summaryrefslogtreecommitdiffstats
path: root/tests/ipecamera/grab-hwtrigger.sh
blob: 0279ab48d2123c579023d94502517d9f25a671fe (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
#! /bin/bash

function pci {
    PCILIB_PATH="/root/pcitool"
    LD_LIBRARY_PATH="$PCILIB_PATH" $PCILIB_PATH/pci $*
}

function enable_hw_trigger {
    usleep 100000
    pci -w control 0xa01
}

rm -f images.raw

enable_hw_trigger &
pid=$!

echo "Starting the grabber"
pci -g -o images.raw --run-time 60000000 --verbose 10 -o /dev/null
wait $pid