Go Down

Topic: My Arduino is running w/o power supply and USB (Read 1 time) previous topic - next topic

WPD64

Good evening everybody

I'm observing the strangest behaviour on my Arduino.
It appears to running without power supply or USB connection. Instead it is driven by the input signal.

I am using two usb wall chargers to monitor two 230V lines and send +5V to my analog-in when either of these lines is hot.

Both power supplies (ps1, ps2) share a common GND (on the output) which I belive is a 'floating ground' (excuse me - I'm not a native speaker) i.e. has no defined potential.

So I connected these 2 gnd's to the Arduino's (the 2 GND pins adjacent to A0, A1, A2, ...)


      -- +5V ------------ A1
ps1
      --  gnd ----------- GND
                   |
      --  gnd --
ps2
      -- +5V ------------ A2


My sketch does read proper singnals when run by USB.

When I inplug USB and operate on a power supply the sketch gets hickups and works ~ 90%
The behaviour is very inconsistent and involves Ethernet-connection stalls.

Just now did I notice that the Arduino is running w/o power supply... as long as 'ps1' or 'ps2' is ON.
What is going on ??

Koepel

#1
Dec 21, 2015, 08:18 pm Last Edit: Dec 21, 2015, 08:19 pm by Koepel
Watch this : https://www.youtube.com/watch?v=2yFh7Vv0Paw

The microcontroller has internal clamping diodes on every pin. The voltage will flow into the Arduino pin via the internal clamping diode to the 5V, possibly damaging the microcontroller.

Never connect a voltage source to a pin. Use a resistor (for example 4k7 or 10k) between the voltage and the Arduino pin.

WPD64

Oh, ok.
I'll watch the video right away.

Just one question/remark:
I'd consider any signal a 'voltage source'. You probably mean a "power-providing" or "low-internal-resistance" voltage source - right?

Koepel

Yes, a voltage from a battery or power supply is low-internal-resistance. Those should be connected to an analog pin via a resistor.

MarkT

In circuit theory a "voltage source" has zero (dynamic) resistance, a "current source" infinite.
A voltage source by definition always maintains a fixed voltage between its terminals, a current
source maintains a fixed current.
[ I will NOT respond to personal messages, I WILL delete them, use the forum please ]

WPD64

Well as an Arduino noob I was expecting the input lines to be of high impedance.
As they are on volt meters or oscilloscopes - which makes pretty much anything behave as "voltage source".


Anyway, there is no true voltage source for an arbitrary impedance -  a thunderbolt maybe for some ms :-)

Grumpy_Mike

#6
Dec 21, 2015, 11:00 pm Last Edit: Dec 21, 2015, 11:01 pm by Grumpy_Mike
Quote
Well as an Arduino noob I was expecting the input lines to be of high impedance.
They are when the Arduino is powered up. When it is not powered it just looks like a diode. This applies to any piece of electronics not just an Arduino.

What you are seeing is known as parasitic powering and is a good way to destroy a chip.


Quote
I'm observing the strangest behaviour on my Arduino.
So no it is not strange is is what will happen and is what is expected to happen.

Quote
As they are on volt meters or oscilloscopes
No that works just the same, a input probe often has a series 10M resistor though.

polymorph

In fact, someone made their own RFID tag with an Atmel AVR that relies on those input protection diodes to power the chip.

In his original version, there was only the tuned coil and capacitor, it relied on the internal die capacitance to smooth the supply voltage. In later versions, he added a small capacitor from Vcc to Gnd.

And the coil is connected across the Clock input and another IO pin, so the 125kHz RFID signal is also the system clock.

http://scanlime.org/2008/09/using-an-avr-as-an-rfid-tag/

Then this one really pushes it and doesn't use -any- capacitors, relying on brute-force transformer coupling.

http://www.nycresistor.com/2012/12/27/rfid-multipass/
Steve Greenfield AE7HD
Drawing Schematics: tinyurl.com/23mo9pf - tinyurl.com/o97ysyx - https://tinyurl.com/Technote8
Multitasking: forum.arduino.cc/index.php?topic=223286.0
gammon.com.au/blink - gammon.com.au/serial - gammon.com.au/interrupts

WPD64

No that works just the same, a input probe often has a series 10M resistor though.
So oscilloscopes and volt meters have high input resistance don't they

Grumpy_Mike


WPD64

Ok - learnt something here.

Problem solved by means of two resistors as suggested.
Sketch running fine. Thanks to all of you.

Cheers

Go Up