User's Manual
Datalogic Scanning, Inc
959 Terry Street
Eugene, Oregon 97402
Page 100 10/23/2009
Revision X2
transmission.
Key Name Key Number Type Default Setting
PSKEY_INITIAL_PIO_STATE 0x03b5 uint16[] none
This key may be used to set the initial state of the PIO pins prior to the VM application running. The key is
an array of uint16s which can be considered to have the following structure:-
struct {
uint16 mask;
uint16 direction;
uint16 level;
uint16 bias;
uint16 buskeep_en;
uint16 disable_pull; }
Each word within the structure can be considered to be an array of bits corresponding to individual PIO
pins.
The mask word is used to control which PIO pins are controlled by this key. Note that PIOs which are
assigned to firmware functions (including those masked by PSKEY_PIO_PROTECT_MASK
) are also
masked out.
The direction word is used to control pin direction:- 0 = input 1 = output
The level word is optional and controls pin output levels:- 0 = low 1 = high From BlueCore2-External on,
for pins set as inputs by the direction word, the corresponding bits in this word determine the direction of a
weak pull device (0=pull-down, 1=pull-up). If the word is not present, pins will be set to their default
power-on levels.
The bias word is optional and controls the strength of the bias applied to pins configured as input:- 0 =
weak bias 1 = strong bias If the word is not present, pins will be set to their default power-on bias strength.
The buskeep_en word is optional and controls whether "bus-keeper" functionality (see
PSKEY_BCSP_PULL_CONTROL) is enabled for pins configured as inputs, on chips which support this:-
0 = bus-keeper disabled 1 = bus-keeper enabled If the word is not present, no bus-keepers will be enabled.
The disable_pull word is optional and controls whether the internal pull device is disabled (see
PSKEY_BCSP_PULL_CONTROL) for pins configured as inputs, on chips which support this. (These bits
have no effect on pins configured as outputs.) 0 = pull device enabled 1 = pull device disabled If the word
is not present, pull devices will be enabled. NOTE: disabling pull devices when pins are not driven
externally can lead to excessive current consumption and potentially damage the chip.
Example -------
To set PIO 3 as an output driving a high signal and PIO 5 as an input with strong-bias set the key to
(0x0028,0x0008,0x0008,0x0020).
mask = 0x0028 # (1<<5 | 1<<3) direction = 0x0008 # (1<<3) level = 0x0008 # (1<<3) bias = 0x0020 #
(1<<5)
Key Name Key Number Type Default Setting