Difference between revisions of "iMX6 Rex Ultra Accessing and Testing Peripherals"

From Voipac Wiki
Jump to navigation Jump to search
(Created page with "Category:iMX6 Rex Development kit Category:iMX6 Rex Ultra Category:iMX6 Rex Peripherals <!-- --> <div style="float:right">__TOC__</div> Elemental operations of iM...")
 
 
(29 intermediate revisions by the same user not shown)
Line 1: Line 1:
[[Category:iMX6 Rex Development kit]]
+
[[Category:iMX6 Rex Development Kit]]
 
[[Category:iMX6 Rex Ultra]]
 
[[Category:iMX6 Rex Ultra]]
 
[[Category:iMX6 Rex Peripherals]]
 
[[Category:iMX6 Rex Peripherals]]
Line 5: Line 5:
 
<div style="float:right">__TOC__</div>
 
<div style="float:right">__TOC__</div>
  
Elemental operations of iMX6 Rex Development kit interfaces in Ultra configuration are shown on this page.
+
Elemental operations of iMX6 Rex Development Kit interfaces in Ultra configuration are shown on this page.
  
 
== Prerequisites ==
 
== Prerequisites ==
 
=== Hardware ===
 
=== Hardware ===
* DC power supply (5V, 2A)
+
* DC power supply (12V, 1A)
 
* iMX6 Rex Module Ultra
 
* iMX6 Rex Module Ultra
* iMX6 Rex Baseboard
+
* iMX6 Rex Base Board
  
 
=== Peripherals and Accessories ===
 
=== Peripherals and Accessories ===
Line 34: Line 34:
 
'''''Output:''''' Audio chip is detected and bound as an input device
 
'''''Output:''''' Audio chip is detected and bound as an input device
 
<syntaxhighlight lang="bash">
 
<syntaxhighlight lang="bash">
root@imx6-rexpro:~# dmesg | grep -i sgtl5000
+
root@imx6-rexultra:~# dmesg | grep -i sgtl5000
 
sgtl5000 0-000a: sgtl5000 revision 0x11
 
sgtl5000 0-000a: sgtl5000 revision 0x11
 
sgtl5000 0-000a: Using internal LDO instead of VDDD
 
sgtl5000 0-000a: Using internal LDO instead of VDDD
Line 44: Line 44:
 
'''''Output:''''' Card imx-audio-sgtl5000 is available
 
'''''Output:''''' Card imx-audio-sgtl5000 is available
 
<syntaxhighlight lang="bash">
 
<syntaxhighlight lang="bash">
root@imx6-rexpro:~# alsamixer
+
root@imx6-rexultra:~# alsamixer
 
lqqqqqqqqqqqqqqqqqqqqqqqqqqqqq AlsaMixer v1.0.28 qqqqqqqqqqqqqqqqqqqqqqqqqqqqqqk
 
lqqqqqqqqqqqqqqqqqqqqqqqqqqqqq AlsaMixer v1.0.28 qqqqqqqqqqqqqqqqqqqqqqqqqqqqqqk
 
x Card: imx-audio-sgtl5000                            F1:  Help              x
 
x Card: imx-audio-sgtl5000                            F1:  Help              x
Line 71: Line 71:
 
</syntaxhighlight>
 
</syntaxhighlight>
  
'''''Input:''''' Boot-up module with HDMI cable plugged in, connect headphones into LINE_OUT connector and plug-in USB flash drive with mp3 file<br />
+
'''''Input:''''' Boot-up module with HDMI cable plugged in, connect headphones into LINE_OUT connector and plug-in USB flash drive with MP3 file<br />
 
'''''Output:''''' Sound is played and heard
 
'''''Output:''''' Sound is played and heard
 
<syntaxhighlight lang="bash">
 
<syntaxhighlight lang="bash">
Line 106: Line 106:
 
'''''Output:''''' GPIO register is read and displayed state of the button
 
'''''Output:''''' GPIO register is read and displayed state of the button
 
<syntaxhighlight lang="bash">
 
<syntaxhighlight lang="bash">
root@imx6-rexpro:~# echo 511 > /sys/class/gpio/export
+
root@imx6-rexultra:~# echo 511 > /sys/class/gpio/export
root@imx6-rexpro:~# echo in > /sys/class/gpio/gpio511/direction
+
root@imx6-rexultra:~# echo in > /sys/class/gpio/gpio511/direction
root@imx6-rexpro:~# cat /sys/class/gpio/gpio511/value
+
root@imx6-rexultra:~# cat /sys/class/gpio/gpio511/value
 
1
 
1
root@imx6-rexpro:~# cat /sys/class/gpio/gpio511/value
+
root@imx6-rexultra:~# cat /sys/class/gpio/gpio511/value
 
0
 
0
</syntaxhighlight>
 
 
=== Alternative test ===
 
'''''Input:''''' Press the USER button<br />
 
'''''Output:''''' Button events 1 and 0 are generated
 
<syntaxhighlight lang="bash">
 
root@imx6-tinyrexultra:~# hexdump -C /dev/input/event0
 
00000000  18 f4 d1 56 47 40 09 00  01 00 74 00 01 00 00 00  |...VG@....t.....|
 
00000010  18 f4 d1 56 47 40 09 00  00 00 00 00 00 00 00 00  |...VG@..........|
 
00000020  18 f4 d1 56 17 15 0b 00  01 00 74 00 00 00 00 00  |...V......t.....|
 
00000030  18 f4 d1 56 17 15 0b 00  00 00 00 00 00 00 00 00  |...V............|
 
 
</syntaxhighlight>
 
</syntaxhighlight>
  
Line 134: Line 123:
 
CPU:  Freescale i.MX6Q rev1.2 at 792 MHz
 
CPU:  Freescale i.MX6Q rev1.2 at 792 MHz
 
Reset cause: POR
 
Reset cause: POR
Board: MX6 Rex - pro
+
Board: MX6 Rex - ultra
 
I2C:  ready
 
I2C:  ready
 
DRAM:  2 GiB
 
DRAM:  2 GiB
Line 153: Line 142:
 
'''''Note:''''' MAC address should be identical with the address on the sticker placed on module
 
'''''Note:''''' MAC address should be identical with the address on the sticker placed on module
 
<syntaxhighlight lang="bash">
 
<syntaxhighlight lang="bash">
root@imx6-rexpro:~# ip addr show dev eth0
+
root@imx6-rexultra:~# ip addr show dev eth0
 
2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP group default qlen 1000
 
2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP group default qlen 1000
 
     link/ether 00:0d:15:00:cc:e2 brd ff:ff:ff:ff:ff:ff
 
     link/ether 00:0d:15:00:cc:e2 brd ff:ff:ff:ff:ff:ff
Line 162: Line 151:
 
'''''Output:''''' IPv4 address is assigned
 
'''''Output:''''' IPv4 address is assigned
 
<syntaxhighlight lang="bash">
 
<syntaxhighlight lang="bash">
root@imx6-rexpro:~# dmesg | tail
+
root@imx6-rexultra:~# dmesg | tail
 
...
 
...
 
libphy: 2188000.ethernet:03 - Link is Up - 100/Full
 
libphy: 2188000.ethernet:03 - Link is Up - 100/Full
Line 169: Line 158:
  
 
<syntaxhighlight lang="bash">
 
<syntaxhighlight lang="bash">
root@imx6-rexpro:~# udhcpc -i eth0
+
root@imx6-rexultra:~# udhcpc -i eth0
 
udhcpc (v1.22.1) started
 
udhcpc (v1.22.1) started
 
Sending discover...
 
Sending discover...
Line 177: Line 166:
  
 
== HDMI Output ==
 
== HDMI Output ==
'''''Input:''''' Connect LCD monitor to baseboard<br />
+
'''''Input:''''' Connect LCD monitor to the base board<br />
'''''Output:''''' Desktop UI is correctly displayed<br />
+
'''''Output:''''' Desktop UI is displayed correctly<br />
[[image:iMX6_TinyRex_Development_kit-HDMI_terminal.jpg|600px]]
+
[[image:iMX6_TinyRex_Development_Kit-HDMI_terminal.png|580px]]
  
 
== I2C ==
 
== I2C ==
Line 186: Line 175:
 
* SGTL5000 audio (0x0A)
 
* SGTL5000 audio (0x0A)
 
<syntaxhighlight lang="bash">
 
<syntaxhighlight lang="bash">
root@imx6-rexpro:~# i2cdetect -y 0
+
root@imx6-rexultra:~# i2cdetect -y 0
 
     0  1  2  3  4  5  6  7  8  9  a  b  c  d  e  f
 
     0  1  2  3  4  5  6  7  8  9  a  b  c  d  e  f
 
00:          -- -- -- -- -- -- -- UU -- -- -- -- --  
 
00:          -- -- -- -- -- -- -- UU -- -- -- -- --  
Line 207: Line 196:
 
'''''Note:''''' HDMI monitor must be disconnected otherwise I2C bus 1 scanning bus might freeze.
 
'''''Note:''''' HDMI monitor must be disconnected otherwise I2C bus 1 scanning bus might freeze.
 
<syntaxhighlight lang="bash">
 
<syntaxhighlight lang="bash">
root@imx6-rexpro:~# i2cdetect -y 1  
+
root@imx6-rexultra:~# i2cdetect -y 1  
 
     0  1  2  3  4  5  6  7  8  9  a  b  c  d  e  f
 
     0  1  2  3  4  5  6  7  8  9  a  b  c  d  e  f
 
00:          -- -- -- -- -- -- -- -- -- -- -- -- --  
 
00:          -- -- -- -- -- -- -- -- -- -- -- -- --  
Line 222: Line 211:
 
'''''Output:''''' I2C bus 2 is allocated for external use via System Header<br />
 
'''''Output:''''' I2C bus 2 is allocated for external use via System Header<br />
 
<syntaxhighlight lang="bash">
 
<syntaxhighlight lang="bash">
root@imx6-rexpro:~# i2cdetect -y 2
+
root@imx6-rexultra:~# i2cdetect -y 2
 
     0  1  2  3  4  5  6  7  8  9  a  b  c  d  e  f
 
     0  1  2  3  4  5  6  7  8  9  a  b  c  d  e  f
 
00:          -- -- -- -- -- -- -- -- -- -- -- -- --  
 
00:          -- -- -- -- -- -- -- -- -- -- -- -- --  
Line 237: Line 226:
 
'''''Output:''''' GPIO expander is detected
 
'''''Output:''''' GPIO expander is detected
 
<syntaxhighlight lang="bash">
 
<syntaxhighlight lang="bash">
root@imx6-rexpro:~# echo -n "1-0027" > /sys/bus/i2c/drivers/pca953x/unbind
+
root@imx6-rexultra:~# echo -n "1-0027" > /sys/bus/i2c/drivers/pca953x/unbind
root@imx6-rexpro:~# echo -n "1-0027" > /sys/bus/i2c/drivers/pca953x/bind
+
root@imx6-rexultra:~# echo -n "1-0027" > /sys/bus/i2c/drivers/pca953x/bind
 
pca953x 1-0027: interrupt support not compiled in
 
pca953x 1-0027: interrupt support not compiled in
 
</syntaxhighlight>
 
</syntaxhighlight>
Line 245: Line 234:
 
'''''Output:''''' RTC is detected
 
'''''Output:''''' RTC is detected
 
<syntaxhighlight lang="bash">
 
<syntaxhighlight lang="bash">
root@imx6-rexpro:~# echo -n "1-0051" > /sys/bus/i2c/drivers/rtc-pcf8563/unbind
+
root@imx6-rexultra:~# echo -n "1-0051" > /sys/bus/i2c/drivers/rtc-pcf8563/unbind
root@imx6-rexpro:~# echo -n "1-0051" > /sys/bus/i2c/drivers/rtc-pcf8563/bind
+
root@imx6-rexultra:~# echo -n "1-0051" > /sys/bus/i2c/drivers/rtc-pcf8563/bind
 
rtc-pcf8563 1-0051: chip found, driver version 0.4.3
 
rtc-pcf8563 1-0051: chip found, driver version 0.4.3
 
rtc-pcf8563 1-0051: low voltage detected, date/time is not reliable.
 
rtc-pcf8563 1-0051: low voltage detected, date/time is not reliable.
Line 257: Line 246:
 
'''''Output:''''' I2C EEPROM is detected
 
'''''Output:''''' I2C EEPROM is detected
 
<syntaxhighlight lang="bash">
 
<syntaxhighlight lang="bash">
root@imx6-rexpro:~# echo -n "1-0057" > /sys/bus/i2c/drivers/at24/unbind
+
root@imx6-rexultra:~# echo -n "1-0057" > /sys/bus/i2c/drivers/at24/unbind
root@imx6-rexpro:~# echo -n "1-0057" > /sys/bus/i2c/drivers/at24/bind  
+
root@imx6-rexultra:~# echo -n "1-0057" > /sys/bus/i2c/drivers/at24/bind  
 
at24 1-0057: 256 byte 24c02 EEPROM, writable, 1 bytes/write
 
at24 1-0057: 256 byte 24c02 EEPROM, writable, 1 bytes/write
 
</syntaxhighlight>
 
</syntaxhighlight>
  
'''''Input:''''' Write and Read data from I2C EEPROM<br />
+
'''''Input:''''' Write and read data from I2C EEPROM<br />
 
'''''Output:''''' If successful, console text 'Data are the same' should appear
 
'''''Output:''''' If successful, console text 'Data are the same' should appear
 
<syntaxhighlight lang="bash">
 
<syntaxhighlight lang="bash">
root@imx6-rexpro:~# echo -n "0123" > eeprom_in
+
root@imx6-rexultra:~# echo -n "0123" > eeprom_in
root@imx6-rexpro:~# cat eeprom_in > /sys/bus/i2c/devices/1-0057/eeprom
+
root@imx6-rexultra:~# cat eeprom_in > /sys/bus/i2c/devices/1-0057/eeprom
root@imx6-rexpro:~# head -c 4 /sys/bus/i2c/devices/1-0057/eeprom > eeprom_out
+
root@imx6-rexultra:~# head -c 4 /sys/bus/i2c/devices/1-0057/eeprom > eeprom_out
root@imx6-rexpro:~# diff eeprom_in eeprom_out && echo "Data are the same"
+
root@imx6-rexultra:~# diff eeprom_in eeprom_out && echo "Data are the same"
 
Data are the same
 
Data are the same
 
</syntaxhighlight>
 
</syntaxhighlight>
  
=== Altarnative test ===
+
=== Alternative test ===
 
'''''Input:''''' List I2C bus 0, 1 and 2<br />
 
'''''Input:''''' List I2C bus 0, 1 and 2<br />
 
'''''Output:''''' Available devices are displayed
 
'''''Output:''''' Available devices are displayed
 
<syntaxhighlight lang="bash">
 
<syntaxhighlight lang="bash">
root@imx6-rexpro:~# ls /sys/bus/i2c/devices/i2c-0 | grep ^[0]
+
root@imx6-rexultra:~# ls /sys/bus/i2c/devices/i2c-0 | grep ^[0]
 
0-000a
 
0-000a
root@imx6-rexpro:~# ls /sys/bus/i2c/devices/i2c-1 | grep ^[1]
+
root@imx6-rexultra:~# ls /sys/bus/i2c/devices/i2c-1 | grep ^[1]
 
1-0048
 
1-0048
 
1-0050
 
1-0050
root@imx6-rexpro:~# ls /sys/bus/i2c/devices/i2c-2 | grep ^[2]
+
root@imx6-rexultra:~# ls /sys/bus/i2c/devices/i2c-2 | grep ^[2]
 
</syntaxhighlight>
 
</syntaxhighlight>
  
Line 288: Line 277:
 
'''''Output:''''' Red LED assembled on module switches from ON to OFF state with heartbeat pulses afterwards
 
'''''Output:''''' Red LED assembled on module switches from ON to OFF state with heartbeat pulses afterwards
 
<syntaxhighlight lang="bash">
 
<syntaxhighlight lang="bash">
root@imx6-tinyrexultra:~# echo -n "none" > /sys/devices/soc0/leds*/leds/module-led/trigger  
+
root@imx6-rexultra:~# echo -n "none" > /sys/devices/soc0/leds*/leds/module-led/trigger  
root@imx6-tinyrexultra:~# echo -n "1" > /sys/devices/soc0/leds*/leds/module-led/brightness
+
root@imx6-rexultra:~# echo -n "1" > /sys/devices/soc0/leds*/leds/module-led/brightness
root@imx6-tinyrexultra:~# echo -n "0" > /sys/devices/soc0/leds*/leds/module-led/brightness
+
root@imx6-rexultra:~# echo -n "0" > /sys/devices/soc0/leds*/leds/module-led/brightness
root@imx6-tinyrexultra:~# echo -n "heartbeat" >  /sys/devices/soc0/leds*/leds/module-led/trigger  
+
root@imx6-rexultra:~# echo -n "heartbeat" >  /sys/devices/soc0/leds*/leds/module-led/trigger  
 
</syntaxhighlight>
 
</syntaxhighlight>
  
 
'''''Input:''''' GPIO expander PCA9535 driver<br />
 
'''''Input:''''' GPIO expander PCA9535 driver<br />
'''''Output:''''' Red LED assembled on baseboard switches from ON to OFF state
+
'''''Output:''''' Red LED assembled on the base board switches from ON to OFF state
 
<syntaxhighlight lang="bash">
 
<syntaxhighlight lang="bash">
root@imx6-rexpro:~# echo 510 > /sys/class/gpio/export
+
root@imx6-rexultra:~# echo 510 > /sys/class/gpio/export
root@imx6-rexpro:~# echo out > /sys/class/gpio/gpio510/direction
+
root@imx6-rexultra:~# echo out > /sys/class/gpio/gpio510/direction
root@imx6-rexpro:~# echo 1 > /sys/class/gpio/gpio510/value
+
root@imx6-rexultra:~# echo 1 > /sys/class/gpio/gpio510/value
root@imx6-rexpro:~# echo 0 > /sys/class/gpio/gpio510/value
+
root@imx6-rexultra:~# echo 0 > /sys/class/gpio/gpio510/value
 
</syntaxhighlight>
 
</syntaxhighlight>
  
 
== LVDS display ==
 
== LVDS display ==
 
Details how to properly connect display with LVDS and touchsreen interfaces are described on [[iMX6 Rex Display Set|Display Set page]].<br /><br />
 
Details how to properly connect display with LVDS and touchsreen interfaces are described on [[iMX6 Rex Display Set|Display Set page]].<br /><br />
'''''Input:''''' Configure kernel command line in uboot and boot up the module
+
'''''Input:''''' Configure U-Boot video environment and boot up the module<br />
 
'''''Output:''''' GUI can be seen on LVDS screen
 
'''''Output:''''' GUI can be seen on LVDS screen
 
<syntaxhighlight lang="bash">
 
<syntaxhighlight lang="bash">
Line 314: Line 303:
 
== DDR memory ==
 
== DDR memory ==
 
'''''Input:''''' None<br />
 
'''''Input:''''' None<br />
'''''Output:''''' Memory test passes without any error
+
'''''Output:''''' Memory test passes without any errors
 
<syntaxhighlight lang="bash">
 
<syntaxhighlight lang="bash">
root@imx6-rexpro:~# memtester 2G 1   
+
root@imx6-rexultra:~# memtester 2G 1   
 
memtester version 4.1.3 (32-bit)
 
memtester version 4.1.3 (32-bit)
 
Copyright (C) 2010 Charles Cazabon.
 
Copyright (C) 2010 Charles Cazabon.
Line 394: Line 383:
  
 
== PCI Express ==
 
== PCI Express ==
The procedure uses to a WiFi wireless card to test PCIe interface. More details concerning wireless cards are located on [[iMX6 TinyRex Wireless|WiFi and Bluetooth Cards page]] .<br/><br />
+
The procedure uses a WiFi wireless card to test PCIe interface. More details concerning wireless cards are located on [[iMX6 Rex Wireless|WiFi and Bluetooth Cards page]] .<br/><br />
  
 
'''''Input:''''' Plug Wireless WiFi Link 4965AGN mini PCIe card into mini PCIe slot 1<br />
 
'''''Input:''''' Plug Wireless WiFi Link 4965AGN mini PCIe card into mini PCIe slot 1<br />
 
'''''Output:''''' Card is detected by system
 
'''''Output:''''' Card is detected by system
 
<syntaxhighlight lang="bash">
 
<syntaxhighlight lang="bash">
root@imx6-rexpro:~# lspci  
+
root@imx6-rexultra:~# lspci  
 
00:00.0 PCI bridge: Device 16c3:abcd (rev 01)
 
00:00.0 PCI bridge: Device 16c3:abcd (rev 01)
 
01:00.0 Network controller: Intel Corporation PRO/Wireless 4965 AG or AGN [Kedron] Network Connection (rev 61)
 
01:00.0 Network controller: Intel Corporation PRO/Wireless 4965 AG or AGN [Kedron] Network Connection (rev 61)
 
</syntaxhighlight>
 
</syntaxhighlight>
  
'''''Input:''''' Plug Wireless WiFi Link 4965AGN mini PCIe card into mini PCIe slot<br />
+
'''''Input:''''' Plug Wireless WiFi Link 4965AGN mini PCIe card into mini PCIe slot 1<br />
 
'''''Output:''''' Wireless WiFi card firmware is loaded
 
'''''Output:''''' Wireless WiFi card firmware is loaded
 
<syntaxhighlight lang="bash">
 
<syntaxhighlight lang="bash">
root@imx6-rexpro:~# dmesg | grep iwl4965
+
root@imx6-rexultra:~# dmesg | grep iwl4965
 
iwl4965: Intel(R) Wireless WiFi 4965 driver for Linux, in-tree:
 
iwl4965: Intel(R) Wireless WiFi 4965 driver for Linux, in-tree:
 
iwl4965: Copyright(c) 2003-2011 Intel Corporation
 
iwl4965: Copyright(c) 2003-2011 Intel Corporation
Line 416: Line 405:
 
</syntaxhighlight>
 
</syntaxhighlight>
  
'''''Input:''''' Plug Wireless WiFi Link 4965AGN mini PCIe card into mini PCIe slot<br />
+
'''''Input:''''' Plug Wireless WiFi Link 4965AGN mini PCIe card into mini PCIe slot 1<br />
 
'''''Output:''''' Card scans neighbour networks
 
'''''Output:''''' Card scans neighbour networks
 
<syntaxhighlight lang="bash">
 
<syntaxhighlight lang="bash">
root@imx6-rexpro:~# rfkill unblock wlan
+
root@imx6-rexultra:~# rfkill unblock wlan
root@imx6-rexpro:~# ip link set wlan0 up
+
root@imx6-rexultra:~# ip link set wlan0 up
 
IPv6: ADDRCONF(NETDEV_UP): wlan0: link is not ready
 
IPv6: ADDRCONF(NETDEV_UP): wlan0: link is not ready
root@imx6-rexpro:~# iw dev wlan0 scan
+
root@imx6-rexultra:~# iw dev wlan0 scan
 
BSS 20:aa:4b:7e:21:97(on wlan0)
 
BSS 20:aa:4b:7e:21:97(on wlan0)
 
         TSF: 9263203904202 usec (107d, 05:06:43)
 
         TSF: 9263203904202 usec (107d, 05:06:43)
Line 453: Line 442:
  
 
=== Alternative test ===
 
=== Alternative test ===
'''''Input:''''' Plug Wireless WiFi Link 4965AGN mini PCIe card into mini PCIe slot<br />
+
'''''Input:''''' Plug Wireless WiFi Link 4965AGN mini PCIe card into mini PCIe slot 1<br />
 
'''''Output:''''' Card scans neighbour networks
 
'''''Output:''''' Card scans neighbour networks
 
<syntaxhighlight lang="bash">
 
<syntaxhighlight lang="bash">
root@imx6-rexpro:~# ip link set wlan0 up
+
root@imx6-rexultra:~# ip link set wlan0 up
 
IPv6: ADDRCONF(NETDEV_UP): wlan0: link is not ready
 
IPv6: ADDRCONF(NETDEV_UP): wlan0: link is not ready
root@imx6-rexpro:~# iwlist wlan0 scan
+
root@imx6-rexultra:~# iwlist wlan0 scan
 
wlan0    Scan completed :
 
wlan0    Scan completed :
 
           Cell 01 - Address: 20:AA:4B:7E:21:97
 
           Cell 01 - Address: 20:AA:4B:7E:21:97
Line 488: Line 477:
  
 
== SATA ==
 
== SATA ==
'''''Input:''''' Power off the baseboard, connect HDD to SATA connector, provide power for the hard drive and turn on the board<br />
+
'''''Input:''''' Power off the base board, connect HDD to SATA connector, provide power for the hard drive and turn on the board<br />
 
'''''Output:''''' HDD is detected
 
'''''Output:''''' HDD is detected
 
<syntaxhighlight lang="bash">
 
<syntaxhighlight lang="bash">
root@imx6-tinyrexultra:~# dmesg | grep -i -e sata -e ata1
+
root@imx6-rexultra:~# dmesg | grep -i -e sata -e ata1
 
ahci-imx 2200000.sata: fsl,transmit-level-mV not specified, using 00000024
 
ahci-imx 2200000.sata: fsl,transmit-level-mV not specified, using 00000024
 
ahci-imx 2200000.sata: fsl,transmit-boost-mdB not specified, using 00000480
 
ahci-imx 2200000.sata: fsl,transmit-boost-mdB not specified, using 00000480
Line 499: Line 488:
 
ahci-imx 2200000.sata: AHCI 0001.0300 32 slots 1 ports 3 Gbps 0x1 impl platform mode
 
ahci-imx 2200000.sata: AHCI 0001.0300 32 slots 1 ports 3 Gbps 0x1 impl platform mode
 
ahci-imx 2200000.sata: flags: ncq sntf stag pm led clo only pmp pio slum part ccc apst  
 
ahci-imx 2200000.sata: flags: ncq sntf stag pm led clo only pmp pio slum part ccc apst  
ata1: SATA max UDMA/133 mmio [mem 0x02200000-0x02203fff] port 0x100 irq 71
+
ata1: SATA max UDMA/133 mmio [mem 0x02200000-0x02203fff] port 0x100 irq 306
ata1: SATA link up 3.0 Gbps (SStatus 123 SControl 300)
+
ata1: SATA link down (SStatus 0 SControl 300)
ata1.00: ATA-8: WDC WD1600BEVT-22ZCT0, 11.01A11, max UDMA/133
+
ahci-imx 2200000.sata: no device found, disabling link.
ata1.00: 312581808 sectors, multi 0: LBA48 NCQ (depth 31/32)
+
ahci-imx 2200000.sata: pass ahci_imx..hotplug=1 to enable hotplug
ata1.00: configured for UDMA/133
 
 
</syntaxhighlight>
 
</syntaxhighlight>
  
'''''Input:''''' Generate a dummy file and copy this file into HDD and compare checksums<br />
+
SATA device can be used as a default filesystem source. [[iMX6 Rex SATA|SATA Interface page]] contains detailed steps to follow. iMX6 Rex Deveploment Kit gives an alternate option of utilizing SATA interface and reliabale storage by supporting [[iMX6 Rex CFast Card|CFast Cards]].
'''''Output:''''' Both file are identical and have the same checksum
 
<syntaxhighlight lang="bash">
 
root@imx6-tinyrexultra:~# umount /dev/sda[1-9]
 
root@imx6-tinyrexultra:~# dd if=/dev/zero of=/dev/sda bs=512 count=1
 
1+0 records in
 
1+0 records out
 
512 bytes (512 B) copied, 0.361743 s, 1.4 kB/s
 
root@imx6-tinyrexultra:~# fdisk /dev/sda
 
...
 
 
 
 
 
The number of cylinders for this disk is set to 19457.
 
There is nothing wrong with that, but this is larger than 1024,
 
and could in certain setups cause problems with:
 
1) software that runs at boot time (e.g., old versions of LILO)
 
2) booting and partitioning software from other OSs
 
  (e.g., DOS FDISK, OS/2 FDISK)
 
 
 
Command (m for help): n
 
Command action
 
  e  extended
 
  p  primary partition (1-4)
 
p
 
Partition number (1-4): 1
 
First cylinder (1-19457, default 1): Using default value 1
 
Last cylinder or size or sizeM or sizeK (1-19457, default 19457): Using default value 19457
 
 
 
Command (m for help): t
 
Selected partition 1
 
Hex code (type L to list codes): c
 
Changed system type of partition 1 to c (Win95 FAT32 (LBA))
 
 
 
Command (m for help): w
 
The partition table has been altered.
 
Calling ioctl() to re-read partition table
 
sda: sda1
 
root@imx6-tinyrexultra:~# umount /dev/sda1
 
root@imx6-tinyrexultra:~# mkfs.vfat -F32 /dev/sda1
 
root@imx6-tinyrexultra:~# mount /dev/sda1 /media/
 
root@imx6-tinyrexultra:~# rm -f file.txt /media/file.txt
 
root@imx6-tinyrexultra:~# dd if=/dev/urandom of=file.txt count=1024 bs=1024
 
1024+0 records in
 
1024+0 records out
 
1048576 bytes (1.0 MB) copied, 0.434573 s, 2.4 MB/s
 
root@imx6-tinyrexultra:~# cp file.txt /media/
 
root@imx6-tinyrexultra:~# md5sum file.txt /media/file.txt
 
b8e8141b61813fcc08a6164833729e3b  file.txt
 
b8e8141b61813fcc08a6164833729e3b  /media/file.txt
 
root@imx6-tinyrexultra:~# rm -f file.txt /media/file.txt
 
root@imx6-tinyrexultra:~# umount /dev/sda1
 
</syntaxhighlight><br />
 
 
 
SATA device can be used as a default bootlader and filesystem source. [[iMX6 TinyRex SATA|SATA Interface page]] contains detailed steps to follow.
 
  
 
== SD card ==
 
== SD card ==
'''''Input:''''' SD card is plugged in<br />
 
'''''Output:''''' Files stored on SD card are listed
 
<syntaxhighlight lang="bash">
 
root@imx6-tinyrexultra:~# dmesg | grep mmc
 
mmc0: new high speed SD card at address aaaa
 
mmcblk1: mmc0:aaaa SU02G 1.84 GiB
 
mmcblk1: p1
 
root@imx6-tinyrexultra:~# mount /dev/mmcblk1p1 /media/
 
root@imx6-tinyrexultra:~# ls -la /media
 
total 118084
 
drwxr-xr-x  4 root root        8192 Jan  1  1970 .
 
drwxr-xr-x 22 root linaro      4096 Dec 20 09:30 ..
 
-rwxr-xr-x  1 root root  120886176 Dec 22 15:11 78.avi
 
drwxr-xr-x  8 root root        8192 Oct 10 16:48 Pictures processed
 
drwxr-xr-x  2 root root        8192 Oct 10 16:44 iMX6 Rex Moduel Layout videos
 
</syntaxhighlight>
 
  
== SPI Flash Memory ==
+
=== Top slot SD card (mmcblk1) ===
'''''Input:''''' Trigger M25P80 flash detection<br />
+
'''''Input:''''' Plug and unplug SD card<br />
'''''Output:''''' SPI Flash sst25vf032b is detected
+
'''''Output:''''' Kernel log shows that mmc1 device is added and removed
 
<syntaxhighlight lang="bash">
 
<syntaxhighlight lang="bash">
root@imx6-tinyrexultra:~# echo -n "spi0.0" > /sys/bus/spi/drivers/m25p80/unbind
+
root@imx6-rexultra:~# dmesg | tail
root@imx6-tinyrexultra:~# echo -n "spi0.0" > /sys/bus/spi/drivers/m25p80/bind
+
...
m25p80 spi0.0: found sst25vf032b, expected m25p32
+
mmc1: new high speed SDHC card at address e624
m25p80 spi0.0: sst25vf032b (4096 Kbytes)
+
mmcblk1: mmc1:e624 SU08G 7.40 GiB
 +
mmcblk1: p1 p2
 +
FAT-fs (mmcblk1p1): Volume was not properly unmounted. Some data may be corrupt. Please run fsck.
 +
EXT4-fs (mmcblk1p2): recovery complete
 +
EXT4-fs (mmcblk1p2): mounted filesystem with ordered data mode. Opts: (null)
 +
mmc1: card e624 removed
 
</syntaxhighlight>
 
</syntaxhighlight>
  
== Suspend ==
+
=== Bottom slot SD card (mmcblk2) ===
'''''Input:''''' Put module into suspend state (mem state). Wait 10s and then press USER button<br />
+
'''''Input:''''' Plug SD card with a filesystem and boot-up the module<br />
'''''Output:''''' Module wakes up
+
'''''Output:''''' Module boots up successfully
 
<syntaxhighlight lang="bash">
 
<syntaxhighlight lang="bash">
root@imx6-tinyrexultra:~# echo mem > /sys/power/state
+
root@imx6-rexultra:~# dmesg | grep -i "Kernel command line"
PM: Syncing filesystems ... done.
+
Kernel command line: console=ttymxc0,115200 root=/dev/mmcblk2p2 rootwait rw
Freezing user space processes ... (elapsed 0.005 seconds) done.
 
Freezing remaining freezable tasks ... (elapsed 0.001 seconds) done.
 
Suspending console(s) (use no_console_suspend to debug)
 
fec 2188000.ethernet eth0: Graceful transmit stop did not complete!
 
PM: suspend of devices complete after 31.996 msecs
 
PM: suspend devices took 0.030 seconds
 
PM: late suspend of devices complete after 0.511 msecs
 
PM: noirq suspend of devices complete after 11.941 msecs
 
Disabling non-boot CPUs ...
 
PM: noirq resume of devices complete after 20.111 msecs
 
PM: early resume of devices complete after 0.399 msecs
 
PM: resume of devices complete after 412.384 msecs
 
PM: resume devices took 0.410 seconds
 
Restarting tasks ... done.
 
root@imx6-tinyrexultra:~#
 
 
</syntaxhighlight>
 
</syntaxhighlight>
  
'''''Input:''''' Put module into suspend state (standby state). Wait 10s and then press USER button<br />
+
== SPI Flash Memory ==
'''''Output:''''' Module wakes up
+
'''''Input:''''' Trigger M25P80 flash detection<br />
 +
'''''Output:''''' SPI Flash  sst25vf016b(sst25vf032b) is detected
 
<syntaxhighlight lang="bash">
 
<syntaxhighlight lang="bash">
root@imx6-tinyrexultra:~# echo standby > /sys/power/state
+
root@imx6-rexultra:~# echo -n "spi2.0" > /sys/bus/spi/drivers/m25p80/unbind
PM: Syncing filesystems ... done.
+
root@imx6-rexultra:~# echo -n "spi2.0" > /sys/bus/spi/drivers/m25p80/bind
Freezing user space processes ... (elapsed 0.005 seconds) done.
+
m25p80 spi2.0: found sst25vf032b, expected m25p32
Freezing remaining freezable tasks ... (elapsed 0.001 seconds) done.
+
m25p80 spi2.0: sst25vf032b (4096 Kbytes)
Suspending console(s) (use no_console_suspend to debug)
 
fec 2188000.ethernet eth0: Graceful transmit stop did not complete!
 
PM: suspend of devices complete after 31.989 msecs
 
PM: suspend devices took 0.030 seconds
 
PM: late suspend of devices complete after 0.532 msecs
 
PM: noirq suspend of devices complete after 11.862 msecs
 
Disabling non-boot CPUs ...
 
PM: noirq resume of devices complete after 20.186 msecs
 
PM: early resume of devices complete after 0.397 msecs
 
PM: resume of devices complete after 412.337 msecs
 
PM: resume devices took 0.410 seconds
 
Restarting tasks ... done.
 
root@imx6-tinyrexultra:~#
 
 
</syntaxhighlight>
 
</syntaxhighlight>
  
'''''Input:''''' Set RTC wakeup event after 10s and put module into suspend state (standby state)<br />
+
'''''Input:''''' Write and read data from M25P80 flash<br />
'''''Output:''''' Module wakes up by itself
+
'''''Output:''''' If successful, console text 'Data are the same' should appear
 
<syntaxhighlight lang="bash">
 
<syntaxhighlight lang="bash">
root@imx6-tinyrexultra:~# echo +10 > /sys/class/rtc/rtc0/wakealarm && echo standby > /sys/power/state
+
root@imx6-rexultra:~# echo -n "0123" > mtd_in
PM: Syncing filesystems ... done.
+
root@imx6-rexultra:~# mtd_debug write /dev/mtd0 0 4 mtd_in
Freezing user space processes ... (elapsed 0.005 seconds) done.
+
Copied 4 bytes from mtd_in to address 0x00000000 in flash
Freezing remaining freezable tasks ... (elapsed 0.001 seconds) done.
+
root@imx6-rexultra:~# mtd_debug read /dev/mtd0 0 4 mtd_out
Suspending console(s) (use no_console_suspend to debug)
+
Copied 4 bytes from address 0x00000000 in flash to mtd_out
fec 2188000.ethernet eth0: Graceful transmit stop did not complete!
+
root@imx6-rexultra:~# diff mtd_in mtd_out && echo "Data are the same"
PM: suspend of devices complete after 32.020 msecs
+
Data are the same
PM: suspend devices took 0.030 seconds
 
PM: late suspend of devices complete after 0.515 msecs
 
PM: noirq suspend of devices complete after 11.887 msecs
 
Disabling non-boot CPUs ...
 
PM: noirq resume of devices complete after 19.990 msecs
 
PM: early resume of devices complete after 0.392 msecs
 
PM: resume of devices complete after 412.311 msecs
 
PM: resume devices took 0.410 seconds
 
Restarting tasks ... done.
 
root@imx6-tinyrexultra:~#
 
 
</syntaxhighlight>
 
</syntaxhighlight>
  
 
== UART serial console ==
 
== UART serial console ==
'''''Input:''''' Connect USB to UART cable into baseboard connector and open serial console with baud rate 115200 8n1<br />
+
'''''Input:''''' Connect RS-232 cable into the base board connector and open serial console with baud rate 115200 8n1<br />
 
'''''Output:''''' The board is controlled and responsive to serial terminal commands
 
'''''Output:''''' The board is controlled and responsive to serial terminal commands
 
<syntaxhighlight lang="bash">
 
<syntaxhighlight lang="bash">
root@imx6-tinyrexultra:~# uname -a
+
root@imx6-rexultra:~# uname -a
Linux imx6-tinyrexultra 3.14.43-yocto+g4b13aeb #1 SMP PREEMPT Tue Jan 19 21:42:39 CET 2016 armv7l GNU/Linux
+
Linux imx6-rexultra 3.14.58-yocto+g11e5ba3 #1 SMP PREEMPT Sun Mar 13 20:20:31 CET 2016 armv7l GNU/Linux
 
</syntaxhighlight>
 
</syntaxhighlight>
  
 
== USB ==
 
== USB ==
'''''Input:''''' Plug USB flash drive with single VFAT partition into bottom USB connector<br />
+
'''''Input:''''' Plug USB flash drive with single VFAT partition into the bottom USB connector<br />
'''''Output:''''' Filesystem recognises the flash drive and automatically mounts it
+
'''''Output:''''' Filesystem recognises the flash drive and automatically mounts it. SMC Hub with ID 0424:2514 is mounted
 
<syntaxhighlight lang="bash">
 
<syntaxhighlight lang="bash">
root@imx6-tinyrexultra:~# lsusb
+
root@imx6-rexultra:~# lsusb
Bus 001 Device 002: ID 125f:d31a A-DATA Technology Co., Ltd.  
+
Bus 001 Device 003: ID 1bc7:0021 Telit HE910
 +
Bus 001 Device 005: ID 054c:0243 Sony Corp. MicroVault Flash Drive
 +
Bus 001 Device 004: ID 0930:6544 Toshiba Corp. Kingston DataTraveler 2.0 Stick (2GB)
 +
Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
 +
Bus 001 Device 002: ID 0424:2514 Standard Microsystems Corp. USB 2.0 Hub
 
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
 
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
  
root@imx6-tinyrexultra:~# mount | grep /run/media/sd*
+
root@imx6-rexultra:~# mount | grep /run/media/sd*
 
/dev/sda1 on /run/media/sda1 type vfat (rw,relatime,gid=6,fmask=0007,dmask=0007,allow_utime=0020,codepage=437,iocharset=iso8859-1,shortname=mixed,errors=remount-ro)
 
/dev/sda1 on /run/media/sda1 type vfat (rw,relatime,gid=6,fmask=0007,dmask=0007,allow_utime=0020,codepage=437,iocharset=iso8859-1,shortname=mixed,errors=remount-ro)
 
</syntaxhighlight>
 
</syntaxhighlight>
Line 679: Line 570:
 
'''''Output:''''' Generated file and copied file have the same checksum
 
'''''Output:''''' Generated file and copied file have the same checksum
 
<syntaxhighlight lang="bash">
 
<syntaxhighlight lang="bash">
root@imx6-tinyrexultra:~# rm -f file.txt /run/media/sda1/file.txt  
+
root@imx6-rexultra:~# rm -f file.txt /run/media/sda1/file.txt  
root@imx6-tinyrexultra:~# dd if=/dev/urandom of=file.txt count=1024 bs=1024
+
root@imx6-rexultra:~# dd if=/dev/urandom of=file.txt count=1024 bs=1024
 
1024+0 records in
 
1024+0 records in
 
1024+0 records out
 
1024+0 records out
1048576 bytes (1.0 MB) copied, 0.435065 s, 2.4 MB/s
+
1048576 bytes (1.0 MB) copied, 0.435456 s, 2.4 MB/s
root@imx6-tinyrexultra:~# cp file.txt /run/media/sda1/
+
root@imx6-rexultra:~# cp file.txt /run/media/sda1/
root@imx6-tinyrexultra:~# md5sum file.txt /run/media/sda1/file.txt  
+
root@imx6-rexultra:~# md5sum file.txt /run/media/sda1/file.txt
b8e8141b61813fcc08a6164833729e3b file.txt
+
33ef96efccbbf570bfce477735ed2068 file.txt
b8e8141b61813fcc08a6164833729e3b /run/media/sda1/file.txt
+
33ef96efccbbf570bfce477735ed2068 /run/media/sda1/file.txt
root@imx6-tinyrexultra:~# rm file.txt /run/media/sda1/file.txt
+
root@imx6-rexultra:~# rm file.txt /run/media/sda1/file.txt
 
</syntaxhighlight>
 
</syntaxhighlight>
  
 
== USB OTG ==
 
== USB OTG ==
'''''Input:''''' Load USB serial gadget driver and connect baseboard to host PC over micro USB cable<br />
+
'''''Input:''''' Load USB serial gadget driver and connect base board to host PC over micro USB cable<br />
 
'''''Output:''''' Driver is successfully loaded and host PC detects a new USB serial gadget device<br /><br />
 
'''''Output:''''' Driver is successfully loaded and host PC detects a new USB serial gadget device<br /><br />
  
iMX6 Rex Development kit:
+
iMX6 Rex Development Kit:
 
<syntaxhighlight lang="bash">
 
<syntaxhighlight lang="bash">
root@imx6-tinyrexultra:~# modprobe -i g_serial
+
root@imx6-rexultra:~# modprobe -i g_serial
 
g_serial gadget: Gadget Serial v2.4
 
g_serial gadget: Gadget Serial v2.4
 
g_serial gadget: g_serial ready
 
g_serial gadget: g_serial ready
root@imx6-tinyrexultra:~# g_serial gadget: high-speed config #2: CDC ACM config
+
root@imx6-rexultra:~# g_serial gadget: high-speed config #2: CDC ACM config
 
</syntaxhighlight>
 
</syntaxhighlight>
  
Line 709: Line 600:
 
Bus 001 Device 014: ID 0525:a4a7 Netchip Technology, Inc. Linux-USB Serial Gadget (CDC ACM mode)
 
Bus 001 Device 014: ID 0525:a4a7 Netchip Technology, Inc. Linux-USB Serial Gadget (CDC ACM mode)
 
...
 
...
 +
</syntaxhighlight>
 +
 +
== Touchscreen ==
 +
Details how to properly connect display with LVDS and touchsreen interfaces are described on [[iMX6 Rex Display Set|Display Set page]].<br /><br />
 +
 +
'''''Input:''''' Search kernel log for TSC2007 chip<br />
 +
'''''Output:''''' TSC2007 chip is detected and bound as an input device
 +
<syntaxhighlight lang="bash">
 +
root@imx6-rexultra:~# dmesg | grep -i tsc2007
 +
input: TSC2007 Touchscreen as /devices/soc0/soc.0/2100000.aips-bus/21a4000.i2c/i2c-1/1-0048/input/input0
 +
evbug: Connected device: input0 (TSC2007 Touchscreen at 1-0048/input0)
 +
</syntaxhighlight>
 +
 +
'''''Input:''''' Press the touchscreen<br />
 +
'''''Output:''''' Touchscreen events are generated
 +
<syntaxhighlight lang="bash">
 +
root@imx6-rexultra:~# evtest /dev/input/by-path/platform-21a4000.i2c-event
 +
Input driver version is 1.0.1
 +
Input device ID: bus 0x18 vendor 0x0 product 0x0 version 0x0
 +
Input device name: "TSC2007 Touchscreen"
 +
Supported events:
 +
  Event type 0 (EV_SYN)
 +
  Event type 1 (EV_KEY)
 +
    Event code 330 (BTN_TOUCH)
 +
  Event type 3 (EV_ABS)
 +
    Event code 0 (ABS_X)
 +
      Value  3529
 +
      Min        0
 +
      Max    4095
 +
    Event code 1 (ABS_Y)
 +
      Value    375
 +
      Min        0
 +
      Max    4095
 +
    Event code 24 (ABS_PRESSURE)
 +
      Value      0
 +
      Min        0
 +
      Max    4095
 +
Properties:
 +
Testing ... (interrupt to exit)
 +
Event: time 1457899907.959665, type 1 (EV_KEY), code 330 (BTN_TOUCH), value 1
 +
Event: time 1457899907.959665, type 3 (EV_ABS), code 0 (ABS_X), value 1657
 +
Event: time 1457899907.959665, type 3 (EV_ABS), code 1 (ABS_Y), value 2486
 +
Event: time 1457899907.959665, type 3 (EV_ABS), code 24 (ABS_PRESSURE), value 3268
 +
Event: time 1457899907.959665, -------------- EV_SYN ------------
 +
Event: time 1457899907.969094, type 1 (EV_KEY), code 330 (BTN_TOUCH), value 0
 +
Event: time 1457899907.969094, type 3 (EV_ABS), code 24 (ABS_PRESSURE), value 0
 +
Event: time 1457899907.969094, -------------- EV_SYN ------------
 +
</syntaxhighlight>
 +
 +
=== Alternative test ===
 +
'''''Input:''''' Press the touchscreen<br />
 +
'''''Output:''''' Touchscreen events are generated
 +
<syntaxhighlight lang="bash">
 +
root@imx6-rexultra:~# hexdump -C /dev/input/event0
 +
00000000  79 ca e5 56 cd a3 07 00  01 00 4a 01 01 00 00 00  |y..V......J.....|
 +
00000010  79 ca e5 56 cd a3 07 00  03 00 00 00 2f 08 00 00  |y..V......../...|
 +
00000020  79 ca e5 56 cd a3 07 00  03 00 01 00 a7 07 00 00  |y..V............|
 +
00000030  79 ca e5 56 cd a3 07 00  03 00 18 00 64 06 00 00  |y..V........d...|
 +
00000040  79 ca e5 56 cd a3 07 00  00 00 00 00 00 00 00 00  |y..V............|
 +
00000050  79 ca e5 56 a7 c4 07 00  01 00 4a 01 00 00 00 00  |y..V......J.....|
 +
00000060  79 ca e5 56 a7 c4 07 00  03 00 18 00 00 00 00 00  |y..V............|
 +
00000070  79 ca e5 56 a7 c4 07 00  00 00 00 00 00 00 00 00  |y..V............|
 
</syntaxhighlight>
 
</syntaxhighlight>

Latest revision as of 10:51, 24 April 2022

Elemental operations of iMX6 Rex Development Kit interfaces in Ultra configuration are shown on this page.

Prerequisites

Hardware

  • DC power supply (12V, 1A)
  • iMX6 Rex Module Ultra
  • iMX6 Rex Base Board

Peripherals and Accessories

  • 1x FullHD monitor with Audio output
  • 1x LVDS touchscreen display
  • 2x MicroSD card
  • 1x MiniPCIe WiFi card
  • 1x MiniPCIe 3G card
  • 1x SATA HDD drive
  • 2x USB FLASH drive
  • 1x headphones
  • 1x microphone

Cables

  • Ethernet cable
  • HDMI cable
  • Micro USB cable
  • RS-232 cable

Audio

Input: Search kernel log for SGTL5000 chip
Output: Audio chip is detected and bound as an input device

root@imx6-rexultra:~# dmesg | grep -i sgtl5000
sgtl5000 0-000a: sgtl5000 revision 0x11
sgtl5000 0-000a: Using internal LDO instead of VDDD
imx-sgtl5000 sound.23: sgtl5000 <-> 2028000.ssi mapping ok
  #0: imx-audio-sgtl5000

Input: Run alsamixer command
Output: Card imx-audio-sgtl5000 is available

root@imx6-rexultra:~# alsamixer
lqqqqqqqqqqqqqqqqqqqqqqqqqqqqq AlsaMixer v1.0.28 qqqqqqqqqqqqqqqqqqqqqqqqqqqqqqk
x Card: imx-audio-sgtl5000                             F1:  Help               x
x Chip:                                                F2:  System information x
x View: F3:[Playback] F4: Capture  F5: All             F6:  Select sound card  x
x Item: Headphone [dB gain: -20.00, -20.00]            Esc: Exit               x
x                                                                              x
x     lqqk                       lqqk     lqqk                                 x
x     x  x                       x  x     x  x                                 x
x     x  x                       x  x     x  x                                 x
x     x  x                       x  x     x  x                                 x
x     x  x                       xaax     x  x                                 x
x     x  x                       xaax     x  x                                 x
x     x  x                       xaax     x  x                                 x
x     x  x                       xaax     x  x                                 x
x     x  x                       xaax     x  x                                 x
x     x  x                       xaax     x  x                                 x
x     xaax                       xaax     x  x                                 x
x     xaax                       xaax     x  x                                 x
x     mqqj     DAC      lqqk     mqqj     mqqj     lqqk    MIC_IN    lqqk      x
x                       xOOx                       xMMx              xOOx      x
x                       mqqj                       mqqj              mqqj      x
x    23<>23                     75<>75     0                                   x
x  <Headphon>Headphon Headphon   PCM      Mic    Capture  Capture  Capture     x
mqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqj

Input: Boot-up module with HDMI cable plugged in, connect headphones into LINE_OUT connector and plug-in USB flash drive with MP3 file
Output: Sound is played and heard

root@imx6-rexultra:~# aplay -D sysdefault:CARD=sgtl5000audio multimedia/sample.wav
#root@imx6-rexultra:~# aplay -D sysdefault:CARD=imxaudiosgtl500 multimedia/sample.wav 
Playing WAVE 'multimedia/sample.wav' : Signed 16 bit Little Endian, Rate 44100 Hz, Stereo
root@imx6-rexultra:~# aplay -D sysdefault:CARD=imxhdmisoc multimedia/sample.wav 
Playing WAVE 'multimedia/sample.wav' : Signed 16 bit Little Endian, Rate 44100 Hz, Stereo

Input: Plug headphones into HEADPHONES connector and mic into MICROPHONE connector
Output: Microphone sound is played in headphones

root@imx6-rexultra:~# arecord -D sysdefault:CARD=sgtl5000audio -t wav -f cd | aplay -D sysdefault:CARD=imxaudiosgtl500
#root@imx6-rexultra:~# arecord -D sysdefault:CARD=imxaudiosgtl500 -t wav -f cd | aplay -D sysdefault:CARD=imxaudiosgtl500

Input: Plug headphones into HEADPHONES connector and mic into MICROPHONE connector
Output: Sound is recorded and played afterwards

root@imx6-rexultra:~# arecord -D sysdefault:CARD=sgtl5000audio -t wav -f cd -d 10 multimedia/recorded.wav 
#root@imx6-rexultra:~# arecord -D sysdefault:CARD=imxaudiosgtl500 -t wav -f cd -d 10 multimedia/recorded.wav 
Recording WAVE 'multimedia/recorded.wav' : Signed 16 bit Little Endian, Rate 44100 Hz, Stereo
root@imx6-rexultra:~# aplay -D sysdefault:CARD=sgtl5000audio multimedia/recorded.wav 
#root@imx6-rexultra:~# aplay -D sysdefault:CARD=imxaudiosgtl500 multimedia/recorded.wav 
Playing WAVE 'multimedia/recorded.wav' : Signed 16 bit Little Endian, Rate 44100 Hz, Stereo

User button

Input: Press and hold USER button (pca9535 driver is used)
Output: GPIO register is read and displayed state of the button

root@imx6-rexultra:~# echo 511 > /sys/class/gpio/export
root@imx6-rexultra:~# echo in > /sys/class/gpio/gpio511/direction
root@imx6-rexultra:~# cat /sys/class/gpio/gpio511/value
1
root@imx6-rexultra:~# cat /sys/class/gpio/gpio511/value
0

Reset button

Input: Press the RESET button
Output: Module will execute bootloader immediately with "Reset cause: POR"
Note: Module should never freeze or hang after the reset button was pressed. Testing the operation 10 times gives a reliable result

U-Boot 2014.10-dirty (Mar 12 2016 - 11:34:54)

CPU:   Freescale i.MX6Q rev1.2 at 792 MHz
Reset cause: POR
Board: MX6 Rex - ultra
I2C:   ready
DRAM:  2 GiB
MMC:   FSL_SDHC: 0, FSL_SDHC: 1
SF: Detected SST25VF032B with page size 256 Bytes, erase size 4 KiB, total 4 MiB
*** Warning - bad CRC, using default environment

In:    serial
Out:   serial
Err:   serial
Net:   FEC [PRIME]
Hit any key to stop autoboot:  0

Ethernet

Input: None
Output: Device driver is available
Note: MAC address should be identical with the address on the sticker placed on module

root@imx6-rexultra:~# ip addr show dev eth0
2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP group default qlen 1000
    link/ether 00:0d:15:00:cc:e2 brd ff:ff:ff:ff:ff:ff
    inet6 fe80::20d:15ff:fe00:cce2/64 scope link

Input: Plug Ethernet cable into connector and issue DHCP command
Output: IPv4 address is assigned

root@imx6-rexultra:~# dmesg | tail
...
libphy: 2188000.ethernet:03 - Link is Up - 100/Full
IPv6: ADDRCONF(NETDEV_CHANGE): eth0: link becomes ready
root@imx6-rexultra:~# udhcpc -i eth0
udhcpc (v1.22.1) started
Sending discover...
Sending select for 192.168.0.178...
Lease of 192.168.0.178 obtained, lease time 600

HDMI Output

Input: Connect LCD monitor to the base board
Output: Desktop UI is displayed correctly
iMX6 TinyRex Development Kit-HDMI terminal.png

I2C

Input: Scan I2C bus 0
Output: Available devices:

  • SGTL5000 audio (0x0A)
root@imx6-rexultra:~# i2cdetect -y 0
     0  1  2  3  4  5  6  7  8  9  a  b  c  d  e  f
00:          -- -- -- -- -- -- -- UU -- -- -- -- -- 
10: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
20: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
30: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
40: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
50: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
60: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
70: -- -- -- -- -- -- -- --

Input: Scan I2C bus 1
Output: Available devices:

  • GPIO expander (0x27)
  • touchscreen TSC2007 (0x48)
  • HDMI Output EDID (0x50)
  • RTC clock (0x51)
  • EEPROM (0x57)

Note: HDMI monitor must be disconnected otherwise I2C bus 1 scanning bus might freeze.

root@imx6-rexultra:~# i2cdetect -y 1 
     0  1  2  3  4  5  6  7  8  9  a  b  c  d  e  f
00:          -- -- -- -- -- -- -- -- -- -- -- -- -- 
10: -- -- -- -- -- -- -- -- 18 -- -- -- -- -- -- -- 
20: -- -- -- -- -- -- -- UU -- -- -- -- -- -- -- -- 
30: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
40: -- -- -- -- -- -- -- -- UU -- -- -- -- -- -- -- 
50: UU UU -- -- -- -- -- UU -- -- -- -- -- -- -- -- 
60: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
70: -- -- -- -- -- -- -- --

Input: Scan I2C bus 2
Output: I2C bus 2 is allocated for external use via System Header

root@imx6-rexultra:~# i2cdetect -y 2
     0  1  2  3  4  5  6  7  8  9  a  b  c  d  e  f
00:          -- -- -- -- -- -- -- -- -- -- -- -- -- 
10: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
20: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
30: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
40: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
50: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
60: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
70: -- -- -- -- -- -- -- --

Input: Trigger I2C GPIO expander detection.
Output: GPIO expander is detected

root@imx6-rexultra:~# echo -n "1-0027" > /sys/bus/i2c/drivers/pca953x/unbind
root@imx6-rexultra:~# echo -n "1-0027" > /sys/bus/i2c/drivers/pca953x/bind
pca953x 1-0027: interrupt support not compiled in

Input: Trigger I2C RTC detection
Output: RTC is detected

root@imx6-rexultra:~# echo -n "1-0051" > /sys/bus/i2c/drivers/rtc-pcf8563/unbind
root@imx6-rexultra:~# echo -n "1-0051" > /sys/bus/i2c/drivers/rtc-pcf8563/bind
rtc-pcf8563 1-0051: chip found, driver version 0.4.3
rtc-pcf8563 1-0051: low voltage detected, date/time is not reliable.
rtc-pcf8563 1-0051: low voltage detected, date/time is not reliable.
rtc rtc1: invalid alarm value: 2030-10-20 41:58:0
rtc-pcf8563 1-0051: rtc core: registered rtc-pcf8563 as rtc1

Input: Trigger I2C EEPROM detection
Output: I2C EEPROM is detected

root@imx6-rexultra:~# echo -n "1-0057" > /sys/bus/i2c/drivers/at24/unbind
root@imx6-rexultra:~# echo -n "1-0057" > /sys/bus/i2c/drivers/at24/bind 
at24 1-0057: 256 byte 24c02 EEPROM, writable, 1 bytes/write

Input: Write and read data from I2C EEPROM
Output: If successful, console text 'Data are the same' should appear

root@imx6-rexultra:~# echo -n "0123" > eeprom_in
root@imx6-rexultra:~# cat eeprom_in > /sys/bus/i2c/devices/1-0057/eeprom
root@imx6-rexultra:~# head -c 4 /sys/bus/i2c/devices/1-0057/eeprom > eeprom_out
root@imx6-rexultra:~# diff eeprom_in eeprom_out && echo "Data are the same"
Data are the same

Alternative test

Input: List I2C bus 0, 1 and 2
Output: Available devices are displayed

root@imx6-rexultra:~# ls /sys/bus/i2c/devices/i2c-0 | grep ^[0]
0-000a
root@imx6-rexultra:~# ls /sys/bus/i2c/devices/i2c-1 | grep ^[1]
1-0048
1-0050
root@imx6-rexultra:~# ls /sys/bus/i2c/devices/i2c-2 | grep ^[2]

User LED

Input: None
Output: Red LED assembled on module switches from ON to OFF state with heartbeat pulses afterwards

root@imx6-rexultra:~# echo -n "none" > /sys/devices/soc0/leds*/leds/module-led/trigger 
root@imx6-rexultra:~# echo -n "1" > /sys/devices/soc0/leds*/leds/module-led/brightness
root@imx6-rexultra:~# echo -n "0" > /sys/devices/soc0/leds*/leds/module-led/brightness
root@imx6-rexultra:~# echo -n "heartbeat" >  /sys/devices/soc0/leds*/leds/module-led/trigger

Input: GPIO expander PCA9535 driver
Output: Red LED assembled on the base board switches from ON to OFF state

root@imx6-rexultra:~# echo 510 > /sys/class/gpio/export
root@imx6-rexultra:~# echo out > /sys/class/gpio/gpio510/direction
root@imx6-rexultra:~# echo 1 > /sys/class/gpio/gpio510/value
root@imx6-rexultra:~# echo 0 > /sys/class/gpio/gpio510/value

LVDS display

Details how to properly connect display with LVDS and touchsreen interfaces are described on Display Set page.

Input: Configure U-Boot video environment and boot up the module
Output: GUI can be seen on LVDS screen

Rex U-Boot > setenv video 'video=mxcfb0:dev=ldb,edt570,if=RGB666 video=mxcfb1:off'
Rex U-Boot > boot

DDR memory

Input: None
Output: Memory test passes without any errors

root@imx6-rexultra:~# memtester 2G 1   
memtester version 4.1.3 (32-bit)
Copyright (C) 2010 Charles Cazabon.
Licensed under the GNU General Public License version 2 (only).

pagesize is 4096
pagesizemask is 0xfffff000
want 2048MB (2147483648 bytes)
got  267MB (280412160 bytes), trying mlock ...locked.
Loop 1/1:
  Stuck Address       : ok         
  Random Value        : ok
  Compare XOR         : ok
  Compare SUB         : ok
  Compare MUL         : ok
  Compare DIV         : ok
  Compare OR          : ok
  Compare AND         : ok
  Sequential Increment: ok
  Solid Bits          : ok         
  Block Sequential    : ok         
  Checkerboard        : ok         
  Bit Spread          : ok         
  Bit Flip            : ok         
  Walking Ones        : ok         
  Walking Zeroes      : ok         

Done.


Further information about DDR3 memories and its calibration can be accessed in Memory Calibration details.

Modem

Input: Plug HE910 3G card into PCIe mini 2 slot and plug SIM card into SIM1 slot
Output: HE910 3G card is detected and AT commands executed

root@imx6-rexultra:~# lsusb | grep -i 1bc7
Bus 001 Device 003: ID 1bc7:0021 Telit HE910
root@imx6-rexultra:~# cat > /etc/minirc.he910 << EOF
pu port             /dev/ttyACM0
pu baudrate         115200
pu bits             8
pu parity           N
pu stopbits         1
pu rtscts           No
pu xonxoff          No
pu escape-key       ^B
EOF
root@imx6-rexultra:~# echo "Press 'Ctrl+B z q' to exit"
root@imx6-rexultra:~# minicom -o he910
AT
AT+CPIN?
AT+CREG?
AT+COPS?

Log:

AT
OK
AT+CPIN?
+CPIN: READY

OK
AT+CREG?
+CREG: 0,1

OK
AT+COPS?
+COPS: 0,0,"Vodafone",0

OK

PCI Express

The procedure uses a WiFi wireless card to test PCIe interface. More details concerning wireless cards are located on WiFi and Bluetooth Cards page .

Input: Plug Wireless WiFi Link 4965AGN mini PCIe card into mini PCIe slot 1
Output: Card is detected by system

root@imx6-rexultra:~# lspci 
00:00.0 PCI bridge: Device 16c3:abcd (rev 01)
01:00.0 Network controller: Intel Corporation PRO/Wireless 4965 AG or AGN [Kedron] Network Connection (rev 61)

Input: Plug Wireless WiFi Link 4965AGN mini PCIe card into mini PCIe slot 1
Output: Wireless WiFi card firmware is loaded

root@imx6-rexultra:~# dmesg | grep iwl4965
iwl4965: Intel(R) Wireless WiFi 4965 driver for Linux, in-tree:
iwl4965: Copyright(c) 2003-2011 Intel Corporation
iwl4965 0000:01:00.0: Detected Intel(R) Wireless WiFi Link 4965AGN, REV=0x4
iwl4965 0000:01:00.0: device EEPROM VER=0x36, CALIB=0x5
iwl4965 0000:01:00.0: Tunable channels: 13 802.11bg, 19 802.11a channels
iwl4965 0000:01:00.0: loaded firmware version 228.61.2.24

Input: Plug Wireless WiFi Link 4965AGN mini PCIe card into mini PCIe slot 1
Output: Card scans neighbour networks

root@imx6-rexultra:~# rfkill unblock wlan
root@imx6-rexultra:~# ip link set wlan0 up
IPv6: ADDRCONF(NETDEV_UP): wlan0: link is not ready
root@imx6-rexultra:~# iw dev wlan0 scan
BSS 20:aa:4b:7e:21:97(on wlan0)
        TSF: 9263203904202 usec (107d, 05:06:43)
        freq: 5220
        beacon interval: 100 TUs
        capability: ESS Privacy ShortPreamble (0x0031)
        signal: -69.00 dBm
        last seen: 0 ms ago
        SSID: OpenWrt5g
        Supported rates: 6.0* 9.0 12.0* 18.0 24.0* 36.0 48.0 54.0 
        DS Parameter set: channel 44
        Country: CZ     Environment: Indoor/Outdoor
                Channels [36 - 48] @ 23 dBm
        RSN:     * Version: 1
                 * Group cipher: CCMP
                 * Pairwise ciphers: CCMP
                 * Authentication suites: PSK
                 * Capabilities: 16-PTKSA-RC 1-GTKSA-RC (0x000c)
        WPA:     * Version: 1
                 * Group cipher: CCMP
                 * Pairwise ciphers: CCMP
                 * Authentication suites: PSK
        Extended capabilities: 6
        WMM:     * Parameter version 1
                 * BE: CW 15-1023, AIFSN 3
                 * BK: CW 15-1023, AIFSN 7
                 * VI: CW 7-15, AIFSN 2, TXOP 3008 usec
                 * VO: CW 3-7, AIFSN 2, TXOP 1504 usec

Alternative test

Input: Plug Wireless WiFi Link 4965AGN mini PCIe card into mini PCIe slot 1
Output: Card scans neighbour networks

root@imx6-rexultra:~# ip link set wlan0 up
IPv6: ADDRCONF(NETDEV_UP): wlan0: link is not ready
root@imx6-rexultra:~# iwlist wlan0 scan
wlan0     Scan completed :
          Cell 01 - Address: 20:AA:4B:7E:21:97
                    Channel:44
                    Frequency:5.22 GHz (Channel 44)
                    Quality=39/70  Signal level=-71 dBm  
                    Encryption key:on
                    ESSID:"OpenWrt5g"
                    Bit Rates:6 Mb/s; 9 Mb/s; 12 Mb/s; 18 Mb/s; 24 Mb/s
                              36 Mb/s; 48 Mb/s; 54 Mb/s
                    Mode:Master
                    Extra:tsf=0000086d2e342cf9
                    Extra: Last beacon: 40ms ago
                    IE: Unknown: 00094F70656E5772743567
                    IE: Unknown: 01088C129824B048606C
                    IE: Unknown: 03012C
                    IE: Unknown: 0706435A20240417
                    IE: IEEE 802.11i/WPA2 Version 1
                        Group Cipher : CCMP
                        Pairwise Ciphers (1) : CCMP
                        Authentication Suites (1) : PSK
                    IE: WPA Version 1
                        Group Cipher : CCMP
                        Pairwise Ciphers (1) : CCMP
                        Authentication Suites (1) : PSK
                    IE: Unknown: 7F080000000000000040
                    IE: Unknown: DD180050F2020101000003A4000027A4000042435E0062322F00

SATA

Input: Power off the base board, connect HDD to SATA connector, provide power for the hard drive and turn on the board
Output: HDD is detected

root@imx6-rexultra:~# dmesg | grep -i -e sata -e ata1
ahci-imx 2200000.sata: fsl,transmit-level-mV not specified, using 00000024
ahci-imx 2200000.sata: fsl,transmit-boost-mdB not specified, using 00000480
ahci-imx 2200000.sata: fsl,transmit-atten-16ths not specified, using 00002000
ahci-imx 2200000.sata: fsl,receive-eq-mdB not specified, using 05000000
ahci-imx 2200000.sata: SSS flag set, parallel bus scan disabled
ahci-imx 2200000.sata: AHCI 0001.0300 32 slots 1 ports 3 Gbps 0x1 impl platform mode
ahci-imx 2200000.sata: flags: ncq sntf stag pm led clo only pmp pio slum part ccc apst 
ata1: SATA max UDMA/133 mmio [mem 0x02200000-0x02203fff] port 0x100 irq 306
ata1: SATA link down (SStatus 0 SControl 300)
ahci-imx 2200000.sata: no device found, disabling link.
ahci-imx 2200000.sata: pass ahci_imx..hotplug=1 to enable hotplug

SATA device can be used as a default filesystem source. SATA Interface page contains detailed steps to follow. iMX6 Rex Deveploment Kit gives an alternate option of utilizing SATA interface and reliabale storage by supporting CFast Cards.

SD card

Top slot SD card (mmcblk1)

Input: Plug and unplug SD card
Output: Kernel log shows that mmc1 device is added and removed

root@imx6-rexultra:~# dmesg | tail
...
mmc1: new high speed SDHC card at address e624
mmcblk1: mmc1:e624 SU08G 7.40 GiB 
 mmcblk1: p1 p2
FAT-fs (mmcblk1p1): Volume was not properly unmounted. Some data may be corrupt. Please run fsck.
EXT4-fs (mmcblk1p2): recovery complete
EXT4-fs (mmcblk1p2): mounted filesystem with ordered data mode. Opts: (null)
mmc1: card e624 removed

Bottom slot SD card (mmcblk2)

Input: Plug SD card with a filesystem and boot-up the module
Output: Module boots up successfully

root@imx6-rexultra:~# dmesg | grep -i "Kernel command line"
Kernel command line: console=ttymxc0,115200 root=/dev/mmcblk2p2 rootwait rw

SPI Flash Memory

Input: Trigger M25P80 flash detection
Output: SPI Flash sst25vf016b(sst25vf032b) is detected

root@imx6-rexultra:~# echo -n "spi2.0" > /sys/bus/spi/drivers/m25p80/unbind
root@imx6-rexultra:~# echo -n "spi2.0" > /sys/bus/spi/drivers/m25p80/bind 
m25p80 spi2.0: found sst25vf032b, expected m25p32
m25p80 spi2.0: sst25vf032b (4096 Kbytes)

Input: Write and read data from M25P80 flash
Output: If successful, console text 'Data are the same' should appear

root@imx6-rexultra:~# echo -n "0123" > mtd_in
root@imx6-rexultra:~# mtd_debug write /dev/mtd0 0 4 mtd_in 
Copied 4 bytes from mtd_in to address 0x00000000 in flash
root@imx6-rexultra:~# mtd_debug read /dev/mtd0 0 4 mtd_out
Copied 4 bytes from address 0x00000000 in flash to mtd_out
root@imx6-rexultra:~# diff mtd_in mtd_out && echo "Data are the same"
Data are the same

UART serial console

Input: Connect RS-232 cable into the base board connector and open serial console with baud rate 115200 8n1
Output: The board is controlled and responsive to serial terminal commands

root@imx6-rexultra:~# uname -a
Linux imx6-rexultra 3.14.58-yocto+g11e5ba3 #1 SMP PREEMPT Sun Mar 13 20:20:31 CET 2016 armv7l GNU/Linux

USB

Input: Plug USB flash drive with single VFAT partition into the bottom USB connector
Output: Filesystem recognises the flash drive and automatically mounts it. SMC Hub with ID 0424:2514 is mounted

root@imx6-rexultra:~# lsusb
Bus 001 Device 003: ID 1bc7:0021 Telit HE910
Bus 001 Device 005: ID 054c:0243 Sony Corp. MicroVault Flash Drive
Bus 001 Device 004: ID 0930:6544 Toshiba Corp. Kingston DataTraveler 2.0 Stick (2GB)
Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 001 Device 002: ID 0424:2514 Standard Microsystems Corp. USB 2.0 Hub
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

root@imx6-rexultra:~# mount | grep /run/media/sd*
/dev/sda1 on /run/media/sda1 type vfat (rw,relatime,gid=6,fmask=0007,dmask=0007,allow_utime=0020,codepage=437,iocharset=iso8859-1,shortname=mixed,errors=remount-ro)

Input: Generate a dummy file and copy it into USB flash drive
Output: Generated file and copied file have the same checksum

root@imx6-rexultra:~# rm -f file.txt /run/media/sda1/file.txt 
root@imx6-rexultra:~# dd if=/dev/urandom of=file.txt count=1024 bs=1024
1024+0 records in
1024+0 records out
1048576 bytes (1.0 MB) copied, 0.435456 s, 2.4 MB/s
root@imx6-rexultra:~# cp file.txt /run/media/sda1/
root@imx6-rexultra:~# md5sum file.txt /run/media/sda1/file.txt
33ef96efccbbf570bfce477735ed2068  file.txt
33ef96efccbbf570bfce477735ed2068  /run/media/sda1/file.txt
root@imx6-rexultra:~# rm file.txt /run/media/sda1/file.txt

USB OTG

Input: Load USB serial gadget driver and connect base board to host PC over micro USB cable
Output: Driver is successfully loaded and host PC detects a new USB serial gadget device

iMX6 Rex Development Kit:

root@imx6-rexultra:~# modprobe -i g_serial
g_serial gadget: Gadget Serial v2.4
g_serial gadget: g_serial ready
root@imx6-rexultra:~# g_serial gadget: high-speed config #2: CDC ACM config

Host PC:

user@voipac:~$ lsusb 
...
Bus 001 Device 014: ID 0525:a4a7 Netchip Technology, Inc. Linux-USB Serial Gadget (CDC ACM mode)
...

Touchscreen

Details how to properly connect display with LVDS and touchsreen interfaces are described on Display Set page.

Input: Search kernel log for TSC2007 chip
Output: TSC2007 chip is detected and bound as an input device

root@imx6-rexultra:~# dmesg | grep -i tsc2007
input: TSC2007 Touchscreen as /devices/soc0/soc.0/2100000.aips-bus/21a4000.i2c/i2c-1/1-0048/input/input0
evbug: Connected device: input0 (TSC2007 Touchscreen at 1-0048/input0)

Input: Press the touchscreen
Output: Touchscreen events are generated

root@imx6-rexultra:~# evtest /dev/input/by-path/platform-21a4000.i2c-event 
Input driver version is 1.0.1
Input device ID: bus 0x18 vendor 0x0 product 0x0 version 0x0
Input device name: "TSC2007 Touchscreen"
Supported events:
  Event type 0 (EV_SYN)
  Event type 1 (EV_KEY)
    Event code 330 (BTN_TOUCH)
  Event type 3 (EV_ABS)
    Event code 0 (ABS_X)
      Value   3529
      Min        0
      Max     4095
    Event code 1 (ABS_Y)
      Value    375
      Min        0
      Max     4095
    Event code 24 (ABS_PRESSURE)
      Value      0
      Min        0
      Max     4095
Properties:
Testing ... (interrupt to exit)
Event: time 1457899907.959665, type 1 (EV_KEY), code 330 (BTN_TOUCH), value 1
Event: time 1457899907.959665, type 3 (EV_ABS), code 0 (ABS_X), value 1657
Event: time 1457899907.959665, type 3 (EV_ABS), code 1 (ABS_Y), value 2486
Event: time 1457899907.959665, type 3 (EV_ABS), code 24 (ABS_PRESSURE), value 3268
Event: time 1457899907.959665, -------------- EV_SYN ------------
Event: time 1457899907.969094, type 1 (EV_KEY), code 330 (BTN_TOUCH), value 0
Event: time 1457899907.969094, type 3 (EV_ABS), code 24 (ABS_PRESSURE), value 0
Event: time 1457899907.969094, -------------- EV_SYN ------------

Alternative test

Input: Press the touchscreen
Output: Touchscreen events are generated

root@imx6-rexultra:~# hexdump -C /dev/input/event0 
00000000  79 ca e5 56 cd a3 07 00  01 00 4a 01 01 00 00 00  |y..V......J.....|
00000010  79 ca e5 56 cd a3 07 00  03 00 00 00 2f 08 00 00  |y..V......../...|
00000020  79 ca e5 56 cd a3 07 00  03 00 01 00 a7 07 00 00  |y..V............|
00000030  79 ca e5 56 cd a3 07 00  03 00 18 00 64 06 00 00  |y..V........d...|
00000040  79 ca e5 56 cd a3 07 00  00 00 00 00 00 00 00 00  |y..V............|
00000050  79 ca e5 56 a7 c4 07 00  01 00 4a 01 00 00 00 00  |y..V......J.....|
00000060  79 ca e5 56 a7 c4 07 00  03 00 18 00 00 00 00 00  |y..V............|
00000070  79 ca e5 56 a7 c4 07 00  00 00 00 00 00 00 00 00  |y..V............|