Did you know...
|
|
Serial Wombat Public data sources
Each pin provides a 16 bit value which can be seen by other
pins and the host. The meaning of this piece of public data is
dependent on the mode a pin is configured for. The public data
index for each pin is its pin number.
Public data can be read by the host using the 'A' command.
Public data provided by one pin is frequently used by another.
For example, in hysteresis
control, one pin provides the input which controls a second
pin configured for hysteresis output.
Additional system parameters are available as 16 bit public
data under other indexes.
| Public Data Index |
|
Meaning |
| 0 |
|
Public data index 0 always is 0 |
| 1 through 40 |
|
The public data provided by pins 1
through 40 |
| 233 |
|
The 8 bit value of port B, as defined in the 18F4620
datasheet. This 8 bit value represents the digital status
of pins 33(least significant bit),34,35,36,37,38,39, and
40(most significant bit). This data is primarily designed
to be used with the datalogger pin mode. Together, data
233, 234, 235, and 236 can be used with a datalogging pin
to queue the state of 32 of the Wombat's pins at regular
intervals. Note that pins which are configured as
analog inputs will not also function as digital
inputs with regard to this public data. |
| 234 |
|
The 8 bit value of port D, as defined in the 18F4620
datasheet. This 8 bit value represents the digital status
of pins 19(least significant bit),20, 21, 22, 27, 28, 29
and 30(most significant bit). This data is primarily
designed to be used with the datalogger pin mode.
Together, data 233, 234, 235, and 236 can be used with a
datalogging pin to queue the state of 32 of the Wombat's
pins at regular intervals. |
| 235 |
|
The 8 bit value of port C, as defined in the 18F4620
datasheet. This 8 bit value represents the digital status
of pins 15 (least significant bit),16, 17, 18, 23, 24, 25
and 26(most significant bit). This data is primarily
designed to be used with the datalogger pin mode.
Together, data 233, 234, 235, and 236 can be used with a
datalogging pin to queue the state of 32 of the Wombat's
pins at regular intervals. |
| 236 |
|
The 8 bit value of port A, as defined in the 18F4620
datasheet. This 8 bit value represents the digital status
of pins 2 (least significant bit), 3, 4, 5, 6, 7, 14 and
13 (most significant bit; not a typo-they're out of
order). This data is primarily designed to be used with
the datalogger pin mode. Together, data 233, 234, 235,
and 236 can be used with a datalogging pin to queue the
state of 32 of the Wombat's pins at regular intervals.
Note that pins which are configured as
analog inputs will not also function as digital
inputs with regard to this public data. |
| 237 |
|
Last Queue Accessed has been overflowed. After a
queue is accessed (either by a pin mode or a host) the
237 public data will be a 1 if push-in attempts on this
queue have been attempted while it was full. Accessing
this public data will reset this flag to zero. It is not
recommended to use this public data if more than one
queue is active in the system, as the last queue accessed
may vary depending on which pin was most recently
accessing a queue. This data is intended to be used with
the pulse mode
during debugging to allow a visual or audio queue on
queue overflow. |
| 238 |
|
Last Queue Accessed has been underflowed. After a
queue is accessed (either by a pin mode or a host) the
238 public data will be a 1 if shift-out attempts on this
queue have been attempted while it was empty. Accessing
this public data will reset this flag to zero. It is not
recommended to use this public data if more than one
queue is active in the system, as the last queue accessed
may vary depending on which pin was most recently
accessing a queue. This data is intended to be used with
the pulse mode
during debugging to allow a visual or audio queue on
queue underflow. |
| 239 |
|
Incrementing 16-bit number. This public data will
increment each time it is accessed from any source (pin
modes or requested by the host). It's primarily designed
for testing. It will roll over from 65535 to 0. |
| 245 |
|
TX bytes sent
This value increments each time a byte is sent to the
host. It rolls over from 65535 to 0. |
| 246 |
|
RX byte received
This value increments each time a byte is received from
the host. It rolls over from 65535 to 0. |
| 247 |
|
Clock days
This value increments once every 24 hours. The
internal oscillator used to clock the Serial Wombat can
be off by up to 1% and can vary with voltage and
temperature, so this value should not be used for exact
timing. |
| 248 |
|
Clock hours
This value increments once every 60 minutes and
rolls over from 23 to 0. The internal oscillator used to
clock the Serial Wombat can be off by up to 1% and can
vary with voltage and temperature, so this value should
not be used for exact timing. |
| 249 |
|
Clock minutes
This value increments once every 60 seconds and
rolls over from 59 to 0. The internal oscillator used to
clock the Serial Wombat can be off by up to 1% and can
vary with voltage and temperature, so this value should
not be used for exact timing. |
| 250 |
|
Clock seconds
This value increments once per second and rolls
over from 59 to 0. The internal oscillator used to clock
the Serial Wombat can be off by up to 1% and can vary
with voltage and temperature, so this value should not be
used for exact timing. |
| 251 |
|
Receive Byte Overflows
If the Wombat is heavily loaded and messages are sent
very quickly at high baud rates, it is possible for the
Wombat to drop characters. This public data increments
every time a byte is received that the Wombat is unable
to process an incoming byte. This public data can be used
to monitor from the host, or with the pulse mode to beep or
blink a light on an overflow. |
| 252 |
|
Buffer Zero Value
This data is designed for testing and initialization
purposes. It always returns zero |
| 253 |
|
Random Value
This data will return a psuedo-random number
based on a 32 bit Linear Feedback Shift Register with
taps 32, 7, 5, 3, 2 and 1. It returns a different value
each time it is accessed. It repeats every 65536 entries.
It is seeded with 0x00000001 at powerup. The seed will be
configurable in future versions of the Wombat Firmware. |
|
|