Difference between revisions of "iMX6 OpenRex Environmental chamber testing"
(9 intermediate revisions by the same user not shown) | |||
Line 18: | Line 18: | ||
** 1GBps Ethernet PHY Tranciever KSZ9021RNI - automotive temperature range (-40°C to +85°C) | ** 1GBps Ethernet PHY Tranciever KSZ9021RNI - automotive temperature range (-40°C to +85°C) | ||
<br /> | <br /> | ||
− | Two versions of heatsink were selected. | + | Two versions of heatsink were selected for the test. The large nonstandard heatsink covered area occupied by CPU, memories and Ethernet PHY chip. The standard 14x14x14mm heatsink shipped with each SBC, and covering just the CPU, was also tested. No significant performance differences were observed.<br /><br /> |
The setup in the environmental chamber:<br /> | The setup in the environmental chamber:<br /> | ||
− | [[image:iMX6_OpenRex_SBC-Environmental_chamber-Boards.jpg| | + | [[image:iMX6_OpenRex_SBC-Environmental_chamber-Boards.jpg|750px]] |
== Test description == | == Test description == | ||
Three iMX6 OpenRex SBCs (one in Max and two in Basic configuration) were running full peripheral test to check functionality of all the peripherals in different range of temperatures. All the rest of the boards (three in Max and three in Basic version) were running CPU and memory tests to check the reliability of the firmware and hardware design. This included extensive examining of memory settings and used Fly-By Topology layout. Two DDR3 memory chips in Basic configuration were also thoroughly checked.<br /><br /> | Three iMX6 OpenRex SBCs (one in Max and two in Basic configuration) were running full peripheral test to check functionality of all the peripherals in different range of temperatures. All the rest of the boards (three in Max and three in Basic version) were running CPU and memory tests to check the reliability of the firmware and hardware design. This included extensive examining of memory settings and used Fly-By Topology layout. Two DDR3 memory chips in Basic configuration were also thoroughly checked.<br /><br /> | ||
− | [[image:iMX6_OpenRex_SBC-Environmental_chamber-Setup.jpg| | + | [[image:iMX6_OpenRex_SBC-Environmental_chamber-Setup.jpg|750px]] |
<br /><br /> | <br /><br /> | ||
Testing threads are described below:<br /><br /> | Testing threads are described below:<br /><br /> | ||
Line 61: | Line 61: | ||
== Testing Results == | == Testing Results == | ||
The picture below shows the temperature profile during the whole testing process:<br /> | The picture below shows the temperature profile during the whole testing process:<br /> | ||
− | [[image:iMX6_OpenRex_SBC-Environmental_chamber_Temperature_profile. | + | [[image:iMX6_OpenRex_SBC-Environmental_chamber_Temperature_profile.png|700px]] |
=== Running the boards at -60°C and -40°C – PASS === | === Running the boards at -60°C and -40°C – PASS === | ||
− | Test description: CPU, Memory and peripheral stress tests were running at these extremely low temepratures. All the tested | + | Test description: CPU, Memory and peripheral stress tests were running at these extremely low temepratures. All the tested SBCs were working without errors even when temperature reached -60°C.<br /><br /> |
'''''Note:''''' Initial testing revealed that Ethernet PHY KSZ9031 created the network communication malfunction at very low temperatures. This behaviour was caused by chip manufacturer issue as described in [https://ww1.microchip.com/downloads/en/DeviceDoc/80000692D.pdf Micrel errata]. After changing PHY controller to KSZ9021RN all the boards were working without errors. | '''''Note:''''' Initial testing revealed that Ethernet PHY KSZ9031 created the network communication malfunction at very low temperatures. This behaviour was caused by chip manufacturer issue as described in [https://ww1.microchip.com/downloads/en/DeviceDoc/80000692D.pdf Micrel errata]. After changing PHY controller to KSZ9021RN all the boards were working without errors. | ||
=== Running the boards at +65°C – PASS === | === Running the boards at +65°C – PASS === | ||
− | Test description: The ambient temperature was gradually increasing (to +55°C, +60°C and +65°C) and we were running the CPU, Memory and peripheral stress tests. Even at +65°C processors were running at full speed (frequency was not lowered by the system to cool down the CPU). Reaching higher temperature is possible by using a bigger and more massive heatsink. | + | Test description: The ambient temperature was gradually increasing (to +55°C, +60°C and +65°C) and we were running the CPU, Memory and peripheral stress tests. Even at +65°C processors were running at full speed (frequency was not lowered by the system to cool down the CPU). Reaching higher operating temperature is possible by using a bigger and more massive heatsink. |
<br /><br /> | <br /><br /> | ||
− | The boards were also tested with a small heatsink which is a part of the webshop iMX6 OpenRex SBC | + | The boards were also tested with a small heatsink which is a part of the webshop configuration of the iMX6 OpenRex SBC. This setup also reached temperatures above +65°C without any errors. |
<br /><br /> | <br /><br /> | ||
Temperature readout from boards when running at +65°C shows that the temperature inside the CPU was approximately 20°C to 30°C higher. Heatsink design influences this difference the most.<br /><br /> | Temperature readout from boards when running at +65°C shows that the temperature inside the CPU was approximately 20°C to 30°C higher. Heatsink design influences this difference the most.<br /><br /> | ||
− | [[image:iMX6_OpenRex_SBC-Environmental_chamber-Temperature_readout_at_+65_degC. | + | [[image:iMX6_OpenRex_SBC-Environmental_chamber-Temperature_readout_at_+65_degC.png|800px]] |
=== Switch ON/OFF test – PASS === | === Switch ON/OFF test – PASS === | ||
Line 90: | Line 90: | ||
== Setup preparation and testing recommendations == | == Setup preparation and testing recommendations == | ||
− | It is very important to run the exact same setup for environmental chamber testing in the lab for couple of days. Use exactly the same boards, board setup, cables, | + | It is very important to run the exact same setup for environmental chamber testing in the lab for couple of days. Use exactly the same boards, board setup, cables, PCs and all other equipment. The main reason to do this is to minimise possible issues with testing scripts or faulty connections – everything has to be running smoothly. During the boards performance temperature testing, there will be little time to fix those avoidable problems.<br /><br /> |
− | The next very important thing is to make as many notes as possible during the testing. Always add board number and date to the message. This will help to | + | The next very important thing is to make as many notes as possible during the testing. Always add board number and date to the message. This will help to memorise everything and no important detail will be missed in the report.<br /><br /> |
To get reliable results, running 4 boards is advised at minimum, 6-10 boards is recommended. This amount of boards, cables and equipment require a special precautions to avoid confusion. Thus marking all the boards and important cables is a very useful habit.<br /><br /> | To get reliable results, running 4 boards is advised at minimum, 6-10 boards is recommended. This amount of boards, cables and equipment require a special precautions to avoid confusion. Thus marking all the boards and important cables is a very useful habit.<br /><br /> | ||
Line 114: | Line 114: | ||
=== Setting the network === | === Setting the network === | ||
Disable firewall (PC will not be connected to the Internet) and setup a static IP address: Press Windows button -> go to Control Panel -> Network and Internet -> Network and Sharing Center -> Change adapter settings (on the right side in the bar) -> double click on Local Area Connection -> Properties -> In the tab Networking go to Internet Protocol Version 4 (TCP/IPv4) -> type the static IP address and subnet mask as shown below:<br /> | Disable firewall (PC will not be connected to the Internet) and setup a static IP address: Press Windows button -> go to Control Panel -> Network and Internet -> Network and Sharing Center -> Change adapter settings (on the right side in the bar) -> double click on Local Area Connection -> Properties -> In the tab Networking go to Internet Protocol Version 4 (TCP/IPv4) -> type the static IP address and subnet mask as shown below:<br /> | ||
− | [[image:iMX6_OpenRex_SBC-Environmental_chamber-Static_IP. | + | [[image:iMX6_OpenRex_SBC-Environmental_chamber-Static_IP.png|400px]] |
=== Enabling sharing === | === Enabling sharing === | ||
iMX6 OpenRex SBCs and the control PC are connected via Gigabit Ethernet switch. To ensure correct IP address assignment, turn on the PC first, connect it with the switch and only after that turn the switch on. To be able to download the files from the FTP server, sharing option need to be enabled first. This can be done by setting up the network as a ''work network''. Sharing can be enabled in Control Panel -> Network and Internet -> Network and Sharing Center -> Click to Choose homegroup and sharing options:<br /> | iMX6 OpenRex SBCs and the control PC are connected via Gigabit Ethernet switch. To ensure correct IP address assignment, turn on the PC first, connect it with the switch and only after that turn the switch on. To be able to download the files from the FTP server, sharing option need to be enabled first. This can be done by setting up the network as a ''work network''. Sharing can be enabled in Control Panel -> Network and Internet -> Network and Sharing Center -> Click to Choose homegroup and sharing options:<br /> | ||
− | [[image:iMX6_OpenRex_SBC-Environmental_chamber-Network_setup. | + | [[image:iMX6_OpenRex_SBC-Environmental_chamber-Network_setup.png|710px]] |
=== Setting up the TFTP and DHCP servers === | === Setting up the TFTP and DHCP servers === | ||
− | Tftpd32 software supports both TFTP and DHCP server options. For more details about DHCP configuration, follow the screenshots below: | + | Tftpd32 software supports both TFTP and DHCP server options. For more details about DHCP configuration, follow the screenshots below:<br /> |
− | + | |[[image:iMX6_OpenRex_SBC-Environmental_chamber-DHCP_setting.png|360px]]<br /><br /> | |
− | |[[image:iMX6_OpenRex_SBC-Environmental_chamber-DHCP_setting. | + | |[[image:iMX6_OpenRex_SBC-Environmental_chamber-DHCP.png|460px]] |
− | |[[image:iMX6_OpenRex_SBC-Environmental_chamber-DHCP. | ||
− | |||
=== Starting time server === | === Starting time server === | ||
To assign the correct time for all the boards Time server feature built in Tftpd32 was used. Go to ''Settings'' and make sure that ''SNTP server'' is checked:<br /> | To assign the correct time for all the boards Time server feature built in Tftpd32 was used. Go to ''Settings'' and make sure that ''SNTP server'' is checked:<br /> | ||
− | |[[image:iMX6_OpenRex_SBC-Environmental_chamber-SNTP_server. | + | |[[image:iMX6_OpenRex_SBC-Environmental_chamber-SNTP_server.png|360px]] |
=== Assigning custom COM port names === | === Assigning custom COM port names === | ||
As we mentioned before, it is useful to apply the same numbering for boards and serial ports. To do so plug in the first FTDI cable and go to the control PC, select Start, right click on Computer and select Properties. Now click on the Device Manager in the top right corner. Under the item Ports (COM & LPT), USB ports are visible. Now right click and select Properties:<br /> | As we mentioned before, it is useful to apply the same numbering for boards and serial ports. To do so plug in the first FTDI cable and go to the control PC, select Start, right click on Computer and select Properties. Now click on the Device Manager in the top right corner. Under the item Ports (COM & LPT), USB ports are visible. Now right click and select Properties:<br /> | ||
− | |[[image:iMX6_OpenRex_SBC-Environmental_chamber-COM_Port_properties. | + | |[[image:iMX6_OpenRex_SBC-Environmental_chamber-COM_Port_properties.png|580px]] |
<br /><br /> | <br /><br /> | ||
Select the Port Settings tab and click on Advanced tab:<br /> | Select the Port Settings tab and click on Advanced tab:<br /> | ||
− | |[[image:iMX6_OpenRex_SBC-Environmental_chamber-COM_Port_settings. | + | |[[image:iMX6_OpenRex_SBC-Environmental_chamber-COM_Port_settings.png|400px]] |
<br /><br /> | <br /><br /> | ||
Now select from the COM Port Number (the one which is not in use):<br /> | Now select from the COM Port Number (the one which is not in use):<br /> | ||
− | [[image:iMX6_OpenRex_SBC-Environmental_chamber-COM_Port_number. | + | [[image:iMX6_OpenRex_SBC-Environmental_chamber-COM_Port_number.png|630px]] |
<br /><br /> | <br /><br /> | ||
− | Now this process can be repeated by plugging another serial cable if needed. After all the | + | Now this process can be repeated by plugging another serial cable if needed. After all the cables were attached, restart the computer. |
=== SSH and Serial consoles === | === SSH and Serial consoles === | ||
To control iMX6 OpenRex SBCs, one TeraTerm serial console was opened per board. SSH clients were used to read temperature. For the boards with the peripheral test, an extra SSH client was established to be able to spot possible errors or warnings if occurred.<br /> | To control iMX6 OpenRex SBCs, one TeraTerm serial console was opened per board. SSH clients were used to read temperature. For the boards with the peripheral test, an extra SSH client was established to be able to spot possible errors or warnings if occurred.<br /> | ||
− | [[image:iMX6_OpenRex_SBC-Environmental_chamber-Serial_console. | + | [[image:iMX6_OpenRex_SBC-Environmental_chamber-Serial_console.png|800px]] |
== Preparing the test == | == Preparing the test == | ||
=== Boot device and software === | === Boot device and software === | ||
+ | All the boards were using bootloader stored in SPI flash memory with the rest of firmware located on SD card. The only exception was moving the filesystem to either SATA disk (Max version) or USB flash drive (Basic configuration) for peripheral tests.<br /><br /> | ||
+ | |||
The only change compared to standard software package was running a multimedia filesystem. U-Boot settings were not adjusted as the default configuration was used. To prepare a fresh SD card follow [[iMX6 OpenRex Max Creating Bootable microSD Card|these instructions]]. Here is an example of creating a SD card suitable for Max configuration: | The only change compared to standard software package was running a multimedia filesystem. U-Boot settings were not adjusted as the default configuration was used. To prepare a fresh SD card follow [[iMX6 OpenRex Max Creating Bootable microSD Card|these instructions]]. Here is an example of creating a SD card suitable for Max configuration: | ||
<syntaxhighlight lang="bash"> | <syntaxhighlight lang="bash"> | ||
Line 156: | Line 156: | ||
gunzip -c fsl-image-gui-imx6-openrexmax-2.4.sdcard.gz | sudo dd of=/dev/mmcblk0 conv=sync bs=64K | gunzip -c fsl-image-gui-imx6-openrexmax-2.4.sdcard.gz | sudo dd of=/dev/mmcblk0 conv=sync bs=64K | ||
</syntaxhighlight> | </syntaxhighlight> | ||
− | |||
− | |||
=== Creating new directories and copying test files === | === Creating new directories and copying test files === | ||
Line 198: | Line 196: | ||
<syntaxhighlight lang="bash"> | <syntaxhighlight lang="bash"> | ||
cd /home/ubuntu/openrex/env-chamber-testing/ | cd /home/ubuntu/openrex/env-chamber-testing/ | ||
− | tail - | + | tail -f orx-cpu-temp.log |
</syntaxhighlight> | </syntaxhighlight> | ||
Line 264: | Line 262: | ||
</syntaxhighlight> | </syntaxhighlight> | ||
− | The testing script uses multiple variables to specify its operation. As the first parameter board configuration is used (-max | + | The testing script uses multiple variables to specify its operation. As the first parameter board configuration is used (-max or -basic). As other parameters device names |
are written in the following order: the first USB stick, the second USB, SD card and SATA drive (if used). All logs are stored into a single file.<br /><br /> | are written in the following order: the first USB stick, the second USB, SD card and SATA drive (if used). All logs are stored into a single file.<br /><br /> | ||
Starting peripheral test for Max configuration: | Starting peripheral test for Max configuration: | ||
<syntaxhighlight lang="bash"> | <syntaxhighlight lang="bash"> | ||
− | ./openrex-env-chamber-test.sh - | + | ./openrex-env-chamber-test.sh -max sdb1 sdc1 mmcblk1p2 sda1 2>&1 | tee -i orx-env-chamber-testing.log |
</syntaxhighlight> | </syntaxhighlight> | ||
Starting peripheral test for Basic configuration: | Starting peripheral test for Basic configuration: | ||
<syntaxhighlight lang="bash"> | <syntaxhighlight lang="bash"> | ||
− | ./openrex-env-chamber-test.sh - | + | ./openrex-env-chamber-test.sh -basic sda1 sdb1 mmcblk1p2 2>&1 | tee -i orx-env-chamber-testing.log |
</syntaxhighlight> | </syntaxhighlight> | ||
Line 281: | Line 279: | ||
#!/bin/sh | #!/bin/sh | ||
− | # | + | # OpenRex environmental chamber testing script |
− | + | ||
+ | # Example QUAD: ./openrex-env-chamber-test.sh -quad sdb1 sdc1 mmcblk0p1 sda1 2>&1 | tee -i orx-env-chamber-testing.log | ||
+ | # Example SOLO: ./openrex-env-chamber-test.sh -solo sda1 sdb1 mmcblk0p1 2>&1 | tee -i orx-env-chamber-testing.log | ||
+ | |||
mountDevice() { | mountDevice() { | ||
mount /dev/$1 /media/$2 | mount /dev/$1 /media/$2 | ||
Line 293: | Line 294: | ||
} | } | ||
− | # prepare files | + | # prepare files if needed |
− | + | touch orx-env-chamber-testing.log | |
− | + | touch orx-cpu-temp.log | |
− | + | ||
− | + | echo -e '\033[9;0]' > /dev/tty1 # disable blanking the display | |
− | touch | ||
− | touch | ||
− | + | imx6solo=0 | |
− | + | imx6quad=0 | |
− | |||
case $1 in | case $1 in | ||
− | -basic) | + | -basic) imx6solo=1 ;; |
− | + | -max) imx6quad=1 ;; | |
− | -max) | ||
*) | *) | ||
esac | esac | ||
− | + | ||
# mount devices | # mount devices | ||
mountDevice $2 usb0 | mountDevice $2 usb0 | ||
mountDevice $3 usb1 | mountDevice $3 usb1 | ||
mountDevice $4 mmc0 | mountDevice $4 mmc0 | ||
− | if [ "${ | + | if [ "${imx6quad}" -eq "1" ]; then |
mountDevice $5 sata | mountDevice $5 sata | ||
fi | fi | ||
Line 324: | Line 321: | ||
# be sure time server is running on DHCP server | # be sure time server is running on DHCP server | ||
currentTime=`date +%Y-%m-%d.%H:%M` | currentTime=`date +%Y-%m-%d.%H:%M` | ||
− | + | ||
− | mv | + | mv orx-env-chamber-testing.log orx-board-$boardID-env-chamber.log.$currentTime |
− | mv | + | mv orx-cpu-temp.log orx-board-$boardID-env-cpu-temp.log.$currentTime |
+ | |||
+ | touch orx-env-chamber-testing.log | ||
+ | touch orx-cpu-temp.log | ||
} | } | ||
Line 332: | Line 332: | ||
echo "$(date +\%Y/\%m/\%d-\%T)($(date +\%Z)) Ctrl+C Detected: End of the test" | echo "$(date +\%Y/\%m/\%d-\%T)($(date +\%Z)) Ctrl+C Detected: End of the test" | ||
precced=0; | precced=0; | ||
− | #kill -INT $vid_pid $str_pid | + | #kill -INT $vid_pid $str_pid; |
sleep 3; | sleep 3; | ||
− | test_status=`cat | + | test_status=`cat orx-env-chamber-testing.log | grep -i "error" | grep -v -e "0 errors" -e "no corrected errors"` |
if [ -z "$test_status" ] | if [ -z "$test_status" ] | ||
then | then | ||
− | echo "********* | + | echo "*********\nTEST PASS\n*********" |
else | else | ||
− | echo "********* | + | echo "*********\nTEST FAIL\n*********\n" |
echo "List of detected errors:" | echo "List of detected errors:" | ||
− | cat | + | cat orx-env-chamber-testing.log | grep -i "error" | grep -v -e "0 errors" -e "no corrected errors" -e "List of detected errors:" |
fi | fi | ||
updateLogFiles | updateLogFiles | ||
exit; | exit; | ||
} | } | ||
− | + | ||
# kill all processes if Ctrl+C is detected | # kill all processes if Ctrl+C is detected | ||
trap finish_test_now 2 | trap finish_test_now 2 | ||
− | + | # stressapptest - one thread CPU, one thread memory | |
− | + | if [ "${imx6solo}" -eq "1" ]; then | |
− | + | stressapptest -s 600000 -M 100 -m 1 -C 1 --printsec 10 & | |
− | # stressapptest - one thread CPU, one thread memory | ||
− | if [ "${ | ||
− | |||
− | |||
− | |||
− | |||
− | |||
str_pid=$! | str_pid=$! | ||
fi | fi | ||
− | if [ "${ | + | if [ "${imx6quad}" -eq "1" ]; then |
− | + | stressapptest -f /media/sata/tmp-file1 -s 600000 -M 500 -m 1 -C 1 --printsec 10 & | |
str_pid=$! | str_pid=$! | ||
fi | fi | ||
echo "$(date +\%Y/\%m/\%d-\%T)($(date +\%Z)) Starting stressapptest with PID: " $str_pid | echo "$(date +\%Y/\%m/\%d-\%T)($(date +\%Z)) Starting stressapptest with PID: " $str_pid | ||
− | + | ||
+ | # play a video file in an infinite loop | ||
+ | echo 0 > /sys/class/graphics/fb0/blank | ||
+ | mplayer -vo fbdev2:/dev/fb0 -quiet -vf scale -zoom -loop 0 -xy 1024 /home/ubuntu/Clouds.avi < /dev/null & | ||
+ | vid_pid=$! | ||
+ | echo "$(date +\%Y/\%m/\%d-\%T)($(date +\%Z)) Starting video file playback with PID: " $vid_pid | ||
+ | |||
proceed=1 | proceed=1 | ||
file1="blackbird.wav" | file1="blackbird.wav" | ||
Line 375: | Line 374: | ||
cp1_to="/media/usb0/" | cp1_to="/media/usb0/" | ||
− | cp2_from="/ | + | cp2_from="/home/ubuntu/" |
cp2_to="/media/usb1/" | cp2_to="/media/usb1/" | ||
Line 383: | Line 382: | ||
cp /media/$file2 $cp2_from$file2 | cp /media/$file2 $cp2_from$file2 | ||
cp /media/$file2 $cp2_to$file2 | cp /media/$file2 $cp2_to$file2 | ||
− | + | ||
while [ $proceed -eq 1 ] | while [ $proceed -eq 1 ] | ||
do | do | ||
− | ping -q -c1 192.168.0.2 >> | + | ping -q -c1 192.168.0.2 >> orx-env-chamber-testing.log |
if [ $? -ne 0 ] | if [ $? -ne 0 ] | ||
then | then | ||
echo "$(date +\%Y/\%m/\%d-\%T)($(date +\%Z)) ERROR: Ping failed" | echo "$(date +\%Y/\%m/\%d-\%T)($(date +\%Z)) ERROR: Ping failed" | ||
fi | fi | ||
− | + | ||
− | cp1_done=`ps | grep $cp1_pid | grep cp` | + | cp1_done=`ps cax | grep $cp1_pid | grep cp` |
if [ -z "$cp1_done" ]; then # copy finished | if [ -z "$cp1_done" ]; then # copy finished | ||
if cmp -s $cp1_from$file1 $cp1_to$file1; then | if cmp -s $cp1_from$file1 $cp1_to$file1; then | ||
Line 399: | Line 398: | ||
else | else | ||
echo "$(date +\%Y/\%m/\%d-\%T)($(date +\%Z)) ERROR: Difference between files on $cp1_from and $cp1_to detected" | echo "$(date +\%Y/\%m/\%d-\%T)($(date +\%Z)) ERROR: Difference between files on $cp1_from and $cp1_to detected" | ||
+ | cp /media/$file1 $cp1_to$file1 | ||
+ | echo "$(date +\%Y/\%m/\%d-\%T)($(date +\%Z)) File copied from /media/ to $cp1_to" | ||
fi | fi | ||
cp1_temp=$cp1_from # swap destinations | cp1_temp=$cp1_from # swap destinations | ||
cp1_from=$cp1_to | cp1_from=$cp1_to | ||
cp1_to=$cp1_temp | cp1_to=$cp1_temp | ||
− | + | ||
rm $cp1_to$file1 # remove destination file | rm $cp1_to$file1 # remove destination file | ||
− | + | ||
cp $cp1_from$file1 $cp1_to$file1 & | cp $cp1_from$file1 $cp1_to$file1 & | ||
cp1_pid=$! | cp1_pid=$! | ||
echo "$(date +\%Y/\%m/\%d-\%T)($(date +\%Z)) Started copying file from $cp1_from to $cp1_to" | echo "$(date +\%Y/\%m/\%d-\%T)($(date +\%Z)) Started copying file from $cp1_from to $cp1_to" | ||
fi | fi | ||
− | + | ||
− | cp2_done=`ps | grep $cp2_pid | grep cp` | + | cp2_done=`ps cax | grep $cp2_pid | grep cp` |
if [ -z "$cp2_done" ]; then # copy finished | if [ -z "$cp2_done" ]; then # copy finished | ||
if cmp -s $cp2_from$file2 $cp2_to$file2; then | if cmp -s $cp2_from$file2 $cp2_to$file2; then | ||
Line 417: | Line 418: | ||
else | else | ||
echo "$(date +\%Y/\%m/\%d-\%T)($(date +\%Z)) ERROR: Difference between files on $cp2_from and $cp2_to detected" | echo "$(date +\%Y/\%m/\%d-\%T)($(date +\%Z)) ERROR: Difference between files on $cp2_from and $cp2_to detected" | ||
+ | cp /media/$file2 $cp2_to$file2 | ||
+ | echo "$(date +\%Y/\%m/\%d-\%T)($(date +\%Z) File copied from /media/ to $cp2_to" | ||
fi | fi | ||
cp2_temp=$cp2_from # swap destinations | cp2_temp=$cp2_from # swap destinations | ||
cp2_from=$cp2_to | cp2_from=$cp2_to | ||
cp2_to=$cp2_temp | cp2_to=$cp2_temp | ||
− | + | ||
rm $cp2_to$file2 # remove destination file | rm $cp2_to$file2 # remove destination file | ||
− | + | ||
cp $cp2_from$file2 $cp2_to$file2 & | cp $cp2_from$file2 $cp2_to$file2 & | ||
cp2_pid=$! | cp2_pid=$! | ||
echo "$(date +\%Y/\%m/\%d-\%T)($(date +\%Z)) Started copying file from $cp2_from to $cp2_to" | echo "$(date +\%Y/\%m/\%d-\%T)($(date +\%Z)) Started copying file from $cp2_from to $cp2_to" | ||
fi | fi | ||
− | + | ||
done | done | ||
</syntaxhighlight> | </syntaxhighlight> |
Latest revision as of 22:04, 31 August 2021
On this page environmental stress testing results of iMX6 OpenRex SBC are displayed. Detailed instructions how to setup boards are also shown.
Hardware configuration
All of the boards used standard specification except of the temperature ranges for the key components. CPU with different frequency and increased operating range was selected for Basic version during the test. Details are described below:
- 4x iMX6 OpenRex SBC in Max configuration
- i.MX6 Quad 1.0 GHz CPU - automotive temperature range (-40°C to +125°C)
- 2GB DDR3 Memory (4x 4Gb DDR3 Memory chips) - industrial temperature range (-40°C to +95°C)
- 1GBps Ethernet PHY Tranciever KSZ9021RNI - automotive temperature range (-40°C to +85°C)
- 5x iMX6 OpenRex SBC in modified Basic configuration
- i.MX6 Solo 800 MHz CPU - industrial temperature range (-40°C to +105°C)
- 512MB DDR3 Memory (2x 2Gb DDR3 Memory chips) - industrial temperature range (-40°C to +95°C)
- 1GBps Ethernet PHY Tranciever KSZ9021RNI - automotive temperature range (-40°C to +85°C)
Two versions of heatsink were selected for the test. The large nonstandard heatsink covered area occupied by CPU, memories and Ethernet PHY chip. The standard 14x14x14mm heatsink shipped with each SBC, and covering just the CPU, was also tested. No significant performance differences were observed.
The setup in the environmental chamber:
Test description
Three iMX6 OpenRex SBCs (one in Max and two in Basic configuration) were running full peripheral test to check functionality of all the peripherals in different range of temperatures. All the rest of the boards (three in Max and three in Basic version) were running CPU and memory tests to check the reliability of the firmware and hardware design. This included extensive examining of memory settings and used Fly-By Topology layout. Two DDR3 memory chips in Basic configuration were also thoroughly checked.
Testing threads are described below:
3x iMX6 OpenRex peripheral stress testing
- 1 thread of extensive Memory stress test
- 1 thread of CPU stress test
- SATA stress test (applied for Max version only)
- video playing via HDMI output
- copying a file from the first USB drive to SD card and vice versa
- copying a file from the second USB device to SATA hard drive and vice versa (applied for Max version)
- copying a file from the second USB drive to SD card and vice versa (applied for Basic version)
- pinging the host PC via Ethernet
- all the messages were printed out on the serial console through connected FTDI cable
- booting device:
- SATA hard drive in Max configuration
- USB flash drive for Basic version
3x iMX6 OpenRex Max Memory stress testing
- 4 threads of extensive Memory stress test
- 4 threads of CPU stress test
- reading CPU temperature via SSH Ethernet session
- serial FTDI cable used for displaying messages
- firmware running from SD card
3x iMX6 OpenRex Basic Memory stress testing
- 1 threads of extensive Memory stress test
- 1 threads of CPU stress test
- reading CPU temperature via SSH Ethernet session
- serial FTDI cable used for displaying messages
- firmware running from SD card
USB flash devices and SATA hard drives were place outside the environmental chamber. All the scripts running during the test and the board setup instructions can be found in section How to prepare the test.
Testing Results
The picture below shows the temperature profile during the whole testing process:
Running the boards at -60°C and -40°C – PASS
Test description: CPU, Memory and peripheral stress tests were running at these extremely low temepratures. All the tested SBCs were working without errors even when temperature reached -60°C.
Note: Initial testing revealed that Ethernet PHY KSZ9031 created the network communication malfunction at very low temperatures. This behaviour was caused by chip manufacturer issue as described in Micrel errata. After changing PHY controller to KSZ9021RN all the boards were working without errors.
Running the boards at +65°C – PASS
Test description: The ambient temperature was gradually increasing (to +55°C, +60°C and +65°C) and we were running the CPU, Memory and peripheral stress tests. Even at +65°C processors were running at full speed (frequency was not lowered by the system to cool down the CPU). Reaching higher operating temperature is possible by using a bigger and more massive heatsink.
The boards were also tested with a small heatsink which is a part of the webshop configuration of the iMX6 OpenRex SBC. This setup also reached temperatures above +65°C without any errors.
Temperature readout from boards when running at +65°C shows that the temperature inside the CPU was approximately 20°C to 30°C higher. Heatsink design influences this difference the most.
Switch ON/OFF test – PASS
Test description: At temperatures -30°C, -35°C, -40°C and -45°C the boards were switched OFF, left OFF for at least 5 minutes (to cool down completely) and then switched ON to see if they boot up without any problem. Once booted up into Linux, the boards were turned off again. All of the tested boards booted up successfully. Tested at least one time for every temperature.
Temperature stress test – quick change from -60°C to -10°C and back – PASS
Test description: The ambient temperature was quickly increased from -60°C to -10°C and then back to -60°C. The boards were running CPU, Memory and peripheral stress tests. All the boards were working correctly.
Temperature stress test – quick change from +65°C to +40°C and back – PASS
Test description: The ambient temperature was quickly decreased from +65°C to +40°C and back to +65°C while running CPU, Memory and peripheral stress tests. All boards were working without errors.
Boards were tested in a very rugged environment (ice flaked forming on the rear window):
Setup preparation and testing recommendations
It is very important to run the exact same setup for environmental chamber testing in the lab for couple of days. Use exactly the same boards, board setup, cables, PCs and all other equipment. The main reason to do this is to minimise possible issues with testing scripts or faulty connections – everything has to be running smoothly. During the boards performance temperature testing, there will be little time to fix those avoidable problems.
The next very important thing is to make as many notes as possible during the testing. Always add board number and date to the message. This will help to memorise everything and no important detail will be missed in the report.
To get reliable results, running 4 boards is advised at minimum, 6-10 boards is recommended. This amount of boards, cables and equipment require a special precautions to avoid confusion. Thus marking all the boards and important cables is a very useful habit.
These are the most crucial hardware parts, which were marked prior the testing:
- Boards: place a sticker on a visible spot (e.g. USB or Ethernet connector). Use simple numbering (e.g. 1, 2, 3…)
- Serial consoles: mark both ends of the cable
- Adapters or power cables: mark both ends of the cable so resetting a single board becomes much easier
- USB memories and hard drives: if there is a problem with e.g. USB flash drive, it can be time saving to know which one to replace (marking used 1-USB1, 1-USB2, 2-USB1…)
Following the same pattern, software and connections was number in similar fashion:
- IP addresses: having the same address makes examining possible problems much easier. DHCP server which assigns the same IP address for one particular MAC address was used during the testing (e.g. board with mark 1 will always have IP address 168.192.0.201)
- Be aware: In some situation DHCP server can assign a different IP address. The SSH connection will not be responsible but Ethernet would still be working fine. Check LED status of the router and DHCP server application in this case.
- Name of the log files: differentiate between the log files (this is already done in the testing script)
- Serial console ports: plug them the way that system will assign the same number as the board number is (e.g. in Linux control PC use directory /dev/ttyUSB1 as a serial port for board number 1)
- Visual arrangement of serial and SSH consoles: move them the way the boards are placed inside the chamber
PC setup
During the test DHCP and FTP servers were utilized. The PC was also used during Ethernet ping test while controlling all the boards through SSH and serial console sessions. The control computer was running Windows 7 operating system.
Setting the network
Disable firewall (PC will not be connected to the Internet) and setup a static IP address: Press Windows button -> go to Control Panel -> Network and Internet -> Network and Sharing Center -> Change adapter settings (on the right side in the bar) -> double click on Local Area Connection -> Properties -> In the tab Networking go to Internet Protocol Version 4 (TCP/IPv4) -> type the static IP address and subnet mask as shown below:
Enabling sharing
iMX6 OpenRex SBCs and the control PC are connected via Gigabit Ethernet switch. To ensure correct IP address assignment, turn on the PC first, connect it with the switch and only after that turn the switch on. To be able to download the files from the FTP server, sharing option need to be enabled first. This can be done by setting up the network as a work network. Sharing can be enabled in Control Panel -> Network and Internet -> Network and Sharing Center -> Click to Choose homegroup and sharing options:
Setting up the TFTP and DHCP servers
Tftpd32 software supports both TFTP and DHCP server options. For more details about DHCP configuration, follow the screenshots below:
|
|
Starting time server
To assign the correct time for all the boards Time server feature built in Tftpd32 was used. Go to Settings and make sure that SNTP server is checked:
|
Assigning custom COM port names
As we mentioned before, it is useful to apply the same numbering for boards and serial ports. To do so plug in the first FTDI cable and go to the control PC, select Start, right click on Computer and select Properties. Now click on the Device Manager in the top right corner. Under the item Ports (COM & LPT), USB ports are visible. Now right click and select Properties:
|
Select the Port Settings tab and click on Advanced tab:
|
Now select from the COM Port Number (the one which is not in use):
Now this process can be repeated by plugging another serial cable if needed. After all the cables were attached, restart the computer.
SSH and Serial consoles
To control iMX6 OpenRex SBCs, one TeraTerm serial console was opened per board. SSH clients were used to read temperature. For the boards with the peripheral test, an extra SSH client was established to be able to spot possible errors or warnings if occurred.
Preparing the test
Boot device and software
All the boards were using bootloader stored in SPI flash memory with the rest of firmware located on SD card. The only exception was moving the filesystem to either SATA disk (Max version) or USB flash drive (Basic configuration) for peripheral tests.
The only change compared to standard software package was running a multimedia filesystem. U-Boot settings were not adjusted as the default configuration was used. To prepare a fresh SD card follow these instructions. Here is an example of creating a SD card suitable for Max configuration:
mkdir -pv ~/workdir/imx6/rootfs/yocto cd ~/workdir/imx6/rootfs/yocto wget http://downloads.voipac.com/files/iMX6_OpenRex_SBC/software/yocto/binaries/fsl-image-gui-imx6-openrexmax-2.4.sdcard.gz gunzip -c fsl-image-gui-imx6-openrexmax-2.4.sdcard.gz | sudo dd of=/dev/mmcblk0 conv=sync bs=64K
Creating new directories and copying test files
cd /media wget http://downloads.voipac.com/files/iMX6_OpenRex_SBC/documents/Environmental_chamber_testing/ cp blackbird.wav blackbird2.wav # prepare directories cd /home/ubuntu/ mkdir -p openrex/ cd openrex/ mkdir -p env-chamber-testing/ cd env-chamber-testing/ wget http://downloads.voipac.com/files/iMX6_OpenRex_SBC/documents/Environmental_chamber_testing/stressapptest touch orx-env-chamber-testing.log touch orx-cpu-temp.log # setup local time ln -sf /usr/share/zoneinfo/Europe/Bratislava /etc/localtime
Setup the cron
To be able to check the CPU temperature every minute a new cron job was setup. For Ubuntu file systems postfix package installation is required:
sudo apt-get install postfix
To setup a cron tab, the file containing all cron jobs needs to be altered. Before running the crontab for the first time, selecting a text editor is required:
sudo crontab -e
Paste the following line to the end of the cron list file. The output time format will be set the same as for stressapptest. Cron job performs a current CPU temperature readout and the data are saved in the log file. The log format was selected identical to the one used by stressapptest package:
* * * * * { echo -n $(date +%Y/%m/%d-%T); echo -n "("; echo -n $(date +%Z); echo -n ") "; cat /sys/devices/virtual/thermal/thermal_zone0/temp; } >> /home/ubuntu/openrex/env-chamber-testing/orx-cpu-temp.log
Note: The percent sign '%' has a special purpose in the cron file. As this sign is needed to write the date formats, the backslash is required to be placed before the percent sign: '\%'.
Setup the CPU temperature printout
Open one SSH client per board where CPU temperature will be shown. Tail command is utilized to display the last part of the log file, which is filled up as the CRON job outputs the current readouts:
cd /home/ubuntu/openrex/env-chamber-testing/ tail -f orx-cpu-temp.log
Error checking during peripheral test
To make sure tests are running smoothly, potential errors can be detected by opening another SSH session:
cd /home/ubuntu/openrex/env-chamber-testing/ tail -f orx-env-chamber-testing.log | grep -i "error"
Copying the script file
Before the script is run, the correct permission needs to be set up:
cd /home/ubuntu/openrex/env-chamber-testing/ wget http://downloads.voipac.com/files/iMX6_OpenRex_SBC/documents/Environmental_chamber_testing/openrex-env-chamber-test.sh chmod 777 openrex-env-chamber-test.sh
Preparing backup script (memory test only)
To store the older files automatically, following script can be used:
#!/bin/sh # obtain board ID from IP address - be sure addresses are allocated based on MAC boardID=$(/sbin/ip -o -4 addr list eth0 | awk '{print $4}' | cut -d/ -f1 | cut -d'.' -f4 | cut -d'2' -f2); currentTime=`date +%Y-%m-%d.%H:%M` mv stressapptest.log orx-board-$boardID-stressapptest.log.$currentTime mv orx-cpu-temp.log orx-board-$boardID-env-cpu-temp.log.$currentTime touch stressapptest.log touch orx-cpu-temp.log
This script requires permission update as well:
cd /home/ubuntu/openrex/env-chamber-testing/ wget http://www.imx6rex.com/download/software/openrex/others/files/backupFiles.sh chmod 777 backupFiles.sh
Setting time and date
Before the test, server date and time is automatically obtained from SNTP server:
ntpdate 192.168.0.2
Start CPU and memory stress test
Navigate into the directory, where stressapptest feature and test are stored.
Stress command for Max configuration:
./backupFiles.sh & stressapptest -s 600000 -M 1000 -m 4 -C 4 -W -l /home/ubuntu/openrex/env-chamber-testing/stressapptest.log --printsec 100
Stress command for Basic configuration:
./backupFiles.sh & stressapptest -s 600000 -M 150 -m 1 -C 1 -W -l /home/ubuntu/openrex/env-chamber-testing/stressapptest.log --printsec 100
Start peripheral test
Before the test start it is a good practice to make sure that all the devices were plugged in successfully. To find out where the devices were mounted following command can be used:
fdisk -l
The testing script uses multiple variables to specify its operation. As the first parameter board configuration is used (-max or -basic). As other parameters device names
are written in the following order: the first USB stick, the second USB, SD card and SATA drive (if used). All logs are stored into a single file.
Starting peripheral test for Max configuration:
./openrex-env-chamber-test.sh -max sdb1 sdc1 mmcblk1p2 sda1 2>&1 | tee -i orx-env-chamber-testing.log
Starting peripheral test for Basic configuration:
./openrex-env-chamber-test.sh -basic sda1 sdb1 mmcblk1p2 2>&1 | tee -i orx-env-chamber-testing.log
The complete script can be found in the download section or down below:
#!/bin/sh # OpenRex environmental chamber testing script # Example QUAD: ./openrex-env-chamber-test.sh -quad sdb1 sdc1 mmcblk0p1 sda1 2>&1 | tee -i orx-env-chamber-testing.log # Example SOLO: ./openrex-env-chamber-test.sh -solo sda1 sdb1 mmcblk0p1 2>&1 | tee -i orx-env-chamber-testing.log mountDevice() { mount /dev/$1 /media/$2 cat /etc/mtab | grep -F "/dev/$1 /media/$2" if [ "$?" -eq "0" ]; then echo "$2 mounted" else echo "$2 not mounted"; exit 2 fi } # prepare files if needed touch orx-env-chamber-testing.log touch orx-cpu-temp.log echo -e '\033[9;0]' > /dev/tty1 # disable blanking the display imx6solo=0 imx6quad=0 case $1 in -basic) imx6solo=1 ;; -max) imx6quad=1 ;; *) esac # mount devices mountDevice $2 usb0 mountDevice $3 usb1 mountDevice $4 mmc0 if [ "${imx6quad}" -eq "1" ]; then mountDevice $5 sata fi updateLogFiles() { # obtain board ID from IP address - be sure addresses are allocated based on MAC boardID=$(/sbin/ip -o -4 addr list eth0 | awk '{print $4}' | cut -d/ -f1 | cut -d'.' -f4 | cut -d'2' -f2); # be sure time server is running on DHCP server currentTime=`date +%Y-%m-%d.%H:%M` mv orx-env-chamber-testing.log orx-board-$boardID-env-chamber.log.$currentTime mv orx-cpu-temp.log orx-board-$boardID-env-cpu-temp.log.$currentTime touch orx-env-chamber-testing.log touch orx-cpu-temp.log } finish_test_now() { echo "$(date +\%Y/\%m/\%d-\%T)($(date +\%Z)) Ctrl+C Detected: End of the test" precced=0; #kill -INT $vid_pid $str_pid; sleep 3; test_status=`cat orx-env-chamber-testing.log | grep -i "error" | grep -v -e "0 errors" -e "no corrected errors"` if [ -z "$test_status" ] then echo "*********\nTEST PASS\n*********" else echo "*********\nTEST FAIL\n*********\n" echo "List of detected errors:" cat orx-env-chamber-testing.log | grep -i "error" | grep -v -e "0 errors" -e "no corrected errors" -e "List of detected errors:" fi updateLogFiles exit; } # kill all processes if Ctrl+C is detected trap finish_test_now 2 # stressapptest - one thread CPU, one thread memory if [ "${imx6solo}" -eq "1" ]; then stressapptest -s 600000 -M 100 -m 1 -C 1 --printsec 10 & str_pid=$! fi if [ "${imx6quad}" -eq "1" ]; then stressapptest -f /media/sata/tmp-file1 -s 600000 -M 500 -m 1 -C 1 --printsec 10 & str_pid=$! fi echo "$(date +\%Y/\%m/\%d-\%T)($(date +\%Z)) Starting stressapptest with PID: " $str_pid # play a video file in an infinite loop echo 0 > /sys/class/graphics/fb0/blank mplayer -vo fbdev2:/dev/fb0 -quiet -vf scale -zoom -loop 0 -xy 1024 /home/ubuntu/Clouds.avi < /dev/null & vid_pid=$! echo "$(date +\%Y/\%m/\%d-\%T)($(date +\%Z)) Starting video file playback with PID: " $vid_pid proceed=1 file1="blackbird.wav" file2="blackbird2.wav" cp1_from="/media/mmc0/" cp1_to="/media/usb0/" cp2_from="/home/ubuntu/" cp2_to="/media/usb1/" #copy files in case they are missing cp /media/$file1 $cp1_from$file1 cp /media/$file1 $cp1_to$file1 cp /media/$file2 $cp2_from$file2 cp /media/$file2 $cp2_to$file2 while [ $proceed -eq 1 ] do ping -q -c1 192.168.0.2 >> orx-env-chamber-testing.log if [ $? -ne 0 ] then echo "$(date +\%Y/\%m/\%d-\%T)($(date +\%Z)) ERROR: Ping failed" fi cp1_done=`ps cax | grep $cp1_pid | grep cp` if [ -z "$cp1_done" ]; then # copy finished if cmp -s $cp1_from$file1 $cp1_to$file1; then echo "$(date +\%Y/\%m/\%d-\%T)($(date +\%Z)) PASS: Copying file from $cp1_from to $cp1_to successful" else echo "$(date +\%Y/\%m/\%d-\%T)($(date +\%Z)) ERROR: Difference between files on $cp1_from and $cp1_to detected" cp /media/$file1 $cp1_to$file1 echo "$(date +\%Y/\%m/\%d-\%T)($(date +\%Z)) File copied from /media/ to $cp1_to" fi cp1_temp=$cp1_from # swap destinations cp1_from=$cp1_to cp1_to=$cp1_temp rm $cp1_to$file1 # remove destination file cp $cp1_from$file1 $cp1_to$file1 & cp1_pid=$! echo "$(date +\%Y/\%m/\%d-\%T)($(date +\%Z)) Started copying file from $cp1_from to $cp1_to" fi cp2_done=`ps cax | grep $cp2_pid | grep cp` if [ -z "$cp2_done" ]; then # copy finished if cmp -s $cp2_from$file2 $cp2_to$file2; then echo "$(date +\%Y/\%m/\%d-\%T)($(date +\%Z)) PASS: Copying file from $cp2_from to $cp2_to successful" else echo "$(date +\%Y/\%m/\%d-\%T)($(date +\%Z)) ERROR: Difference between files on $cp2_from and $cp2_to detected" cp /media/$file2 $cp2_to$file2 echo "$(date +\%Y/\%m/\%d-\%T)($(date +\%Z) File copied from /media/ to $cp2_to" fi cp2_temp=$cp2_from # swap destinations cp2_from=$cp2_to cp2_to=$cp2_temp rm $cp2_to$file2 # remove destination file cp $cp2_from$file2 $cp2_to$file2 & cp2_pid=$! echo "$(date +\%Y/\%m/\%d-\%T)($(date +\%Z)) Started copying file from $cp2_from to $cp2_to" fi done
The original article can be accessed on the iMX6Rex.com website.