Cooking a Teensy 2.0

Status
Not open for further replies.

Aussie_CrocHunter

Well-known member
Hi! I'm new here so please go easy - also I'm terrible at electronics but that will become evident!

I'm building a simple midi controller (isn't everyone?).

I've got a mate doing the coding coz he's a wiz at that stuff. I'm building the box.

I've got some guitar footswitches which are normally on and then momentarily off when you press them.
I've done a test on the breadboard but that was with a momentary on switch like a normal button.
I connected the positive to one side of the button and the ground to the other side. I put the digital input connector in the middle so it picked up when the circuit changed. it's on the positive side (I couldn't get it to work on the ground side).

However when I switched to the button that's always on unless you tap it to momentarily turn it off, I have cooked my teensy. So, I have two questions:
-Should the digital pin be paired with the ground contact or the VCC contact?
-How did I cook my teensy?

So the connections go like this:
VCC to two switches
ground to the other terminal of two switches
digital input pins on same terminal of the switch as VCC

I don't think code is relevant here, but if it is, I'll post it ASAP
 
Is it because the switch is nearly always on? should I have connected on the other side of the switch which would only be momentarily on? (it's a DPDT switch which is normally on then momentarily changes to the other side being on)
 
From the sounds of it you shorted the power supply with the switch closed. If you draw it out is that what is going on?

Normally you would use pinMode(pullup) and connect the other end of the switch to ground.

Anytime you have VCC and GND connected to the same switch you need to be doing a bunch of design work to make sure you never short the power supply.

https://learn.adafruit.com/adafruit-arduino-lesson-6-digital-inputs/overview

This should not in fact have killed the Teensy, but the problem may in fact be that the PC USB port is dead/disabled due abuse. Once you have the short circuit fixed (unplug and test VCC to gnd for resistance and look for more than 50 ohms or so). try power cycling the computer and using a different physical USB port.
 
So the connections go like this:
VCC to two switches
ground to the other terminal of two switches
digital input pins on same terminal of the switch as VCC

I'm not getting a clear idea of how this was actually connected. Any chance you could show us photos and/or a clear diagram?

Often when parts are damaged, it's due to something getting connected differently than was intended. That's why photos of what actually happened are so essential for troubleshooting (over the internet).

For connecting switches, the common (and usually best) approach is to connect one side of the switch to GND and the other side to a pullup resistor and the input pin. Usually connecting VCC to switches isn't necessary.

If the switch is normally closed, this still works. The only downside is a small current through the resistor that would normally only consume a small amount of power when the button is pressed will instead be always consuming that small amount of power, except for the moments when you press the button. Usually this is perfectly fine, unless you're making a project that needs to run from a small battery and you've optimized everything else for very low power, where that very small amount of extra power in the resistor could matter.
 
Thanks guys, you've answered my questions. For your own peace of mind, yeah the problem was having power connected to the switch. I haven't tried to salvage the Teensy yet (I just moved onto my ++ I had lying around) so I'll do that tomorrow. Much appreciated!
 
For your next try, adding a 1K resistor between the Teensy pin and the rest of the world can greatly improve reliance to "bad things" damaging your board.

longwires.jpg
 
Status
Not open for further replies.
Back
Top