Author Topic: Spurious chip reset when a bit of metal makes contact  (Read 662 times)

0 Members and 1 Guest are viewing this topic.

Online TauIs2Pi

  • Newbie
  • Posts: 2
  • Country: ca
Spurious chip reset when a bit of metal makes contact
« on: March 08, 2018, 08:32:32 pm »
I'm facing an issue where a chip resets whenever a bit of metal makes contact with any of the rails (ground, +3.3V or +5V) anywhere in the circuit. I should mention I'm a beginner in electronics (coming from the software world, analog issues have me stumped).

I'm getting the issue on a breadboard prototype I'm working on (the end goal is a specialized USB device and multi-port USB host). 5V comes from a USB cable through a USB hub (powered either from a floating power supply or a computer – doesn't make a difference). A linear voltage regulator provides 3.3 volts for a PIC18F microcontroller, a 74HC driving a 7-segment LED display (for quick debugging) and the evaluation board of the MAX3421E.

The MAX3421E is the one that's resetting. I initially found the issue by connecting a USB cable from the evaluation board to a device: it would reset whenever the plug would touch the device's receptacle.

What I know
  • The MAX3421E only does a soft reset, not a full power on reset. (I know this because only some register bits are cleared. This is the same behavior as if I the RES pin became low.)
  • The microcontroller does not reset.
  • The 74HC retains it's latched output (doesn't reset either).
  • Sometimes it takes more than one try to make it happen. For example it is harder to reproduce near the voltage regulator.
  • It doesn't reset if I make contact with my fingers.
My current theory

The only thing I can think of that would explain the symptoms is that, somehow, the voltage on the MAX3421E's RES pin briefly drops (I don't have an oscilloscope to test this). Yet the entire chip stays on (wouldn't it's Vcc drops too if RES did? both are connected to 3.3V).

Demonstration

Here the microcontroller (bottom) continuously polls the MAX3421E (top PCB) and displays the value of a register bit on the screen. It should always be 1. It becomes 0 only if the MAX3421E resets.



What could be happening here? How can an unconnected wire/bit of metal do anything? How can I address this? It's probably obvious, but I can't figure it out!
« Last Edit: March 09, 2018, 12:50:05 am by TauIs2Pi »
 

Offline drussell

  • Frequent Contributor
  • **
  • Posts: 978
  • Country: ca
  • Hardcore Geek
Re: Spurious chip reset when a bit of metal makes contact
« Reply #1 on: March 08, 2018, 08:43:04 pm »
What do you have on there for decoupling capacitors? 

Can't really see closely enough on your animated GIF...
 

Offline plazma

  • Frequent Contributor
  • **
  • Posts: 436
  • Country: fi
    • Homepage
Re: Spurious chip reset when a bit of metal makes contact
« Reply #2 on: March 08, 2018, 08:53:35 pm »
Check decoupling. Add a series ferrite bead to the wire or reset line.
 

Offline capt bullshot

  • Super Contributor
  • ***
  • Posts: 1246
  • Country: de
    • Mostly useless stuff, but nice to have: wunderkis.de
Re: Spurious chip reset when a bit of metal makes contact
« Reply #3 on: March 08, 2018, 09:41:00 pm »
Aside from the boilerplate "this is a breadboard, it'll never work since it is a breadboard" sentence,

There are IC's that have very sensitive RST inputs. The Maxim chip might be one of these, so adding a small capacitor (1nF ... 10nF)  from the RST pin to either GND or the supply voltage (depending on the active level of the input) usually helps. Place this capacitor really close to the IC in your layout (as I said - breadboards don't work well with fast digital stuff).

Safety devices hinder evolution
 

Offline Jeroen3

  • Super Contributor
  • ***
  • Posts: 2940
  • Country: nl
  • Embedded Engineer
    • jeroen3.nl
Re: Spurious chip reset when a bit of metal makes contact
« Reply #4 on: March 08, 2018, 09:49:43 pm »
Is the pc where all the stuff is attached to grounded?
 

Online BrianHG

  • Super Contributor
  • ***
  • Posts: 2626
  • Country: ca
Re: Spurious chip reset when a bit of metal makes contact
« Reply #5 on: March 08, 2018, 10:00:35 pm »
Why does that animation look so well timed after after each increment to 1?
__________
BrianHG.
 

Online ebastler

  • Super Contributor
  • ***
  • Posts: 2042
  • Country: de
Re: Spurious chip reset when a bit of metal makes contact
« Reply #6 on: March 08, 2018, 10:24:32 pm »
Why does that animation look so well timed after after each increment to 1?

Because TauIs2Pi has gone through this motion A LOT before finally deciding to post here, I assume.  ;)
 

Online TauIs2Pi

  • Newbie
  • Posts: 2
  • Country: ca
Re: Spurious chip reset when a bit of metal makes contact
« Reply #7 on: March 09, 2018, 12:03:16 am »
Wow, I did not expect this many replies that quickly, thanks a lot!

What do you have on there for decoupling capacitors? 

There is 100µF at the voltage regulator input and 10µF at the output. The MCU has 0.1µF, and according to the evaluation kit datasheet the MAX3421E has 2.2µF + 1µF.

Check decoupling. Add a series ferrite bead to the wire or reset line.

I'll have to buy some to test that in series. I just tried loosely putting a big clip-on ferrite bead around the reset wire and it made no noticable difference.

Aside from the boilerplate "this is a breadboard, it'll never work since it is a breadboard" sentence,

There are IC's that have very sensitive RST inputs. The Maxim chip might be one of these, so adding a small capacitor (1nF ... 10nF)  from the RST pin to either GND or the supply voltage (depending on the active level of the input) usually helps. Place this capacitor really close to the IC in your layout (as I said - breadboards don't work well with fast digital stuff).

Indeed, I did run into problems with random corrupted data when talking to the MAX3421E through SPI @ 12MHz. I thought the breadboard capacitance(?) might be smoothing out the signals so I tried lowering the clock speed and the corruption went away. Full-speed USB communication between the PIC and the PC does work though (but there could be retried packets due to occasional corruption, I don't know).

Would using a soldered prototype board really be much better in this regard?

----

Putting a 10nF capacitor closer helps with the resets! I'm holding it (will probably solder it on the wires later) right in front of the evaluation board's big connector and I don't get spurious resets when making contact with random metallic objects anymore (I had only tried putting such a capacitor on the breadboard side of the reset wire before). The MAX3421E's RES is active low. What is the best place to put the capacitor? I don't notice a difference between +3.3/RES or RES/GND.

However, it still resets if I'm connected to earth ground through the PC and I make contact with a device's USB receptacle while it's plugged in (or directly to it's barrel jack's negative source, which is not earth grounded). So the issue is not completely solved, but that's progress! :D

Is the pc where all the stuff is attached to grounded?

Yes: 11 ohms between the PC usb plug's outside and the earth ground pin of the PC's wall plug.

Why does that animation look so well timed after after each increment to 1?

It's 2X real-time speed to make the video nicer. ;)
« Last Edit: March 09, 2018, 12:34:44 am by TauIs2Pi »
 

Online BrianHG

  • Super Contributor
  • ***
  • Posts: 2626
  • Country: ca
Re: Spurious chip reset when a bit of metal makes contact
« Reply #8 on: March 09, 2018, 12:38:22 am »
Does it reset if you touch the wire with your hand?
__________
BrianHG.
 

Offline capt bullshot

  • Super Contributor
  • ***
  • Posts: 1246
  • Country: de
    • Mostly useless stuff, but nice to have: wunderkis.de
Re: Spurious chip reset when a bit of metal makes contact
« Reply #9 on: March 09, 2018, 12:45:59 am »
Quote
Would using a soldered prototype board really be much better in this regard?
Depends on the layout ...

Quote
The MAX3421E's RES is active low. What is the best place to put the capacitor? I don't notice a difference between +3.3/RES or RES/GND.
Usually one would connect the small capacitor from RES to GND. If connecting to +3.3V is better depends on the layout, just go for the GND connection, that is what I'd do here. Put it as close as possible to the IC. Maybe solder a small SMD cap directly onto the eval board.

Quote
However, it still resets if I'm connected to earth ground through the PC and I make contact with
a device's USB receptacle while it's plugged in (or directly to it's barrel jack's negative source, which is not earth grounded). So the issue is not completely solved, but that's progress!
A proper PCB with ground plane and proper decoupling would help here.
« Last Edit: March 09, 2018, 12:49:41 am by capt bullshot »
Safety devices hinder evolution
 

Offline Peabody

  • Frequent Contributor
  • **
  • Posts: 340
  • Country: us
Re: Spurious chip reset when a bit of metal makes contact
« Reply #10 on: March 09, 2018, 01:58:25 am »
The datasheet says the logic level on /Reset is referenced to VL.  Also the Device Reset section details a number of ways a reset can occur other than through the /Reset pin.  From the description you might be able to tell which one is happening.

Also, did you say what pullup resistor you're using on /Reset?  If a lower value, or even a direcct tie, makes no difference, then the reset may be coming from somewhere else.
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf