Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

An on/off digital toggle signal chip

Status
Not open for further replies.

roineust

Member level 3
Joined
Jul 2, 2013
Messages
58
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,286
Activity points
1,902
Hello!

I am looking for a chip that will enable me to input 3-12 V DC on 2 pins (+ and ground input), to get as output on 2 other pins, the exact voltage i put in those previous 2 input pins (+ and ground output) and to have a 5th pin, that if i put in a 3-12 V DC signal - Will turn on and off the electricity that goes between the previous 4 pins (+ and ground input and output).

I understand that maybe such a chip can be found on Motorola chip series MC140xx or 74HCxx or on the LMxxx (which is not Motorola, but another manufacturer, that starts with the letter N - i forgot its name).

Anyway - i need the chip to be as less expensive as possible.

Can anyone help me?

Thanks,
Roi.
 

Re: Looking for an on/off digital toggle signal chip

It's called a relay.
 
Re: Looking for an on/off digital toggle signal chip

...or maybe a CMOS transmission switch but the current you can draw will be very small.

If you explain the application we may have better ideas...

You are thinking of 'N' being National Semiconductors but the MC14, 74HC and especially LM prefix is used by many hundreds of different devices.

Brian.
 
Re: Looking for an on/off digital toggle signal chip

...or maybe a CMOS transmission switch but the current you can draw will be very small.

If you explain the application we may have better ideas...

You are thinking of 'N' being National Semiconductors but the MC14, 74HC and especially LM prefix is used by many hundreds of different devices.

Brian.

I am trying to build a circuit to protect my 1000-2000 mAh 2-3S LiPos, from over discharging. I am using also an Arduino uno and Low voltage LiPo alarm buzzers - and at the end point i have several small servos. I think that the problems with all these chips, is that although on the logic and analog side, they do exactly what i need, but they will not be able to stand such a current as the LiPos let out. So i started searching for relays - but relays that have DC voltage of around 3-20V, not only for logic, but also 3-20 V DC for load - are kind of rare and expensive. I found mostly relays that are manufactured by opto22 - but too pricy.

Do you have any idea for a solution?

Thanks.
 

Re: Looking for an on/off digital toggle signal chip

I *think* I understand your needs but a block diagram of your system might help. I assume the load on the LiPos is the servos themselves so are you asking for a device that cuts all the power when the LiPo voltage drops below a defined level. If that is the case, is it possible for your Arduino to measure the voltage and stop controlling the servos if the measurement is too low, or alternatively, is there a reset line that can be operated to shut everything down when the voltage drops?

Brian.
 
Re: Looking for an on/off digital toggle signal chip

Hey Brian!
Thanks for your reply!
I will try to make a block diagram of the system, in the meantime, i have several questions:


I would have used the Arduino sleep library - but the problem/advantage is that i have separated the servos power line from the Arduino - the servos get the voltage directly form another LiPo via a small regulator - for the sake of a better power distribution and also not to damage ultra-sound sensors reading that i have on the Arduino - it seems that when the sensors and the servos are connected both to the Arduino 5V output, every time the servos start working the sensors go buzzerk. As well, it seems to me in general that the Arduino can not let out enough current for the servos.

Basically what i did and maybe it was an error - is that i have purchased this relay:

**broken link removed**

Now, regarding this above relay i have a question:

I have this regulator:

**broken link removed**


If i have on one side of this regulator (input voltage) the Arduino Uno 5V 40mAh digital pin (PWM) output - Can i get on the output voltage side of this regulator, the 18V 9mAh input voltage logic signal needed for the above relay?

And i have another question:

I was discouraged to use a chip of the following characters:

https://pdf1.alldatasheet.com/datasheet-pdf/view/26882/TI/CD4066.html

That basically, it seems to me, on the logic and analog side, can act just like the relay i mentioned above - But on the data sheet there is this detail:

"DC input current, IIN (any one input) . . . . . . . . . . . . . . ±10 mA"

So, although for a newbie inexperienced electronics hobbyist like me, the common knowledge is that current is something that is drawn by the end device and not "pushed" forward like voltage - i was still concerned that if i put through the analog legs of this chip, the LiPo 2-3S 2000 mAh current, while it specifically says that the DC input current is 10 mAh - then i might damage the chip. Or is it, as mentioned above by you, i will not damage the chip - it is just that the chip will not be able to give out on the other side a big enough needed current?

Was that concern justified - or have i just made an error, while moving from the relatively inexpensive chips playground to the more pricy relays playground?

Thanks a lot,
I hope i make any sense with my questions.

Roi.
 
Last edited:

Re: Looking for an on/off digital toggle signal chip

Your question makes sense but I don't think your relay is going to work.

If I follow your connections, your Arduino produces a PWM output with maximum 40mA load, you want to step this up to 24V using the regulator board and use that to drive the relay. The reason I'm doubtful it will work is that you assume the Arduino will produce 5V *AT* 40mA load, it's more likely it will produce significantly less at maximum load current. You would have to set the PWM to 100% anyway to ensure a stable output. Even if the voltage did hold up, the maximum load power would be 5*0.04 = 200mW. The relay requires 24V at 9mA = 216mW so even if the regulator was 100% efficient it would still not provide enough output. In practice, you would expect around 75% efficiency from that kind of regulator when stepping up that much. So I won't say it will not work but I will say you are pushing your luck!

The CD4066 is an analog switch and it will not work properly in your application. The reason is that when 'on' the switch will have a DC resistance of around 250 Ohms. These are really intended a signal switches where the load after the switch is quite a high resistance compared to the switch itself, typically they are ('were' - they are old devices!) used as input selector switches in audio amplifiers. The specification limiting their input current to 10mA is because they drop so much voltage in their internal resistance that they would overheat if you tried to pass more.

What you need to explain is 'how do you know when the cells are over discharged?', you need some kind of voltage or charge monitoring system and it would be better to concentrate on that rather than the switch itself. For example, if you need to disconnect the load at a certain cell voltage, you can do it with a single transistor, zener diode, two resistors and a relay.

Brian.
 
Re: Looking for an on/off digital toggle signal chip

For LiPo discharge detection per cell, i am planning on using these LiPo alarm buzzers - while soldering a wire to the buzzer or led output ground and + and connecting it on the other side to the arduino analog input:

**broken link removed**
 

Re: Looking for an on/off digital toggle signal chip

That should work but there is probably an easier way to do all this. The problems you may face are that wiring to an LED or the buzzer may not give you a 'good/bad' indication by simply measuring voltage, it depends upon how they are wired on the board. In any case, the difference between an LED being on and off may only be a small voltage change which you have to measure and compare with a threshold in your program. I think as simpler system would be a single transistor and relay circuit. The transistor drives the relay which in turn disconnects your cells. The transistor would be biased by current through a Zener diode with a knee voltage (Vz) about 0.6V less than the lowest cell voltage you can tolerate. When the voltage is above (Vz+ 0.6) the transistor turns the relay on, as it drops lower than that, it turns the relay off. It's only 5 components and much cheaper! The drawback to this simple method is that if you power the relay from the cells, as it turns off, the load on them reduces, their voltage goes up slightly and the relay might kick in again. You would probably have the same problem with the HobbyKing product as well. There are several ways around this, all relatively simple but does this approach sound reasonable to you before I explain more.

Brian.
 
Re: Looking for an on/off digital toggle signal chip

I don't understand well enough the terms and the names of the components that you mention. I will google them.

Could you send me a diagram? It might be easier for me to understand.

Here is the reason i went for these LiPo over-discharge buzzers and was discouraged from trying to measure the LiPos per cell, by building my own circuit, there is this guy who finds it very easy to check out 1 cell, using his Arduino and then, when trying to expand his idea to all the cells on his LiPo, things start getting kinda messy:
 

Re: Looking for an on/off digital toggle signal chip

OK, images attached. Sorry for the quality, they are snapshots of scribbles from my mobile phone!



Measuring Cells in series is never easy as the article mentions. Across one cell is just a voltage measurement but as soon as you introduce more cells it becomes difficult to distinguish one cell's voltage from another and of course the total voltage may be too high to measure anyway. There are several solutions, the easiest to visualize is simply moving the measurement connections from one cell to the next but when the bottom cell is also the ground of the measuring system it gets tricky and it's very easy to either short it out or damage the measurement device. The safe solution is as I show in the diagram with three cells in series. The bottom is the most negative point so you use hat as the zero reference and measurment ground. It's then simple to measure the voltage at the top of the bottom cell. To measure the next one is a bit harder because at it's top is the sum of the bottom two cells and also the voltage is above normal measurement range (0 to 5V). The solution is to reduce the voltage using two resistors (a potential divider) so it is within measurable range. Obviously, dropping it means you are no longer reading the true voltage but a fraction of it decided by the resistor values R1 and R2. This is where maths come to the rescue! You have already measured the bottom cell voltage and you can work out the voltage at the top of the middle cells by multiplying the measurement by the inverse of the ratio of the two resistors, if you subtract them you get the middle cell's voltage. The same principle is used to measure the top cell. Work out the real voltage by multiplying by the inverse of the ratio of R3 and R4 then subtract the voltage of the other two cells and all thats left is the top cell voltage. Doing it this way needs three analog inputs but it does check each cell individually without having to break the connection between them.



The second schematic shows the cut-off circuit. The relay operates as long as the voltage applied to the circuit is high enough (Zener voltage 'Vz' plus the transistors Base to emitter voltage 'Vbe'). A Zener diode does not conduct in it's reverse bias polarity (as in the diagram) until the voltage across it reaches a certain amount. The transistor also needs 0.6V on it's base with respect to it's emitter pin before it starts to conduct. The idea is that if the voltage is high enough, current flows through the Zener diode, into the base which makes the transistor conduct and the relay turns on. If the voltage drops below Vz + Vbe, the current no longer flows and the relay turns off. You choose the cut off voltage by picking a suitable Zener type. For example, if you wanted to operate the relay at 8.8V you would use an 8.2V Zener diode.

Brian.
 
Re: Looking for an on/off digital toggle signal chip

Brian,
Thanks for the elaborate explanation and diagrams.

I will need some time to understand these circuits that you describe - it is probably quite basic for you, but it is more than one level above my knowledge and experience....i have started soldering and using breadboards for the first time in my life, just a couple of months ago.

In the meantime, i have a question, regarding the second and less professional possibility, of using the buzzers and the Arduino:

Can i gain any advantage, in relation to making sure that the relay i mentioned will work, if i connect more than one of them 40mAh Arduino PWM signals at once, to the regulator, which has on its other side the relay? Say, 2 3 or even 4 digital 5V pins, at 100% pulse, all at once?

Roi.
 

Re: Looking for an on/off digital toggle signal chip

In theory, yes you can parallel output to get more drive capability but, and I stress I have no experience with Arduino boards, if the PWM signals are not 100% (in other words constantly on) and there is any phase difference in the PWM signals, they will simply feed one into another and something will get hot!

May I ask why you want to use PWM in the first place? Normally PWM is used when synchronized switches have to be operated or if filtered, when a variable analog voltage has to be generated. It isn't usually used when all you need is a constant full voltage output.

If you are planning to switch the PWM from 100% to 0% in order to operate the relay, why not just use a digital output to do it and drive a relay directly from the power supply?

Brian.
 


Re: Looking for an on/off digital toggle signal chip

I'll try to explain. The PWM outputs only have two voltage levels on them, 0V or 5V but the signal constantly changes from one to the other. The speed at which they change stays the same but the ratio of high (5V) time to low (0V) time is variable and set by the 'analogWrite' function. When you send a high value to the function, the amount of time within the cycle that the pin is high is long and conversely the time when it is low is short. Similarly, when you write a low value to the function, the pin spends longer in a low state and shorter in the high state. The combined high and low times stays the same, it only the proportion of times that changes, hence the term "Pulse Width" in PWM. I'm not sure how fast the each PWM cycle is on your Arduino but it's probably around 1KHz (1,000 high + low periods per second) and the reason they are called analog outputs is because if you filter the PWM signal so you see it's average, it looks like an analog voltage. At 0% PWM the pins are always low throughout the cycle so the average is also 0 and you get 0V out. At 10% PWM, the output is high for 10% of the cycle and low for 90% so the average voltage is 0.5V. At 50% PWM the output is high for half the time and low for half the time so you get 2.5V out. You can see that by changing the PWM ratio you can make a digital pin produce an analog signal.

This where problems might start. Suppose you have two PWM outputs and you link them together to double their output capacity but the PWM signals on them are not identical, it is quite possible that one is high while the other is low. When that happens, current flows between the pins instead of into your load and you get a hot MCU.

Regardless of the PWM problem, the way you are doing the whole thing is vastly over-complicated and inefficient. You might consider that the power wasted by the regulator board alone is probably more than the Arduino uses. The simplest and most power eficient way is to use the second schematic I drew for you. It needs no software or regulator and it's 'idle' current is very low.

Brian.
 

Re: Looking for an on/off digital toggle signal chip

Now i understood completely.

So if one chooses to go the less efficient method, the least he should check is that the pins that go into the regulator are synchronized by the same internal clock on the Arduino?
 

Re: Looking for an on/off digital toggle signal chip

That's correct. These outputs are really intended to control other equipment rather than provide power to it.

Based on the specifications you have for your regulator module, the Arduino board will struggle to power it anyway. The regulator doesn't just increase the voltage from nowhere, it does it by drawing extra current at it's input and 'converting' it to a higher voltage at it's output. What you are actually doing is using a low power circuit to drive a high power circuit to do a simple job of operating a relay.

If I draw an analogy, it's like you are using a bicycle to tow a bus so a passenger can take a letter to the Post Office. It would be easier to take the letter on the bicycle!

Brian.
 

Re: Looking for an on/off digital toggle signal chip

LOL!
That's a great analogy!
I will try to go over your "bicycle" explanation again and see if i fully understand how to build that more efficient circuit!
 

Re: Looking for an on/off digital toggle signal chip

Hello Brian!
How are you doing?
It was too long that we haven't been corresponding! So, i'v got a couple more of my newbie questions for you:

Here is a link to a chip:

https://pdf1.alldatasheet.com/datasheet-pdf/view/26882/TI/CD4066.html

And here are the questions, regarding this chip or that kind of chip family (bilateral something):

1.Would the above chip work well as a 'relay' for around 3V signal in/out and around 5V for control of that signal?

2.Do i understand correctly from the datasheet, that i can switch up to 4 signals, on one chip of this kind?

3. Is the following chip, the same as the one in the datasheet above?? :

**broken link removed**

4.Do these chips themselves consume energy, after i shut down the signals? If so, how much time would you say, it would take a 1 Amp LiPo cell, that has around 3.0V on it and was cut off the device it is connected to, by the chip itself, to get to, say around 2.8V - only because the chip itself is still connected to it and consuming energy?

5.Do such switching chips exist, that if the signals are switched to disconnected, the chip itself consume no energy at all?

6.Would there be any problem, with the fact that the 2.8-3.8 V signal per cell, that this chip will need to switch, will supply 1 Amp current? After all, the 5V control, that will cut on and off that 1 Amp cell signal, will be only a 40mAh...is that 1 Amp current, more than the chip can handle as a signal? It isn't a problem, right? its a only a question of volts and not of Amps, right?

Thanks,
Roi.
 
Last edited:

Re: Looking for an on/off digital toggle signal chip

Hi Roi.

1. Yes, as long as the supply voltage to the IC is the same or higher than the voltage you are switching. But read below...

2. Yes, it contains four identical bi-lateral switches. Bi-lateral means you can swap the input and output, it works in both directions.

3. Yes, the very same. Although I caution you that Chinese Ebay suppliers have a reputation for shipping fakes or out of specification devices.

4. They do, but the amount is extremely small, only a few uA. The consumption will have negligible effect on battery life.

5. All devices use some current but as stated, it is extremely low whether the switch is on or off. They draw a little more current for the duration of the change of state but it is still less than an LCD wristwatch uses and you know how long they run from a tiny coin cell.

6. Yes, massively! When the switch is off, it has a through resistance of tens of Megohms so for practical purposes it is a complete disconnection. When the switches are on, the have a resistance of around 250 Ohms though so they would try to drop 250V per Amp if they didn't melt first! If I was designing with them, I wouldn't let more than say 1mA pass through them to avoid problems.

Brian.
 

Status
Not open for further replies.

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top