Dual supply, dead UNO, what is the correct way?

I have a pixel LED dev board. It has a 12V supply and a 5V regulator for the ATTiny85.

I program it using the ISP pins from an UNO which has the USB connected. “Arduino as ISP”

I have found last night that it is possible to kill the UNO, somehow, by powering OFF the 12V supply.

The UNO seems to short out.

The 5V regulator will short to ground if you apply voltage to it’s Vout pin. All I can think is the ISP pins on the ATTiny85 provide a route to ground for the UNO’s 5V.

The UNO itself seems fine, but the CH340 USB interface appears to be dead.

How can I avoid this in future? The LED dev board does not provide a 5V power output. So even if I wanted to cut the USB power leads the LED board will not power the UNO.

venquessa: I have a pixel LED dev board. It has a 12V supply and a 5V regulator for the ATTiny85.

I program it using the ISP pins from an UNO which has the USB connected. "Arduino as ISP"

I have found last night that it is possible to kill the UNO, somehow, by powering OFF the 12V supply.

The UNO seems to short out.

The 5V regulator will short to ground if you apply voltage to it's Vout pin. All I can think is the ISP pins on the ATTiny85 provide a route to ground for the UNO's 5V.

The UNO itself seems fine, but the CH340 USB interface appears to be dead.

How can I avoid this in future? The LED dev board does not provide a 5V power output. So even if I wanted to cut the USB power leads the LED board will not power the UNO.

A link to the pixel display please. a block diagram of how everything was connected please. how does the ATTiny85 fit into this?

the 5v regulator used on the Arduino UNO has short-circuit protection. Also looking at the Arduino UNO Schematic I do not see a path in the 5v regulator circuit to short to ground.

artisticforge:
A link to the pixel display please.
a block diagram of how everything was connected please.
how does the ATTiny85 fit into this?

the 5v regulator used on the Arduino UNO has short-circuit protection.
Also looking at the Arduino UNO Schematic I do not see a path in the 5v regulator circuit to short to ground.

I’m in work, so diagram upload would be difficult. Let me try and explain and ASCII art my way out of this.

High Level it’s a standard Arduino as ISP programmer for the ATTiny85. The ATTiny85 is controlling the 12V LED strip, the UNO is programming the ATTiny85. The UNO gets it’s power from the USB. The ATTiny gets it’s power via a 5V regulator from the 12V LED supply.

USB → Arduino UNO → ISP Programming lead → ATTiny85(MOSI, MISO, SCLK, RST, GND) (pin 3) → WS2811 60 LED 12V Strip

The Arduino UNO is power by the USB 5V.

The LED Driver board is powered from a 12V supply. The ATTiny85 gets power from an LM78L05 regulator.

So the power diagram looks like:

USB-5V → UNO | ISP SPI+GND no power| ATTiny85 ← 5V REG ← 12V → WS2811 LED strip.

No 12V power reaches either UNO or ATTiny85. No power from the UNO or ATTiny85 reaches the LEDs.

I recently discovered the LM78L05 will short to ground if you put a high voltage on it’s Vout than it’s Vin. So for example if you are powering a 5V circuit from 12V via the regulator and attempt to put 5V directly yourself and power off the 12V supply. This shorts the 5V through the regulator to ground. The regulator gets very hot.

What I believe has happened here is that one of the SPI pins has been high/5V. When I powered off the 12V supply that 5V has found a route through the ATTiny85 to it’s Vcc pin. That has then routed to GND via the LS78L05 and the USB CH340 IC in the UNO has taken a beating.

The visible sumptons were that when I powered off the 12V supply the UNO’s lights dimmed and went out. I confirmed it was not being powered by the 12V side by removing the USB lead. The UNO powered off. This leads me to conclude that the voltage regulator shorted it out.

You need to disconnect the VCC connection on the 6 wire ISP connection between the Uno and the ATtiny85.

avr_fred: You need to disconnect the VCC connection on the 6 wire ISP connection between the Uno and the ATtiny85.

There is no Vcc connection between them.

MOSI, MISO, SCLK, RST, GND only.

You are disconnecting the ISP connection after programming, right? I thought that would be a given...

If you're not disconnecting, you're parasitically powering the '85 from the Uno through the ESD diodes when the 12v is off. If you want to keep them connected, you need to isolate supplies. Power the Uno from the '85 side by cutting the +5v in the USB cable and add the VCC wire on the ISP connection.

avr_fred: You are disconnecting the ISP connection after programming, right? I thought that would be a given...

Sometimes, but I was programming in a rapid iterative cycle last night. Tweak, upload, test, repeat. It was doing fine, until my LEDs (or the ATTiny85) crashed. So I power cycled the 12V supply while the ISP connection was in place.

That's when I noticed the UNO's power light went out when I did so.

avr_fred: If you're not disconnecting, you're parasitically powering the '85 from the Uno through the ESD diodes when the 12v is off. If you want to keep them connected, you need to isolate supplies. Power the Uno from the '85 side by cutting the +5v in the USB cable and add the VCC wire on the ISP connection.

Okay. Thanks.

So as long as I keep the programed device powered I should be fine.

I will consider opening the LED board (cutting the heatshrink off it) and adding a Vcc from the regulator for the UNO).

I have 2 UNOs in the post to replace. I think I can salvage the ATMega328p out of it though. Just the USB Ch340 died. I believe.

venquessa:
I’m in work, so diagram upload would be difficult. Let me try and explain and ASCII art my way out of this.

High Level it’s a standard Arduino as ISP programmer for the ATTiny85. The ATTiny85 is controlling the 12V LED strip, the UNO is programming the ATTiny85. The UNO gets it’s power from the USB. The ATTiny gets it’s power via a 5V regulator from the 12V LED supply.

USB → Arduino UNO → ISP Programming lead → ATTiny85(MOSI, MISO, SCLK, RST, GND) (pin 3) → WS2811 60 LED 12V Strip

The Arduino UNO is power by the USB 5V.

The LED Driver board is powered from a 12V supply. The ATTiny85 gets power from an LM78L05 regulator.

So the power diagram looks like:

USB-5V → UNO | ISP SPI+GND no power| ATTiny85 ← 5V REG ← 12V → WS2811 LED strip.

No 12V power reaches either UNO or ATTiny85. No power from the UNO or ATTiny85 reaches the LEDs.

I recently discovered the LM78L05 will short to ground if you put a high voltage on it’s Vout than it’s Vin. So for example if you are powering a 5V circuit from 12V via the regulator and attempt to put 5V directly yourself and power off the 12V supply. This shorts the 5V through the regulator to ground. The regulator gets very hot.

What I believe has happened here is that one of the SPI pins has been high/5V. When I powered off the 12V supply that 5V has found a route through the ATTiny85 to it’s Vcc pin. That has then routed to GND via the LS78L05 and the USB CH340 IC in the UNO has taken a beating.

The visible sumptons were that when I powered off the 12V supply the UNO’s lights dimmed and went out. I confirmed it was not being powered by the 12V side by removing the USB lead. The UNO powered off. This leads me to conclude that the voltage regulator shorted it out.

With the UNO connected to the USB of the computer the current supplied by the Computer’s USB port is limited.

What are you caling the “USB CH340 IC”. I do not find such a chip in the Arduino UNO Schematic nor do I find it on the Arduino UNO Board. I just finished a high magnification inspection of of the Arduino UNO that I have and I find no CH340 markings on any chip.

Can you post a photograph of the Arduino UNO Board that you have with this chip circled in Red?

I have a feeling something else to happening here.

I am very skeptical of your claim that you do not have the 5v of the Uno connected to 5v of the Tiny85 - if you did, things would mostly make sense (except for it actually doing damage to the board) - if the 12v supply put a load on it’s outputs when it was turned off (not implausible), or the connector was one of those barrel jack sockets where the contact that touches the outside of the barrel, and the pin that goes down the middle touch when the plug is removed, the Vin rail would be near-shorted. And most linear regulators have an internal diode between Vout and Vin, to keep Vout from rising much above Vin (presumably this would damage the part if allowed to happen). So you’d be connecting the Uno’s supply to a high/near-short load.

But if the uno’s 5v isn’t connected to target’s 5v that’s rather mysterious…

And in any event, shorting the power rails shouldn’t do damage… have you tried using a different USB port? Rebooting the system? Sometimes overcurrent on a USB port can leave the port in a bad state until powercycle.

artisticforge:
With the UNO connected to the USB of the computer the current supplied by the Computer’s USB port is limited.

What are you caling the “USB CH340 IC”. I do not find such a chip in the Arduino UNO Schematic nor do I find it on the Arduino UNO Board. I just finished a high magnification inspection of of the Arduino UNO that I have and I find no CH340 markings on any chip.

Can you post a photograph of the Arduino UNO Board that you have with this chip circled in Red?

I have a feeling something else to happening here.

Most arduino clones use a CH340G in place of the 16u2 - it’s a purpose-made USB-serial adapter IC that works at least as well in that role as the 16u2 on the official boards does. Usually the CH340G is pretty resistant to abuse (the 16u2 used on official boards seems to be much easier to damage by doing things like this).

DrAzzy:

Most arduino clones use a CH340G in place of the 16u2 - it’s a purpose-made USB-serial adapter IC that works at least as well in that role as the 16u2 on the official boards does. Usually the CH340G is pretty resistant to abuse (the 16u2 used on official boards seems to be much easier to damage by doing things like this).

thank you. i have wasted a good part of my day trying to figure this out.
I am looking at an Arduino UNO and he is using a clone.
I should have guessed that.

artisticforge: I am looking at an Arduino UNO and he is using a clone.

It's open source Isn't it? Then there is no such thing as a "clone". Is Ubuntu a "clone" of Debian? No.

Did I buy the overly expensive Italian board. No.

Actually this one came as part of an IoT kit I got as a present for Christmas. I was using cheap nanos before then.

The USB chip is totally dead.

[  613.622819] usb 3-1: new full-speed USB device number 3 using xhci_hcd
[  613.742864] usb 3-1: device descriptor read/64, error -71
[  613.852816] xhci_hcd 0000:06:00.0: WARN urb submitted to disabled ep
[  613.852824] xhci_hcd 0000:06:00.0: WARN urb submitted to disabled ep
[  613.852828] xhci_hcd 0000:06:00.0: WARN urb submitted to disabled ep
[  613.972824] usb 3-1: device descriptor read/64, error -2
[  614.202792] usb 3-1: new full-speed USB device number 4 using xhci_hcd
[  614.322820] usb 3-1: device descriptor read/64, error -71
[  614.432814] xhci_hcd 0000:06:00.0: WARN urb submitted to disabled ep
[  614.432822] xhci_hcd 0000:06:00.0: WARN urb submitted to disabled ep
[  614.432826] xhci_hcd 0000:06:00.0: WARN urb submitted to disabled ep
[  614.552855] usb 3-1: device descriptor read/64, error -2
[  614.782815] usb 3-1: new full-speed USB device number 5 using xhci_hcd
[  614.784184] usb 3-1: Device not responding to setup address.
[  614.994165] usb 3-1: Device not responding to setup address.
[  615.202812] usb 3-1: device not accepting address 5, error -71
[  615.332766] usb 3-1: new full-speed USB device number 6 using xhci_hcd
[  615.334178] usb 3-1: Device not responding to setup address.
[  615.544180] usb 3-1: Device not responding to setup address.
[  615.752811] usb 3-1: device not accepting address 6, error -71
[  615.752852] usb usb3-port1: unable to enumerate USB device

I have tried different ports, rebooted, checked the ports with other devices.

If a short didn't kill it something else did. Maybe unrelated. Maybe just a cheap board. shrug.

I'll give you one thing about this board. Osoyoo or something.

It is a bit dodgy. I am 99% sure it IDed on USB as CH340 but the chip on the board has a rather suspicious looking stamp that reads Atmel 16U2. So that chip is fake. They scored CH340 out and stamped the Atmel chip marking onto it.

Of course there is the change, the 1% that I remembered wrong.... or that my Linux id'd it as a CH340 incorrectly.

Either way it's gone to the big DIL socket in the sky.

I am 99% sure it IDed on USB as CH340 but the chip on the board has a rather suspicious looking stamp that reads Atmel 16U2. So that chip is fake. They scored CH340 out and stamped the Atmel chip marking onto it.

The packaging says it all. The CH340G is only available as a 16 pin SOIC, the 16u2 is only available in QFN32 and TQFP32. So which is it?

venquessa: I'll give you one thing about this board. Osoyoo or something.

It is a bit dodgy. I am 99% sure it IDed on USB as CH340 but the chip on the board has a rather suspicious looking stamp that reads Atmel 16U2. So that chip is fake. They scored CH340 out and stamped the Atmel chip marking onto it.

Of course there is the change, the 1% that I remembered wrong.... or that my Linux id'd it as a CH340 incorrectly.

Either way it's gone to the big DIL socket in the sky.

Are you sure it wasn't IDing something else you had connected as CH340G?

That being a 16u2 is also more consistent with the chip failing when the power rails were abused - we get a lot of reports of the 16u2 failing at the same time that something was being done to the power rail.

avr_fred: The packaging says it all. The CH340G is only available as a 16 pin SOIC, the 16u2 is only available in QFN32 and TQFP32. So which is it?

It's square about 0.5mm across and has about 8 pins on each of the 4 sides.

Maybe I hallucinated the CH340, to be honest I have had that much bad luck with USB to serial converters either not being idented on USB or not being able to program a chip on a breadboard or only able to program the UNO if I hold reset, that I have lost track.

Anyway on a plus point. This is the output I got before everything died on me.

It's a mickey mouse bit of programming practice/play.

I call it "collision".

The video doesn't start early enough, but... the white ones miss completely and pass through the blue target, then they bounce off the green target (need to implement momentum), then they collide and explode on the red target.

https://www.youtube.com/watch?v=J7GEjGgwBRA

venquessa: It's square about 0.5mm across and has about 8 pins on each of the 4 sides.

QFN-32

Sounds like a 16u2 (ie, it's an official board or faithful clone). As I noted above, the 16u2 seems particularly easy to damage by abusing the power rails - I don't understand why it's so fragile in this way, but it seems to be the case - the CP2102 and CH340G adapters on clones, we almost never have people here reporting actual hardware problems with them (driver issues, another matter altogether)

venquessa: It's open source Isn't it? Then there is no such thing as a "clone". Is Ubuntu a "clone" of Debian? No.

Did I buy the overly expensive Italian board. No.

Actually this one came as part of an IoT kit I got as a present for Christmas. I was using cheap nanos before then.

The USB chip is totally dead.

[  613.622819] usb 3-1: new full-speed USB device number 3 using xhci_hcd
[  613.742864] usb 3-1: device descriptor read/64, error -71
[  613.852816] xhci_hcd 0000:06:00.0: WARN urb submitted to disabled ep
[  613.852824] xhci_hcd 0000:06:00.0: WARN urb submitted to disabled ep
[  613.852828] xhci_hcd 0000:06:00.0: WARN urb submitted to disabled ep
[  613.972824] usb 3-1: device descriptor read/64, error -2
[  614.202792] usb 3-1: new full-speed USB device number 4 using xhci_hcd
[  614.322820] usb 3-1: device descriptor read/64, error -71
[  614.432814] xhci_hcd 0000:06:00.0: WARN urb submitted to disabled ep
[  614.432822] xhci_hcd 0000:06:00.0: WARN urb submitted to disabled ep
[  614.432826] xhci_hcd 0000:06:00.0: WARN urb submitted to disabled ep
[  614.552855] usb 3-1: device descriptor read/64, error -2
[  614.782815] usb 3-1: new full-speed USB device number 5 using xhci_hcd
[  614.784184] usb 3-1: Device not responding to setup address.
[  614.994165] usb 3-1: Device not responding to setup address.
[  615.202812] usb 3-1: device not accepting address 5, error -71
[  615.332766] usb 3-1: new full-speed USB device number 6 using xhci_hcd
[  615.334178] usb 3-1: Device not responding to setup address.
[  615.544180] usb 3-1: Device not responding to setup address.
[  615.752811] usb 3-1: device not accepting address 6, error -71
[  615.752852] usb usb3-port1: unable to enumerate USB device

I have tried different ports, rebooted, checked the ports with other devices.

If a short didn't kill it something else did. Maybe unrelated. Maybe just a cheap board. shrug.

Ubuntu, is a Debian clone. It is not pure Debian. Linux Mint is a Ubuntu Clone, it is not pure Ubuntu. When someone comes to the forums and states that they are using an Arduino UNO i have ever reason to believe that they are using an original Arduino UNO and not some Far East clone.

Throughout this I have asked you for a link to the pixel dev board, you have not provided that. I asked for a block diagram you have not provided that. I asked you for a photograph of the Arduino UNO with the voltage regulator circle in Red, you have not provided that.

So do not start about it being "open source" and not a "clone"