0

Trinket M0 locks up when powered by USB power adapter
Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.

Trinket M0 locks up when powered by USB power adapter

by Xprt_mike on Fri May 03, 2019 2:47 am

I have Trinket M0 running circuit python. the project has an IR sensor and turns a relay on when the "Power On" button is pressed on the remote. The relay turns off when you press the "Power off" button on the remote. I open the code in Mu and when I click save everything works correctly. I then unplug the USB cable from the PC and connect it to a 110V-USB power adapter. Now the "Power On" works but it won't "Power Off". it seems like it only locks up when powered by the USB power adapter.

Has anyone ever seen this before? I have tried multiple USB power adapters and it always gets stuck after the relay turns on.

Xprt_mike
 
Posts: 6
Joined: Sun Feb 25, 2018 6:30 am

Re: Trinket M0 locks up when powered by USB power adapter

by adafruit_support_mike on Fri May 03, 2019 4:12 am

Post a photo showing your hardware and connections and we'll take a look. 800x600 images usually work best.

adafruit_support_mike
 
Posts: 59172
Joined: Thu Feb 11, 2010 2:51 pm

Re: Trinket M0 locks up when powered by USB power adapter

by Xprt_mike on Fri May 03, 2019 5:30 pm

TrinketIRRelay_bb.jpg
TrinketIRRelay_bb.jpg (142.52 KiB) Viewed 251 times

Xprt_mike
 
Posts: 6
Joined: Sun Feb 25, 2018 6:30 am

Re: Trinket M0 locks up when powered by USB power adapter

by adafruit_support_mike on Fri May 03, 2019 9:34 pm

Post a photo of the actual hardware please. The problem you've described sounds like it could be related to a connection problem, and those don't show up in diagrams.

adafruit_support_mike
 
Posts: 59172
Joined: Thu Feb 11, 2010 2:51 pm

Re: Trinket M0 locks up when powered by USB power adapter

by Xprt_mike on Sun May 05, 2019 5:53 am

After further testing i notice the locking up behavior when first connected to the computer. Once I open the code and then save it, it works correctly but only after saving.

Xprt_mike
 
Posts: 6
Joined: Sun Feb 25, 2018 6:30 am

Re: Trinket M0 locks up when powered by USB power adapter

by Xprt_mike on Tue May 07, 2019 1:23 am

I flashed the Trinket with an Arduino blink sketch and then reloaded circuit-python and copied back the library file and code.py. Now it works from a USB power adapter. I didn't change any wiring connections so the issue could not have been a connection problem.
On the plus side, It works!

Xprt_mike
 
Posts: 6
Joined: Sun Feb 25, 2018 6:30 am

Re: Trinket M0 locks up when powered by USB power adapter

by adafruit_support_mike on Tue May 07, 2019 1:37 am

Glad to hear you got it working. Happy hacking!

adafruit_support_mike
 
Posts: 59172
Joined: Thu Feb 11, 2010 2:51 pm

Please be positive and constructive with your questions and comments.