Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

Earthing my ground USB not working unless circuit is earthed

Status
Not open for further replies.
Hi
I think I need to earth my gnd. My USB interface doesn't work unless my gnd rail on my breadboard is connected to the earth clip on my scope. I'm sure of this because the minute I unplug the earth wire, my device disconnects itself. I get a message in the logs saying it's diconnected. It reconnects as soon as I plug it back in again.

So how do I create an earth? Or is that what the pin connected to the casing of the usb socket is for?
 
Last edited:
You don't need to earth the USB ground. It sounds like you have a break in the 0v going to you breadboard and the ground of the scope is completing it for you.
 
You are missing one of the connections that is supposed to be in the USB cable/connectors.
 
I'm sorry if I wasn't clear. My circuit generally works eg my avr is working because I can flash it and the crystal oscillates at 16 MHZ. It's only the usb that doesn't work when it's not grounded by the ground clip.
Am I correct in assuming I only need D+ and D- for a working usb connection. At the moment it's self powered with a 9V battery to a 5V regulator.
 
Last edited:
I'm sorry if I wasn't clear. My circuit generally works eg my avr is working because I can flash it and the crystal oscillates at 16 MHZ. It's only the usb that doesn't work when it's not grounded by the ground clip.
Am I correct in assuming I only need D+ and D- for a working usb connection. At the moment it's self powered with a 9V battery to a 5V regulator.

hi,
You MUST have the PC's 0V line also connected in addition to the +/-D lines.
 
OH!! I didn't know that!!! Trouble is the schematics I were refering to were powered by USB hence I assumed it was only for power. As you probably know, am an amateur. An amateur and 500 pound pc dont mix hence I was reluctant to source power from usb! Ericgibbs, are you saying I need to wire my zener didodes to the gnd pin of the usb port?

Here's the schematic I was following https://vusb.wdfiles.com/local--files/hardware/level-conversion-with-zener.gif.

So by not connecting to the gnd pin, I've effectively put a break in the circuit right? If so browney points to moffy and Mike.
 
OH!! I didn't know that!!! Trouble is the schematics I were refering to were powered by USB hence I assumed it was only for power. As you probably know, am an amateur. An amateur and 500 pound pc dont mix hence I was reluctant to source power from usb! Ericgibbs, are you saying I need to wire my zener didodes to the gnd pin of the usb port?

Here's the schematic I was following https://vusb.wdfiles.com/local--files/hardware/level-conversion-with-zener.gif.

So by not connecting to the gnd pin, I've effectively put a break in the circuit right? If so browney points to moffy and Mike.

hi,
The 0V should be common to ALL the circuit components.

On the normal USB cable you have +5v, 0V and +/-D

Whats the function of the Zener diodes.???
 
Really but it isn't powered by usb. It's powered by a 9V battery connected to 5V regulator.

Instead of reducing the AVR's power supply, we can limit the output voltage on D+ and D- with Zener diodes. We recommend 3.6 V low power types, those that look like 1N4148 (usually 500 mW or less). Low power types are required because they have less capacitance and thus cause less distortion on the data lines. And 3.6 V is better than 3.3 V because 3.3 V diodes yield only ca. 2.7 V in conjunction with an 1.5 kΩ (or more exactly 10 kΩ) pull-up resistor. With 3.3 V diodes, the device may not be detected reliably.
 
Last edited:
Really but it isn't powered by usb. It's powered by a 9V battery connected to 5V regulator

OK.
Tell me a little about your project, is it a PIC or MCU thats connected to the PC's USB.??

BTW: when I am testing a new USB project I also power from my bench PSU at 5V, the 0V and +/-D are connected to the PC USB port
 
Last edited:
Well it's an AVR ATTiny 44 that the usb is connected to. I believe it's an MCU if am not mistaken.
Specifically I using v-usb to provide my avr with an usb interface so I can control my LCD using software running on the pc. V-usb is a firmware based usb. It doesn't use an interfacing IC.
 
Well it's an AVR ATTiny 44 that the usb is connected to. I believe it's an MCU if am not mistaken.
Specifically I using v-usb to provide my avr with an usb interface so I can control my LCD using software running on the pc. V-usb is a firmware based usb. It doesn't use an interfacing IC.

hi,
So I am assuming that the project +Vs suppy to the v usb is 3.3V.
 
You need ground (ov) for the logic signals as well as for power.
 
Yeah I know now!! Thanks alot guys. My circuit now works. All I have to do is read the API docs so I know how to send/receive the data.

Yeah I mean't to say they recommend 3.6V.
 
Status
Not open for further replies.

Latest threads

New Articles From Microcontroller Tips

Back
Top