I am a beginner in Arduinos and I hope someone can help me out.
I have a Sparkfun Gesture Sensor which can read movement (left, right, up and down). I want to create a project, something like this:
Rule1 - When the sensor detects 3 "left" moves within 5 seconds, it will set LED1 to high Rule2 - When the sensor detects 2 "right" moves within 5 seconds, it will set LED2 to high Rule3 - When the sensor detects 2 "up" and then 2 "down" moves within 5 seconds, it will set LED3 to high
I also want that Rule 2 will become available only when Rule 1 is finished, and rules 3 will only become available when Rule 2 is finished.
In the example code with this sensor I see switch/ case statements, but I really don't know how I can use these for my above wishes ;) I am not sure if this is possible but I hope someone can push me in the right direction.
Thanks a lot! Mark