More than one button - how to setup? #3769
Replies: 1 comment
-
Posted at 2014-04-24 by @gfwilliams Hi. I think your problem is that when you run
with:
Your other problem (which isn't good for Espruino) is that when you press the button, you're applying 5v (from VBat) to 3.3v only pins. See http://www.espruino.com/ReferenceESPRUINOBOARD - the pins that can't take 5v are marked with 3.3. I'd suggest that instead of connecting the other side of the buttons to VBat, you connect it to 3.3 Hope that helps! Posted at 2014-04-24 by Andreas Hi Gordon, Thanks again! It works absolutely fine now. I'm very new in hardware programming and the espruino is really great and a lot of fun to work with! Best regards, Andreas |
Beta Was this translation helpful? Give feedback.
-
Posted at 2014-04-24 by Andreas
Hi Espruinos!
In my application I would like to use four buttons C2, C3, C4 and C5.
The question is, what is the best way to set up these buttons? I tried
Each of the buttons is connected to V_bat on the one side and to C2,3,4 or 5 on the other side. But when I press a button (let's say the one connected with C2), the variable "o" does not increase when I press it the first time, when I press it again it jumps from 0 to 2, then it works and jumps from 2 to 3 and so on but with no reproducibly.
I just want to increase by 1 when a button is pressed.
Thanks a lot, Andreas
Beta Was this translation helpful? Give feedback.
All reactions