Does one wire cap sense really work on trinket without USB?

Adafruit's tiny microcontroller platform. Please tell us which board you are using.
For CircuitPython issues, ask in the Adafruit CircuitPython forum.

Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.
Locked
User avatar
miktek1
 
Posts: 12
Joined: Tue Mar 16, 2021 9:00 pm

Does one wire cap sense really work on trinket without USB?

Post by miktek1 »

I've been unsuccessful with any kind of reliable touch sensing with the Trinket M0 without USB and PC attached. (I use PC with WIN10)
By reliable, I mean the way it works when connected to USB which is great.
Without USB connected, for me, sensing a "touch" is wildly intermittent using a small regulated supply or DC to DC converter +5V to the bat pin on the Trinket M0

I'm it has to do with the USB ground being taken away, but I've looked at the 5V power signal with a scope. Clean
I have tried it with Arduino IDE and the Adafruit_FreeTouch.h library. I have learned CP and used the touchio library per the example. Same Issue
It's even unreliable when trying to drive the onboard led with a touch!

https://learn.adafruit.com/circuitpytho ... -cap-touch

Using CP code with touchio I have spent a lot of time trying multiple threshold settings etc. Same issue

But to actually control anything without connecting to USB, is there any product or example anyone can point to?
My assumption (maybe wrong) is that this chip could be used with projects that could be appropriately independently powered.
When I look at the products and kits in Adafruit though, the pics all show the USB cable connected. Maybe that should have been my clue?

Has anyone made anything that operates the Trinket M0 using Capacitive touch, without a battery or USB connected computer to it?

Thanks

User avatar
CircuitFlyer
 
Posts: 21
Joined: Thu Sep 17, 2020 11:01 pm

Re: Does one wire cap sense really work on trinket without U

Post by CircuitFlyer »

I have reliably used touchio in my Trinket M0 projects and have not experienced the issues you describe. I know thats not a lot of help but , yes, I was able to get it to work for me. Granted, I don't extend the wiring to the touch pin. I just solder on a pin header and use the exposed pin for a touch contact. I had some glitchy behaviour originally but finally corrected my poor coding to debounce the pin properly and that was a big improvement. I found no difference in operation between USB power or battery power.

Locked
Please be positive and constructive with your questions and comments.

Return to “Trinket ATTiny, Trinket M0”