Teensy 4.0 wont run code unless battery terminal is jiggled??

derplecbob

Active member
I’m using a teensy 4.0 soldered to the led/sound/accelerometer prop shield.
I have the positive end of a 3.7v lithium ion battery soldered to the positive of the board and the positive of some addressable led strip, and the negative soldered in the same way so both are powered directly from the battery, with one power switch in between the battery and the board power along with a charging port wired correctly.

The teensy runs my led code when a usb is plugged into it. Without the usb cable, It only runs the code when I jiggle the battery terminal which initially starts the code and then it runs fine.
But if I turn off the power switch and back on again, the code never runs unless I jiggle the battery terminal too.

I think it’s a current issue because the board has proper voltage and all the wires are correct and soldered completely.

I don’t know why it would work only when I “spark it” the right way?

The battery positive is the same as the board positive and the led positive. And the battery negative is the same as the board negative and the led negative.

Any ideas as to what is going on??
 
I think your probably right actually.
It runs fine at 3.0v with the usb so I don’t think it’s the voltage regulator.
I’ll rewire the wires providing power after work and that should probably do it. Thank you
 
Damn. I made sure all the wires were soldered cleanly and even replaced the on off switch and it still is acting the same. Does it make a difference whether I solder power to the 5v and gnd of the prop shield, or the 5v and gnd of the teensy 4.0? I have it connected to the propshield currently.
The led on the teensy also doesn’t light up when I use the battery, only when I plug in the usb.
 
Sorry can only throw darts. Might help if we actually saw picture. Like how is propshield connected to teensy?

Did you check out the thread about some T4s and Voltage regulators?

Not sure why jiggling would make difference.

Is it jiggling it or time? that solves it? for example, if your code has something in it like:
while (!Serial && millis() < 5000) ;

Won't start for 5 seconds if not plugged into USB (and serial monitor connected).
 
So unfortunately as picture will probably just be more confusing.

The teensy is soldered on top of the propshield with all the pins connected as shown on their website.

Battery is connected to the propshields 5v and gnd on the side with the speaker + and -.
Should I solder the battery to the teensys 5v and gnd instead or does it matter?

I looked at those other threads about the voltage regulators but I don’t think that’s the problem because it can still run even if the battery is below 4v

And I have a delay so it’s not a timing issue

And I’m not exactly jiggling the connection because all the wire connections are solid.
But the positive wire that connects to the battery, if I disconnect it and reconnect it in just the right way, then it will turn on.
I think that by sparking the wire does the trick (maybe the tiny arc increases the current for a second so it’s able to turn on) I’m not sure tho
It’s like if I touch the wire to the battery 100 times, it turns on only 10% of the time

And I’m still not sure why the battery never turns the teensys led on
 
Just jumping in here now. If you read post #7 Paul stated that:
ooks like there is indeed a hardware issue with some Teensy 4.0 boards not starting up with less than 4 volts at VUSB / VIN. It's related to the voltage regulator chip.

In his followup post #9 in the same thread he mentioned a fix to get it to start below 4volts. Also in Post#10 he mentioned the latest batch of boards will be able to start down to 3.2 volts.

Not sure if this helps

EDIT: also since you are using the propsheild attached to the T4 you will not be able to use audio. The audioGnd is now just GND on the T4.
 
Actually now that I think about it, it might be the voltage regulator problem.
The battery that works sometimes is right on the cusp of 4v, just a hair under.
Maybe by sparking it just right it goes above 4v for a split second enough for it to turn on.

Is there a way to test if the voltage regulator I have is a AP7366?
And should I try cutting the r4 resistor if it is?
 
Actually now that I think about it, it might be the voltage regulator problem.
The battery that works sometimes is right on the cusp of 4v, just a hair under.
Maybe by sparking it just right it goes above 4v for a split second enough for it to turn on.

Is there a way to test if the voltage regulator I have is a AP7366?
And should I try cutting the r4 resistor if it is?

Sorry - can;t answer that question maybe someone with more knowledge can answer. Don't know if you will be able to read the chip markings.

As for removing R4 that is solely up to you. Warning
But without R4 the 15 second button press restore process will not work. Nothing bad will happen, it just won't work and your Teensy will reboot right after you release the pushbutton (if within 4 seconds of the quick red LED blink). R4's only purpose is to keep the power turned on during the restore process.

Guess what I would do is get a variable power supply and raise the voltage on vin to see where it starts - I would use blink to test with though.
 
Yeah thank you I’ll give that a try after work. I’ve never used the restore function so that should be fine. I never even realized that was a feature.
Thanks for your guys help
I’ll report back if that fixes it :)
 
Back
Top