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.

Using a Drop in Current as a Trigger

Status
Not open for further replies.

TrinitronX

New Member
I've been working on a USB Voltage Delay circuit to delay the enumeration of a certain device on power on and reboot. I use a 555 timer set up to do a single constant pulse after about 11 seconds, this pulse then triggers a PNP transistor to drive the device load.

So far it works fine from a cold boot up state... however, during reboot, the USB bus stays at constant 5V. There must be some data sent over the data lines that tells the device to shut off or reset for a short time though, so the current through the device goes to 0. I need to detect when this happens so I can re-trigger the timer again (set pin 2 to 0), to turn it off and start the voltage delay sequence again.

I've been looking for some sort of current detector I can put in series with the load that won't cause a significant voltage drop. I was going to try to put a LED in series with it and try to use a separate photodiode to detect whether that one was on or off.. but this caused the load to have insufficient voltage.

I was looking at Hall Effect sensors, but it seems most of these are for large currents.. the current through the load under normal conditions stays between 105-112 mA.

I'll attach a schematic and a graph of the current over time during a reboot cycle.
 

Attachments

  • Load Current during rebooot.png
    Load Current during rebooot.png
    40.7 KB · Views: 130
  • Voltage_Delay.png
    Voltage_Delay.png
    43.5 KB · Views: 133
For the current to drop to zero the device itself must power down. Is there an LED or such that you can detect going off.

With a hall effect sensor, if you loop the wire a number of times through a small ferrite ring this will amplify the magnetic field. If you then cut a slot in the ring and place your hall effect device in the slot it may work.

Mike.
 
Why not just put a resistor in series with a capacitor across the power lead (Vcc). Use a comparator to compare the voltage across the capacitor and the value of Vcc. When Vcc varies there will be a period of time, before the cap discharges to the new value, in which the comparator can notify of the change.
 
I do notice a very slight change in voltage during the reboot cycle.. it goes from about 5 to 5.06 volts when the device powers itself down. Will a comparator be sensitive to such a change?
 
Put a resistor in series (with device).
You can use 1ohm resistor - when the device run, the voltage drop is 100mV, this quite enough for comparator.
 
First of all, thanks for the suggestions. I've been struggling to get a voltage comparator working in some way or another, but am having troubles with getting it to change output.

I'm using an LM311N, which I tested using various reference voltages in the (+) terminal, and 5.03V at the (-) terminal. I had a voltage divider set up with a trimpot to see where the comparator was actually triggering, and the moment it did, I had 3.9V at the (+), and still 5.03V at (-).
This is definitely not sensitive enough for what I need. In PSpice, the LM311 model triggers at pretty much exactly the level I needed. What's going on here? Is the 311N supposed to behave this way... I thought it was the same as the normal LM311.

Should I just go out and find a better comparator?
 
TrinitronX said:
First of all, thanks for the suggestions. I've been struggling to get a voltage comparator working in some way or another, but am having troubles with getting it to change output.

I'm using an LM311N, which I tested using various reference voltages in the (+) terminal, and 5.03V at the (-) terminal. I had a voltage divider set up with a trimpot to see where the comparator was actually triggering, and the moment it did, I had 3.9V at the (+), and still 5.03V at (-).
This is definitely not sensitive enough for what I need. In PSpice, the LM311 model triggers at pretty much exactly the level I needed. What's going on here? Is the 311N supposed to behave this way... I thought it was the same as the normal LM311.

Should I just go out and find a better comparator?
hi,
Can you post a circuit of the LM311 configuration and how it is connected.?
 
The OpAmp can only "see" what is within its supply voltage range. Pulling the inverting input to VCC there is not much to do for the OpAmp.

Use a reference voltage 1/2 VCC at the inverting input. If the non-inverting input voltage exceeds VRef at the inverting input the output will swing high, otherwise stay low.
 
Status
Not open for further replies.

Latest threads

New Articles From Microcontroller Tips

Back
Top