8160-dioheader

From embeddedTS Manuals
Revision as of 22:14, 26 February 2012 by Mark (talk | contribs) (Created page with "The DIO is manipulated through tsctl, or through manipulation of the registers directly. Using tsctl will be the easiest way to communicate with the IO....")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

The DIO is manipulated through tsctl, or through manipulation of the registers directly.

Using tsctl will be the easiest way to communicate with the IO. This example will show the simplest way to toggle the IO, but see the tsctl page for more advanced usage.

# Start tsctl server if it is not already running.
# This only needs to be done once
tsctl --server &

# Lookup the logical DIO mapping of the dio header pin 1
eval `tsctl 127.0.0.1 System MapLookup DIO_1`
# If you run this outside of the eval it will return:
# DIO_1=130 

# Toggle the DIO high and low:
tsctl 127.0.0.1 DIO Set $DIO_1 high
tsctl 127.0.0.1 DIO Set $DIO_1 low
Pinout Header
Pin Name Notes
1 DIO_1 Pulled high by R124
2 Ground
3 DIO_3 Pulled high by R123
4 I2C_CLK See TS-4200#I2C for more details.
5 DIO_5 Pulled high by R122
6 SPI_CS# See TS-4200#SPI for more details.
7 DIO_7 pulled high by R121
8 I2C_DAT See TS-4200#I2C for more details.
9 DIO_9 Pulled high by R120
10 SPI_MISO See TS-4200#SPI for more details.
11 DIO_11 Pulled high by R119
12 SPI_MOSI See TS-4200#SPI for more details.
13 DIO_13 Pulled high by R118
14 SPI_CLK See TS-4200#SPI for more details.
15 DIO_15 Pulled high by R117
16 CPU_3.3V Do not draw more than 12mA
16 15
14 13
12 11
10 9
8 7
6 5
4 3
2 1
WARNING: DIO are not 5V tolerant. Only SPI_MOSI on this header is 5V tolerant.