I'm new to this Arduino world and my knowledge of what it can do is limited.
- Arduino UNO R3
- LCD 1602
- 2 x potentiometer
I was wondering and correct me if I'm wrong, the Arduino UNO R3 can only execute one task at a time but we can program it so it can execute multiple tasks one after the other. My question is, can I use 1 LCD with 2 counters on the screen and control each one with its potentiometer since it's a 16 digit by 2 rows? Example:
Row 1 - Count 1 Count 2
Row 2 - 0 0
Yes, essentially you'll need to use the loop function to continuously read the two pots over and over listening for changes. Then if something does in fact change, increment or decrement the counters and update the LCD accordingly.
You probably don't want to be continuously updating the LCD in the loop as it can cause it to slow things down and flicker the display. So writing to the LCD only when needed is a better approach.
..or writing every 300~500ms.
This is great then, I will give it a try.
Thank you so much for your answer
You can switch back and forth between 2 (or more) tasks so quickly that it looks like the tasks are simultaneous.
Several things at a time.
Beginner's guide to millis().
Blink without delay().
This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.