Difference between revisions of "AOM-3841 SPI CN1&SPI)CN2&CN2 I2C——I2C/SPI"

From ESS-WIKI
Jump to: navigation, search
 
(2 intermediate revisions by the same user not shown)
Line 105: Line 105:
 
</pre>
 
</pre>
  
[[File:AOM-3841 I2C function.png]]
+
[[File:AOM-3841 I2C function.png|RTENOTITLE]]
 
<pre># i2cdetect -y 7
 
<pre># i2cdetect -y 7
 
# i2ctransfer -y 7 w4@0x57 0x1f 0xf0 0x22 0x33
 
# i2ctransfer -y 7 w4@0x57 0x1f 0xf0 0x22 0x33
Line 111: Line 111:
 
0x22 0x33</pre>
 
0x22 0x33</pre>
  
[[File:AOM-3841 I2C function1.png]]
+
[[File:AOM-3841 I2C function1.png|RTENOTITLE]]
  
 
== '''SPI PIN Header''' ==
 
== '''SPI PIN Header''' ==
  
AOM-3841 has two SPI-PIN-Header channels. SPIs on AOM-DB3500 have multi�functions, change to SPI PIN Header.
+
AOM-3841 has two SPI-PIN-Header channels. SPIs on AOM-DB3500 have multifunctions, change to SPI PIN Header.
  
 
=== '''SPI_CN1''' ===
 
=== '''SPI_CN1''' ===
Line 220: Line 220:
 
| SPI Chip Select Input
 
| SPI Chip Select Input
 
|}
 
|}
 +
 +
&nbsp;
  
 
=== '''Jumper Setting:''' ===
 
=== '''Jumper Setting:''' ===
  
=== <br/> <span style="font-size: 13px;">Using EG70 Test Board to read SPI flash.</span> ===
+
{| border="1" cellpadding="1" cellspacing="1" style="width: 472px;"
 +
|-
 +
| colspan="2" style="width: 462px;" | '''SPI Select'''
 +
|-
 +
| style="width: 102px;" | Pin
 +
| style="width: 354px;" | Function
 +
|-
 +
| style="width: 102px;" | J6(1-2)
 +
| style="width: 354px;" | Switch SPI0 to the SPI1 flash on the baseboard.
 +
|-
 +
| style="width: 102px;" | J6(2-3)
 +
| style="width: 354px;" | SPI0 is switched to the baseboard SPI_CN2
 +
|-
 +
| style="width: 102px;" | J5(1-2)
 +
| style="width: 354px;" | Switch from SPI1 to SPI2 flash
 +
|-
 +
| style="width: 102px;" | J5(2-3)
 +
| style="width: 354px;" | SPI1 is switched to SPI_CN1
 +
|}
 +
 
 +
=== '''<span style="font-size: 13px;">Using EG70 Test Board to read SPI flash.</span>''' ===
  
 
Test one SPI port alternatively:
 
Test one SPI port alternatively:
Line 229: Line 251:
  
 
Test two SPI ports at the same time:
 
Test two SPI ports at the same time:
<pre># cat /proc/mtd | grep -c mtd11</pre>
+
<pre># cat /proc/mtd | grep -c mtd11
 +
</pre>
  
RK Tool&nbsp; Test:
+
=== '''RK Tool&nbsp; Test:''' ===
 
<pre># /tools/test/adv/spi/spi_test.sh 0
 
<pre># /tools/test/adv/spi/spi_test.sh 0
 
# /tools/test/adv/spi/spi_test.sh 1</pre>
 
# /tools/test/adv/spi/spi_test.sh 1</pre>
 +
 +
[[File:AOM-3841 SPI function1.png|RTENOTITLE]]

Latest revision as of 08:10, 19 March 2026

I2C Pin Header

AOM-3841 has two I2C-PIN-Header channels.

CN2_I2C

CN2 CN2 Connector Pin Definition
Pin Signal I/O Description
1 GND   Ground
2 I2C0_DATA I/O I2C0 Data
3 I2C0_CLK I I2C0 clock input from host.
4 +V1.8   1.8V Source

CN4_I2C

CN4 CN4 Connector Pin Definition
Pin Signal I/O Description
1 GND   Ground
2 I2C1_DATA I/O I2C1 Data
3 I2C1_CLK I I2C0 clock input from host.
4 +V1.8   1.8V Source

Number

I2C-PIN-Header
I2C Number Bus Number I2C Address AOM-DB3500 Number
I2C0 0 0x53 CN2
I2C1 7 0x57 CN4
# i2cdetect -y 0
0 1 2 3 4 5 6 7 8 9 a b c d e f
00: -- -- -- -- 0c -- -- --
10: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
20: -- -- -- -- -- -- -- UU -- -- -- -- -- -- -- --
30: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
40: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
50: -- -- -- 53 -- -- -- -- -- -- -- -- -- -- -- --
60: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
70: -- 71 -- -- -- -- -- --
# i2cdetect -y 7
# i2ctransfer -y 7 w4@0x53 0x1f 0xf0 0x22 0x33
# i2ctransfer -y 7 w2@0x53 0x1f 0xf0 r2
0x22 0x33

RTENOTITLE

# i2cdetect -y 7
# i2ctransfer -y 7 w4@0x57 0x1f 0xf0 0x22 0x33
# i2ctransfer -y 7 w2@0x57 0x1f 0xf0 r2
0x22 0x33

RTENOTITLE

SPI PIN Header

AOM-3841 has two SPI-PIN-Header channels. SPIs on AOM-DB3500 have multifunctions, change to SPI PIN Header.

SPI_CN1

SPI_CN1 Connector Pin Definition
Pin Signal I/O Description
1 +V1.8   Power Supply
2 GND   Ground
3 SPI1_CS0# I SPI1Chip Select Inpu
4 SPI1_CLK I SPI1 Serial Clock Input
5 SPI1_MISO I SPI1 Master Out Slave in
6 SPI1_MOSI O SPI1 Master In Slave Out
7 NA   Not Applicable
8 SPI1_CS1# I SPI Chip Select Input

SPI_CN2

SPI_CN2 Connector Pin Definition
Pin Signal I/O Description
1 +V1.8   Power Supply
2 GND   Ground
3 SPI0_CS0# I SPI0Chip Select Inpu
4 SPI0_CLK I SPI0 Serial Clock Input
5 SPI0_MISO I SPI0 Master Out Slave in
6 SPI0_MOSI O SPI0 Master In Slave Out
7 NA   Not Applicable
8 SPI0_CS1# I SPI Chip Select Input

 

Jumper Setting:

SPI Select
Pin Function
J6(1-2) Switch SPI0 to the SPI1 flash on the baseboard.
J6(2-3) SPI0 is switched to the baseboard SPI_CN2
J5(1-2) Switch from SPI1 to SPI2 flash
J5(2-3) SPI1 is switched to SPI_CN1

Using EG70 Test Board to read SPI flash.

Test one SPI port alternatively:

# cat /proc/mtd | grep –c mtd01

Test two SPI ports at the same time:

# cat /proc/mtd | grep -c mtd11

RK Tool  Test:

# /tools/test/adv/spi/spi_test.sh 0
# /tools/test/adv/spi/spi_test.sh 1

RTENOTITLE