Main Restorations Software Audio/Jukebox/MP3 Everything Else Buy/Sell/Trade
Project Announcements Monitor/Video GroovyMAME Merit/JVL Touchscreen Meet Up Retail Vendors
Driving & Racing Woodworking Software Support Forums Consoles Project Arcade Reviews
Automated Projects Artwork Frontend Support Forums Pinball Forum Discussion Old Boards
Raspberry Pi & Dev Board controls.dat Linux Miscellaneous Arcade Wiki Discussion Old Archives
Lightguns Arcade1Up Try the site in https mode Site News

Unread posts | New Replies | Recent posts | Rules | Chatroom | Wiki | File Repository | RSS | Submit news

  

Author Topic: minimus AVR with Kade firmware registering multiple button presses.....help!  (Read 1059 times)

0 Members and 1 Guest are viewing this topic.

severdhed

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 2975
  • Last login:December 14, 2024, 05:01:52 pm
  • RIP Dinosaur Hippo
i have a minimus avr that i flashed with the Kade firmware, using the USB/HID keyboard Encoder option, with custom key mappings. 

the problem i have is that frequently, when i press a button, it will send 2 or 3 or more presses.  i'm not sure what is going on with it or how to fix it.  i'm trying to use this to make an electronic scoreboard for my son's karate school, so having it register multiple points per press is unacceptable.  At first i thought it was something wierd with the raspberry pi i had it connected to, since i have never used one of those before, but i connect it to my laptop and it does the same thing.

some of the inputs seem to do it more frequently than others.  I replaced the switches on a few of them. even went as far as removing the ground loop and wiring just one button up with straight connections to the encoder, but it still happens.  Is there something I can do to remedy this?

Current Projects:      Zak-Man | TMNT Pedestal | SNES Pi | N64 Odroid
Former Projects:     4 Player Showcase | Donkey Kong | iCade

PL1

  • Global Moderator
  • Trade Count: (+1)
  • Full Member
  • *****
  • Online Online
  • Posts: 9682
  • Last login:Today at 10:13:44 am
  • Designated spam hunter
I often get multiple keystrokes while manually shorting terminals with a ground wire, but not with a microswitch.

It sounds like either 1.) the ground connection is a bit intermittent or 2.) the switches have a really long bounce time.

Are you sure all the wires are securely soldered to the AVR? (good mechanical and electrical connection)

Any continuity problems with the wires/crimps? (broken wire strands, etc.)

Do you get the same multi-keypress when you manually short the input wires to another ground like the USB connector shell or the PSU?

KADE loader has a built-in keyboard tester that should help with testing.

Worst case scenario, Jon can probably make you a custom hex with a much longer debounce time. (50-150 mSec?)   :dunno


Scott
« Last Edit: June 05, 2014, 01:47:20 am by PL1 »

kixfan

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 475
  • Last login:May 22, 2018, 06:59:26 pm
can you explain how you have it mapped in the firmware?   Maybe you can provide a screen shot?   I am using mine on a virtual pin and was worried about this exact issue.   When I went to wire up the start button on the coin door without thinking I took a resistor (well I think it was a resistor) off the switch.   I then started to think about why it was there and figured it was there to stop double presses.   While setting it up, for a short time had the button mapped to something other that the start button.   I believe I was getting double presses but after I mapped to proper button it did not do that.    So, it could be what you are mapping the button to.    Hope that made sense!

If you feel adventurous, use the pinball map and map one of your buttons to the start button and see if you get the same thing.

PL1

  • Global Moderator
  • Trade Count: (+1)
  • Full Member
  • *****
  • Online Online
  • Posts: 9682
  • Last login:Today at 10:13:44 am
  • Designated spam hunter
Thanks for reminding me, Kixfan.   ;D

The component you removed was a capacitor.

See this thread for information on smoothing bouncing switches using capacitors.

WindDrake's second post in that thread has some typical values and a link to the theory and associated math.


Scott

severdhed

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 2975
  • Last login:December 14, 2024, 05:01:52 pm
  • RIP Dinosaur Hippo
the solder connections all look decent, i'll double check them again tomorrow.  i soldered small wires from a piece of cat5 to the minimus which run to some screw terminal barrier strips.  i've  used several different switches, and even a sanwa button with the switch built in, and the problem persists.  i'm not sure what else could be going on.  i'm going to try to rewire everything again just to be sure.  as for the keymapping, i dont have that computer with me right now, but i'll post the configuration tomorrow evening.

Current Projects:      Zak-Man | TMNT Pedestal | SNES Pi | N64 Odroid
Former Projects:     4 Player Showcase | Donkey Kong | iCade