Semtech 2006
www.semtech.com
12-3
XE8805/05A
Note: Depending on the status of the EnResPConf bit in RegSysCtrl, the reset conditions of the registers are
different. See the reset block documentation for more details on the resetpconf signal.
12.4 Port B capabilities
Port B
usage (priority)
name
analog
(high)
functions
(medium)
digital
(low) (default)
PB[7]
uart Rx
I/O
PB[6]
analog
uart Tx
I/O
PB[5]
usrt S1
I/O
PB[4]
analog
usrt S0
I/O
PB[3]
32 kHz
I/O
PB[2]
analog
clock CPU
I/O
PB[1]
PWM1 Counter C (C+D)
I/O
PB[0]
analog
PWM0 Counter A (A+B)
I/O
Table 12-7: Different Port B functionality
Table 12-7 shows the different usage that can be made of the port B with the order of priority. If a pair of pins is
selected to be analog, it overwrites the function and digital set-up. If the pin is not selected as analog, but a
function is enabled, it overwrites the digital set-up. If neither the analog nor function are selected for a pin, it is used
as an ordinary digital I/O. This is the default configuration at start-up.
12.5 Port B analog capability
12.5.1
Port B analog configuration
Port B terminals can be attached to a 4 line analog bus by setting the PBAna[x] bits to 1 in the RegPBAna
register.
The other registers then define the connection of these 4 analog lines to the different pads of Port B. This can be
used to implement a simple LCD driver or A/D converter. Analog switching is available only when the circuit is
powered with sufficient voltage (see specification below). Below the specified supply voltage, only voltages that are
close to VSS or VBAT can be switched.
When PBAna[x] is set to 1, a pair of Port B terminals is switched from digital I/O mode to analog mode. The usage
of the registers RegPBPullup, RegPBOut and RegPBDir define the analog configuration (see Table 12-8).
When PBAna[x] = 1, then PBPullup[x] connects the pin to the analog bus. PBDir[x] and PBPOut[x] select which
of the 4 analog lines is used. For odd values of x, the selection bits are in the register RegPBOut (see Table 12-8).
For even values of x, the selection bits are in the register RegPBDir (see Table 12-9).
if x is odd, PBOut[x, x-1]
PBPullup[x]
PB[x] selection on
00
1
analog line 0
01
1
analog line 1
10
1
analog line 2
11
1
analog line 3
XX
0
High impedance
Table 12-8: Selection of the analog lines for PB[x] when x is odd and PBAna[x] = 1
Not
Recommended
for
New
Designs