Skip to content
Snippets Groups Projects
Code owners
Assign users and groups as approvers for specific file changes. Learn more.
sanvito 4.90 KiB
#-----------------------------------------------------------------------------#
# DESCRIPTION                                                                 #
# -----------                                                                 #
# This is a configuration file for the Garz & Fricke Built-In-Test Framework, #
# which is implemented using tests from the LTP. Thus, the configuration file #
# looks very similar to LTP configuration files and can actually be used by   #
# LTP. However, it should not, since there are slight differences:            #
# This file is divided into three sections: PREPARATION, TESTCASES and        #
# CLEANUP. Each section contains lines beginning with a name and ending with  #
# a command line. The command lines of the PREPARATION section are executed   #
# once at the start of the execution. Then, the command lines of the TEST-    #
# CASES section is looped for the given number of iterations. At the end, the #
# commands of the CLEANUP section are run once.                               #
#-----------------------------------------------------------------------------#

#-----------------------------------------------------------------------------#
# PREPARATION                                                                 #
#-----------------------------------------------------------------------------#
#Testimage_display           FRAMEBUFFER=/dev/fb0 fbv -er /opt/ltp/images/guf_test_800x480.png < /dev/null
#Testimage_display          /usr/share/qt5/examples/touch/fingerpaint/fingerpaint &
Testimage_display             /usr/bin/gplay-1.0 /opt/ltp/images/colorbar-and-bouncing-ball-1024x768.mp4 --repeat &
#USB_stick_1_umount          for i in `mount | grep sda | awk '{print $1}'`; do umount $i; done
Touchtest_remove_socket     rm -f /touch_tst_socket
Touchtest_start             touchmon -d -i /dev/input/event0 -s /touch_tst_socket -p 0
Network_eth0                ifconfig eth0 add 192.168.1.1
Network_eth1                ifconfig eth1 add 192.168.2.1
Network_eth1                ifconfig eth2 add 192.168.3.1
RS485pingpong_start12       echo 1 >/sys/class/gpio/rs485-1_pwr/value; echo 1 >/sys/class/gpio/rs485-2_pwr/value; rs485pingpong -k -d /dev/ttyUSB0 -s 115200 -x 100 -b 64 -n &
RS485pingpong_start34       echo 1 >/sys/class/gpio/rs485-3_pwr/value; echo 1 >/sys/class/gpio/rs485-4_pwr/value; rs485pingpong -k -d /dev/ttyUSB2 -s 115200 -x 100 -b 64 -n &
AnalogIO_start              aio_setup.sh
Buzzer_start				echo 0 >/sys/class/pwm/pwmchip3/export; echo 333333 >/sys/class/pwm/pwmchip3/pwm0/period; echo 16667 >/sys/class/pwm/pwmchip3/pwm0/duty_cycle
LED_Power_start				echo 0 >/sys/class/pwm/pwmchip2/export; echo 2000000 >/sys/class/pwm/pwmchip2/pwm0/period; echo 1000000 >/sys/class/pwm/pwmchip2/pwm0/duty_cycle; echo 1 >/sys/class/pwm/pwmchip2/pwm0/enable
LED_Error_start				echo 0 >/sys/class/pwm/pwmchip1/export; echo 2000000 >/sys/class/pwm/pwmchip1/pwm0/period; echo 1000000 >/sys/class/pwm/pwmchip1/pwm0/duty_cycle; echo 1 >/sys/class/pwm/pwmchip1/pwm0/enable
Ambient_Proximity			ambprox_setup.sh




#-----------------------------------------------------------------------------#
# TESTCASES                                                                   #
#-----------------------------------------------------------------------------#
GPIO1                       gpio -g dig_out1 -d out -v 1 && gpio -g dig_in1 -d in -v 1 && gpio -g dig_out1 -d out -v 0 && gpio -g dig_in1 -d in -v 0
GPIO2                       gpio -g dig_out2 -d out -v 1 && gpio -g dig_in2 -d in -v 1 && gpio -g dig_out2 -d out -v 0 && gpio -g dig_in2 -d in -v 0
Temp                        lm73temp -n lm75
#Flash_write_25kB           fwrite -q -n /file25k -b 25000 -i 1
USB_stick_1_write_100kB     fwrite -q -n /media/sda1/testfile -b 100000 -d -i 1
Network_eth0                iptest -q -g 192.168.1.100 -n 1 -w 50
Network_eth1                iptest -q -g 192.168.2.100 -n 1 -w 50
Network_eth2                iptest -q -g 192.168.3.100 -n 1 -w 50
RS485_BB                    rs485pingpong -b 64 -r 16 -s 115200 -x 100 -o 1 -d /dev/ttymxc1
RS485_12                    rs485pingpong -b 64 -r 16 -s 115200 -x 100 -o 1 -d /dev/ttyUSB1 -n
RS485_34                    rs485pingpong -b 64 -r 16 -s 115200 -x 100 -o 1 -d /dev/ttyUSB3 -n
Touch                       touchmon -z -r /touch_tst_socket
Ambient_Proximity			ambprox.sh
AnalogIO					aio.sh 5; 
Buzzer						echo 1 >/sys/class/pwm/pwmchip3/pwm0/enable; usleep 100000; echo 0 >/sys/class/pwm/pwmchip3/pwm0/enable
Wait                        sleep 0.9

#-----------------------------------------------------------------------------#
# CLEANUP                                                                     #
#-----------------------------------------------------------------------------#
Touchtest_stop              touchmon -t -r /touch_tst_socket -q
#Testimage_display_stop     killall fingerpaint
Testimage_display_stop       killall gplay-1.0
RS485pingpong_stop          killall rs485pingpong