Skip to content
Snippets Groups Projects
Commit 17a93ad0 authored by Marc-Oliver Westerburg's avatar Marc-Oliver Westerburg Committed by Jonas Höppner
Browse files

components: EMV-Testsuite for SANVITO (refs #33211)

* added SANVITO bit-script
* added test-videos for new display tests (new regulations require a
    bouncing-ball" multimedia-test, instead of a simple, static test-image)
* added simple logging-scripts for Analog-I/O and Ambient/Proximity-Sensor.
** Except for an additional I2C communication test for the amb/prox-sensor,
   no real evaluation of read data, but just logging to output-log and later evaluation, for now.

Change-Id: I98bd91402bd5c63f4ccbbfd0941a2fc1e3ce0e4d
Reviewed-on: http://gfweb/gerrit/379
parent 019e8555
No related branches found
No related tags found
No related merge requests found
File added
File added
#-----------------------------------------------------------------------------#
# 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 33333 >/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
SUBDIRECTORIES = backlight bit bwrite can flashled fwrite gpio i2c iptest lm73temp mmc mstick qwheel rs485pingpong rtccheck serial touchmon v4l2capture watchdog timerapi spi SUBDIRECTORIES = aio ambprox backlight bit bwrite can flashled fwrite gpio i2c iptest lm73temp mmc mstick qwheel rs485pingpong rtccheck serial touchmon v4l2capture watchdog timerapi spi
.PHONY: subdirs $(SUBDIRECTORIES) .PHONY: subdirs $(SUBDIRECTORIES)
subdirs: $(SUBDIRECTORIES) subdirs: $(SUBDIRECTORIES)
......
##########################################################################
## ##
## Copyright (C) 2013 Garz & Fricke GmbH ##
## ##
## No use or disclosure of this information in any form without ##
## the written permission of the author ##
## ##
##########################################################################
TARGET=aio
top_srcdir ?= $(SYSROOT)/usr
all:
@mkdir -p ../bin
@cp *.sh ../bin/
clean:
#!/bin/sh
for ((i=0; i<$1; i++));
do
# get random value from 0..255
val=`dd if=/dev/random bs=1 count=1 2>/dev/null|hexdump -e '/1 "%u"'`;
# output value on DAC
echo -n $val >/sys/bus/iio/devices/iio\:device1/out_voltage0_raw;
# generate logging input from output and input
echo "analog i/o 0 TINFO : output:" `dc <<< "$val $(cat /sys/bus/iio/devices/iio\:device1/out_voltage_scale) * p"` " in: " `dc <<< "$(cat /sys/bus/iio/devices/iio\:device0/in_voltage_raw) $(cat /sys/bus/iio/devices/iio\:device0/in_voltage_scale) * p"` `dc <<< "$(cat /sys/bus/iio/devices/iio\:device0/in_voltage_raw) $(cat /sys/bus/iio/devices/iio\:device0/in_voltage_scale) * p"` `dc <<< "$(cat /sys/bus/iio/devices/iio\:device0/in_voltage_raw) $(cat /sys/bus/iio/devices/iio\:device0/in_voltage_scale) * p"`
done;
#!/bin/sh
echo 1 >/sys/class/gpio/an_in_pwr/value; echo 1 >/sys/class/gpio/an_out_pwr/value
##########################################################################
## ##
## Copyright (C) 2013 Garz & Fricke GmbH ##
## ##
## No use or disclosure of this information in any form without ##
## the written permission of the author ##
## ##
##########################################################################
TARGET=ambprox
top_srcdir ?= $(SYSROOT)/usr
all:
@mkdir -p ../bin
@cp *.sh ../bin/
clean:
#!/bin/sh
echo "proximity 0 TINFO : " `gfi2c --read /dev/i2c-2 0x60 0x08 -w 16 -v -v -n 1 | grep rw`;
echo "ambient 0 TINFO : " `gfi2c --read /dev/i2c-2 0x60 0x0b -w 16 -v -v -n 1 | grep rw`;
/opt/ltp/testcases/bin/i2c -q -d /dev/i2c-2 -s 0x60 -a 0x01 -b 0x02 -w 100 -m 8 -l 2
#!/bin/sh
gfi2c --write /dev/i2c-2 0x60 0x03 0x0e01 -w 16 -v -v
gfi2c --write /dev/i2c-2 0x60 0x04 0x0207 -w 16 -v -v
gfi2c --write /dev/i2c-2 0x60 0x06 0x5803 -w 16 -v -v
gfi2c --write /dev/i2c-2 0x60 0x07 0x6003 -w 16 -v -v
echo "proximity 0 TINFO : started"
gfi2c --write /dev/i2c-2 0x60 0x00 0x00 -w 16 -v -v
echo "ambient 0 TINFO : started"
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment