Go Down

Topic: CPU effects chip sensitivity (Read 1 time) previous topic - next topic

treebykooba

Dec 31, 2015, 06:59 pm Last Edit: Dec 31, 2015, 07:38 pm by treebykooba
Hello,
I'm using a CAP1188 (touch sense) from Adafruit as a touch controller for a video game. (UnrealEngine4 using UE4Duino plugin) It works fine when I don't have the game (or UnrealEngine) open...it is easy to control the sensitivity and get a reading in the serial port.

As soon as I do anything CPU intensive (play a video game, render something in 3D) the chip becomes VERY dulled...I have to literally touch the contacts directly to get any reading on it.

The weird thing is, I tried this on a very similar PC build and it only seems to be doing it on this particular machine....but I need to use this PC for this particular project.

Any trouble shooting ideas to keep the sensitivity the same no matter what the CPU is doing?

Some things I tried:
-powered arduino separate with 9V supply and left the USB in (I think then it would take power from 9V and just use USB for serial readings). This improved things ever so slightly.
-I'd like to decouple it but I'm not sure how. Just put a .1uf in between the cap1188 vin and gnd? or i assume it's already decoupled?
-used a usb cable with a choke...no difference.

Thanks for any help!

Coding Badly


Powered USB hub.  I suspect the PC's power supply is ... well ... let's call it "unacceptable".



treebykooba

#2
Dec 31, 2015, 07:51 pm Last Edit: Dec 31, 2015, 07:57 pm by treebykooba
thanks for the help! i'm now powering the arduino (it's a duemilanova if that makes a difference) with a separate power supply (9v) and (i think) only using the USB to read the serial data. but i'm still getting the same problem! argh!
and my PSU is 750W...I'm pretty sure it can handle the arduino and cap1188? but who knows...

DrAzzy

#3
Dec 31, 2015, 08:30 pm Last Edit: Dec 31, 2015, 08:48 pm by DrAzzy
I suspect some sort of stupid driver/system problems, particularly if it works on another similar PC. I've seen (without fully understanding why) huge differences in performance between outwardly similar PCs when playing some video games.

Hell, one game I used to play, this one effect made the frame rate drop to under 1FPS on almost everything. Except a few low spec laptops that sucked for everything else would handle that effect without slowing down. That's a spectacular example, but I've seen similar crap on a less dramatic scale.

Could the computer be overheating when the game is running, and downclocking something to deal with that? That can utterly destroy performance in a way that bogs down input mechanisms too.

I suspect the arduino is doing just fine, but that communication with the PC is the problem?

Oh - crazy thought  - is there a sheet of metal (like the computer case) between the Arduino/touch sensor/etc? Maybe electrical noise from the power supplies that's supposed to be contained by the metal case, but isn't, because you have the case off?
ATTinyCore and megaTinyCore for all ATtiny, DxCore for DA/DB-series! github.com/SpenceKonde
http://drazzy.com/package_drazzy.com_index.json
ATtiny breakouts, mosfets, awesome prototyping board in my store http://tindie.com/stores/DrAzzy

treebykooba

#4
Dec 31, 2015, 09:08 pm Last Edit: Dec 31, 2015, 09:48 pm by treebykooba
man you had me excited that it was just a driver problem...i updated to the latest arduino ide to 1.6.7 and now from my device manager i see that the drivers are the same as on the other newer PC.

the computer could be overheating...but I can also run this game all day and the computer never shuts down so it can't be overheating that badly. it was a little dusty but I cleaned it the best as I could...

both these PCs are built on these open racks...they're not in cases. the mobo and arduino is all installed on elevated bolts on plexi. the cap 1188 is on a wire that extends out around two feet and it's soldered onto a perf board.

i tried decoupling using a choke a 50uf cap and a .1uf cap....no change :-(

ALSO - I'm having this problem whether or not the arduino is plugged into USB! if i just leave the 9V connected but the CPU is working hard, the cap1188 becomes very desensitized...if I move it about 4' from the CPU it works. But for this project I need it around 2' from CPU!
Any ideas?

anything else?????? arghhhhhh

MarkT

Sounds like interference from the screen is at frequency that the touch IC is sensitive to.

LCD screens put out a strong square-wave signal from the whole area of the screen as the polarity
is constantly reversed to prevent any DC component across the liquid crystal.  This frequency may
or may not be sensitive to the refresh rate of the screen, I think that depends on the TFT driver
architecture, but this signal is easy to see if you ever have a 'scope near a screen.

You could try TEMPESTing the screen with fine metal mesh perhaps or trying to alter the frequency
somehow.
[ I DO NOT respond to personal messages, I WILL delete them unread, use the forum please ]

treebykooba

I don't think it's the screen as this only happens when the CPU is working hard... I used the same monitor with a different computer and this didn't happen

MarkT

In that case it sounds like the PSU or the DC-DC converter on the motherboard is pushing out a lot of EMI at an
unfortunate frequency.  This is where dangling a scope-probe around various parts of the machine
would be quite informative.
[ I DO NOT respond to personal messages, I WILL delete them unread, use the forum please ]

DrAzzy

In that case it sounds like the PSU or the DC-DC converter on the motherboard is pushing out a lot of EMI at an
unfortunate frequency.  This is where dangling a scope-probe around various parts of the machine
would be quite informative.
I'd look into shielding it - some grounded tinfoil between the computer and arduino would probably help.
ATTinyCore and megaTinyCore for all ATtiny, DxCore for DA/DB-series! github.com/SpenceKonde
http://drazzy.com/package_drazzy.com_index.json
ATtiny breakouts, mosfets, awesome prototyping board in my store http://tindie.com/stores/DrAzzy

treebykooba

Oh interesting I'll try that. Should I make like a tinfoil box and put the touch sensitive chip in there? Also where do I ground it from? From ground on the arduino or the PSU?

treebykooba

ok i tried putting the touch sensitive chip in a box covered with aluminum foil and with two leads sticking out. it made it worse. i tried grounding the box...no change. i tried covering the motherboard with an aluminum sheet...a little difference.

but then i made the chord connecting the cap1188 to the arduino like 5' longer and voila...it's MUCH more reliable now. weirdly if I tie up this newly long chord...it stops working again.

so weird. i'm learning a lot. anyone know why this would be? I need to get this project out of the studio and into the real world so I'd like it to be as reliable as possible.

thanks and happy new year.

aarg

#11
Jan 01, 2016, 10:38 pm Last Edit: Jan 01, 2016, 10:41 pm by aarg
anyone know why this would be?
Because parasitic capacitance and inductance in conductors becomes a lot more significant at higher frequencies. When you rearrange or move the wires those change those impedances significantly.

Bottom line: You need to take a solid engineering approach to shielding, grounding, and possibly filtering. It's kind of like getting rid of bedbugs - you can't find and kill them individually, you have to just enclose and fumigate the entire building.

There isn't a simple cure. It's a matter of incorporating a variety of good engineering practices. Some are just physical and others are more theoretical. You can't really do this properly in a hurry.
  ... with a transistor and a large sum of money to spend ...
Please don't PM me with technical questions. Post them in the forum.

Go Up