October 2017
Intermediate to advanced
586 pages
14h 8m
English
This is used to create a new sysfs trigger. You can create a new trigger by writing a positive value (which will be used as a trigger ID) into that file. It will create the new sysfs trigger, accessible at /sys/bus/iio/devices/triggerX, where X is the trigger number, for example:
# echo 2 > add_trigger
This will create a new sysfs trigger, accessible at /sys/bus/iio/devices/trigger2. If the trigger with the specified ID is already present in the system, an invalid argument message will be returned. The sysfs trigger name pattern is sysfstrig{ID}. The echo 2 > add_trigger command will create the trigger /sys/bus/iio/devices/trigger2, whose name is sysfstrig2:
$ cat /sys/bus/iio/devices/trigger2/name sysfstrig2
Each sysfs ...