06-27-2021 01:54 PM
How to increment and decrement value when sensor digital read is true ?
06-28-2021 01:04 AM
With such a poor description of a problem this is all i can give you.
06-28-2021 09:47 AM - edited 06-28-2021 09:51 AM
Here's a little pseudo code to think about...
06-29-2021 11:35 AM
I need to increment a value in 7 segment display when avoidance sensor detects a object and thus activate servo motor and other avoidance to sensor decrement that value when "car" leave in car parking system.
06-30-2021 02:29 AM
Hi titos,
@titos_sampas wrote:
I need to increment a value … when avoidance sensor detects a object and thus activate servo motor and other avoidance to sensor decrement that value when "car" leave in car parking system.
Some pseudocode:
IF RisingEdge(AvoidanceSensor1) THEN
value++
ENDIF
IF RisingEdge(AvoidanceSensor2) THEN
value--
ENDIF
@titos_sampas wrote:
value in 7 segment display
The 7 segment display is a different "problem": here you just need to convert your "value" into the corresponding DO signals to light up the correct LEDs…