• Home
  • Annotate
  • current directory
Name Date Size #Lines LOC

..22-Aug-2025-

boards/22-Aug-2025-

src/22-Aug-2025-

CMakeLists.txt A D22-Aug-2025292 107

README.rst A D22-Aug-20251.5 KiB5942

prj.conf A D22-Aug-202556 43

sample.yaml A D22-Aug-2025482 2120

trigger.conf A D22-Aug-202552 32

README.rst

1.. zephyr:code-sample:: paj7620_gesture
2   :name: PAJ7620 Gesture Sensor
3   :relevant-api: sensor_interface
4
5   Get hand gesture data from PAJ7620 sensor.
6
7Overview
8********
9
10This sample application gets the output of a gesture sensor (PAJ7620) using either polling or
11triggers, and outputs the corresponding gesture to the console, each time one is detected.
12
13Requirements
14************
15
16To use this sample, the following hardware is required:
17
18* A board with I2C support (and GPIO to detect external interrupts in trigger mode)
19* PAJ7620 sensor
20
21Building and Running
22********************
23
24This sample outputs data to the console. It requires a PAJ7620 sensor.
25
26Polling Mode
27============
28
29.. zephyr-app-commands::
30   :zephyr-app: samples/sensor/paj7620_gesture
31   :board: nucleo_f334r8
32   :goals: build
33   :compact:
34
35Trigger Mode
36============
37
38In trigger mode, the sample application uses a GPIO to detect external interrupts, therefore GPIO
39support must be enabled. Just like every sensor supporting trigger mode, it is possible to choose
40between using a global thread (``CONFIG_PAJ7620_TRIGGER_GLOBAL_THREAD``) or a dedicated thread
41(``CONFIG_PAJ7620_TRIGGER_OWN_THREAD``) for the interrupt handling.
42
43.. zephyr-app-commands::
44   :zephyr-app: samples/sensor/paj7620_gesture
45   :board: nucleo_f334r8
46   :goals: build
47   :gen-args: -DEXTRA_CONF_FILE=trigger.conf
48   :compact:
49
50Sample Output
51=============
52
53.. code-block:: console
54
55   Gesture LEFT
56   Gesture RIGHT
57   Gesture UP
58   Gesture DOWN
59