]> Repositories - Adafruit_Blinka-hackapet.git/blob - src/adafruit_blinka/microcontroller/pentium/n3710/pin.py
45ce0e7513a7cd10c66f949753d02beffbd8707a
[Adafruit_Blinka-hackapet.git] / src / adafruit_blinka / microcontroller / pentium / n3710 / pin.py
1 """Pentium N3710 (Braswell core SOC) pin names
2    i2c and GPIO can be accessed through Blinka.
3    For i2c use IC20_SCL, IC20-SDA and IC21-SCL, IC21-SDA in the i2c(<sdl, sda>) calls.
4    For UART use pyserial"""
5 from adafruit_blinka.microcontroller.generic_linux.libgpiod_pin import Pin
6
7 # gpiochip3
8 GPIO_243 = Pin((3, 15))
9 GPIO_246 = Pin((3, 18))
10 GPIO_247 = Pin((3, 19))
11 GPIO_249 = Pin((3, 21))
12 GPIO_250 = Pin((3, 22))
13 GPIO_253 = Pin((3, 25))
14 GPIO_273 = Pin((3, 45))
15 GPIO_275 = Pin((3, 47))
16 GPIO_276 = Pin((3, 48))
17 GPIO_278 = Pin((3, 50))
18 GPIO_279 = Pin((3, 51))
19 GPIO_280 = Pin((3, 52))
20 GPIO_307 = Pin((3, 79))
21
22 SDIO_D3 = SDMMC2_D3 = GPIO_243
23 SDIO_DI = SDMMC2_D1 = GPIO_246
24 SDIO_CLK = SDMMC2_CLK = GPIO_247
25 SDIO_D2 = SDMMC2_D2 = GPIO_249
26 SDIO_CMD = SDMMC2_CMD = GPIO_250
27 SDIO_D0 = SDMMC2_D0 = GPIO_253
28
29 MF_LPC_AD2 = GPIO_273
30 MF_LPC_AD0 = GPIO_275
31 LPC_FRAMEB = GPIO_276
32 MF_LPC_AD3 = GPIO_278
33 MF_LPC_CLKOUT0 = GPIO_279
34 MF_LPC_AD1 = GPIO_280
35 ILB_SERIRQ = GPIO_307
36
37 # ggpiochip1
38 GPIO_358 = Pin((1, 17))
39 GPIO_SUS3 = SDIO_WAKE = GPIO_358
40
41
42 # gpiochip0
43 GPIO_490 = Pin((0, 76))
44 GPIO_492 = Pin((0, 78))
45
46 SATA_GP1 = TS_INT = GPIO_490
47 SATA_GP2 = TS_RST = GPIO_492
48
49
50 # not general gpio on chip 0
51 # use pyserial not blinka.  These are only included for completeness
52
53 UART1_RXD = Pin((0, 16))
54 UART1_TXD = Pin((0, 20))
55 UART1_RTS = Pin((0, 15))
56 UART1_CTS = Pin((0, 18))
57
58 UART2_RXD = Pin((0, 17))
59 UART2_TXD = Pin((0, 21))
60 UART2_RTS = Pin((0, 19))
61 UART2_CTS = Pin((0, 22))
62
63 GPIO_429 = UART1_RTS
64 GPIO_430 = UART1_RXD
65 GPIO_431 = UART2_RXD
66 GPIO_432 = UART1_CTS
67 GPIO_434 = UART1_TXD
68 GPIO_435 = UART2_TXD
69 GPIO_436 = UART2_CTS
70
71 # i2c use these addresses when accessing i2c from Blinka.  You can also access
72 # the i2c useing smbus
73 I2C0_SDA = Pin((0, 61)) # IC21 on diagram, port 0 in hardware manual
74 I2C0_SCL = Pin((0, 65))
75
76 I2C1_SDA = TS_I2C_SDA = Pin((0, 45))  # I2C2 on diagram, port 5 in hardware manual
77 I2C1_SCL = TS_I2C_SCL = Pin((0, 48))
78
79
80 GPIO_469 = I2C1_SDA  # I2C2 on diagram
81 GPIO_472 = I2C1_SCL
82 GPIO_475 = I2C0_SDA  # I2C1 on diagram
83 GPIO_479 = I2C0_SCL
84
85 # ordered as i2cId, sclId, sdaId
86 i2cPorts = ((0, I2C0_SCL, I2C0_SDA),
87             (1, I2C1_SCL, I2C1_SDA))