Hello everyone, I would like to use 36 tactile buttons (divided into 4 groups of 9 buttons each) in a circuit that uses a ChipKit MAX32.
I have attached a scheme.
What I would like to get with this experiment is : if one of these buttons has been pressed and which of the 4 groups it belongs to.
But all the resistor are overkill (and might even be to much for the supply). You only need 4. Or even 0 if you use the internal pull up/down.
But yeah, no idea with a ChipKit... Why post here for a chip kit??????
PS You did NOT attach a schematic. That's what we call in the business a Fritzing mess.
Yes.
But all the resistor are overkill (and might even be to much for the supply). You only need 4. Or even 0 if you use the internal pull up/down.
Mmm so I need just 1 resistor for each group? over 500 ohm?
But yeah, no idea with a ChipKit... Why post here for a chip kit??????
I have MEGA 2560 and MAX32 and I am in a long comparative session. Just very similar in what I need!
But for sure I could to write the same post for a MEGA2560.
PS You did NOT attach a schematic. That's what we call in the business a Fritzing mess.
Sorry, little time to paint it. But finally is correct?
Yes, all switches and resistors are in parallel. Which would have been obvious from the start from a real schematic.
Even 10k is fine. Or the internal pull up/down which is quicker....
Then 4 x 10k resistors. Good.
Then you also need a comparison of the support fora...
haha no way. Here is good!
No need for paint, pen and paper will do
Just can't paint either with a pen a right electrical scheme!
I am just an amateur with very poor technical base.
I got little time to paint what you saw but yea just very bad about.
The pinMode/digitalWrite combination in the previous post doesn't affect pull-ups in Max32.
If you need pull-up resistors on input pins you'll need to add them externally.
No big deal. I had a bunch of 10k resistors in my parts box. Just something to watch if you're moving a project that uses input switches from Arduino to Max32.
So now I know pull up resistors are applied to the pins but not all pins.
Ok, so I need 4 pin with this feature BUT reading these words, I think it's better to use resistors considering my code that is written for MEGA2560.
Another question, now I have 4 resistors in parallel. This could affect their work or (with long time) damaging these little things?
Now I trust you realise that you only have four inputs here - you can tell that a button in a group of nine is pressed, but not which of the nine buttons it was.
You effectively have only four buttons, each of which has nine alternate things that may press it.
Paul__B:
Now I trust you realise that you only have four inputs here - you can tell that a button in a group of nine is pressed, but not which of the nine buttons it was.
You effectively have only four buttons, each of which has nine alternate things that may press it.
Thanks again to all you guys.
Yes I just want to know what of the 4 groups has a button pressed. Not important what is exact number of the 9 buttons of the group . Just want to know when a group has a button pressed.
Yes, that is the general idea. All the buttons in parallel, one pull-down resistor. Repeat for each of your four sections.
That said, I always advise that you make a habit of connecting the buttons to ground, and the pull-up resistor to "Vcc" - your 5 V or 3.3 V supply line that apparently the ChipKit uses. So your black and red are exchanged in that diagram.
This is because it is generally a bad idea to have your supply line wandering out to pushbuttons and the like - there is a risk however slight of it being shorted to ground or picking up or radiating interference to other devices.
The resistor is always close to the microcontroller so is much safer connected to Vcc. In addition, most microcontrollers implement a built-in pull-up "resistor" (or current source) function which may be adequate instead of your 10k resistor.
No way to use internal pull up resistor of my MAX32, I read a lot of problematics about and I have no technical level to handle that! just prefer a simple way using normal resistors.
And (lucky) the resistors will be put not too close to the board!
Really thank you Paul! you are very kind! and now I know how to propely make the wires!
I know little about internal pull-up resistor.. I know each MEGA2560 and MAX32 has this feature.
Just know also that these boards has some pins with that feature and not all pins.
Over all that I read some big difference using it between MEGA and MAX32 when you write the
code to handle it.