MrHeckles Posted March 20, 2006 Report Posted March 20, 2006 Hi guys.I have a circuit that uses a 4PDT switch to flick 4 seperate parts from one circuit to another (if that makes sense).Is there a way to use a SPDT switch in conjuction with some electronic switches to do the same thing?I thought I could use the MAX333CPP quad SPDT analogue switch, but have had no luck with it.Any ideas.ThanksMrHeckles Quote
Staigen Posted March 20, 2006 Report Posted March 20, 2006 Hi MrHecklesHow much current? Voltage?A little schematic would be nice!//Staigen Quote
Shahriar Posted March 20, 2006 Report Posted March 20, 2006 Maybe using CD4066 or CD4016 solve your problem. of course depending on Your current and Voltage as Staigen said.HTH - Shahriar Quote
MrHeckles Posted March 21, 2006 Author Report Posted March 21, 2006 Sorry guys, okay here we go. This should make things clearer.The "forward and reverse limit" connections go straight to the + input of a LM4558 dual op amp. The "limit in" connection will be around 0.1v and no more than 1mA.The "forward and reverse value" connections should have no more than 1mA, and as you can see is +5v in.The "forward and reverse signal" connections would have a max of +12v and 12mA. The PWM signal in again has a max of +12v.What I find is that the switch does not seem to change the state of the SPDT sections. I have yet to exam is closely to figure out if they are staying in the correct state (in terms of "normally closed") Quote
Staigen Posted March 21, 2006 Report Posted March 21, 2006 Hi MrHecklesTry this first! As you see, i have added a resistor, that will draw the switcingaction inputs to ground, when the SW1 is open.//Staigen Quote
MrHeckles Posted March 22, 2006 Author Report Posted March 22, 2006 It doesnt mention anything in the datasheet, but is the MAX333CPP capable of putting signals both ways through the switches like the CD4066? Quote
Staigen Posted March 22, 2006 Report Posted March 22, 2006 HiI suppose so, dont it do that for you? If so, the IC is surely damaged!//Staigen Quote
MrHeckles Posted March 22, 2006 Author Report Posted March 22, 2006 Yes, it does work now (with the 10k resistor), with only one small problem.The number 1 SPDT and the number 4 SPDT in the chip are connected to latching comparators that stay on once a mode is selected (by the switch), and indicate through an LED. To turn the comparator off when the mode is switched (and turn on the other one), they are grounded through the MAX333CPP. Problem is that (I assume due to the internal resistance of the chip) even when PIN 3 is connected to PIN 2 (ie grounding it), there is about 0.12v on PIN 3 which keeps the indicator LED on, regardless of the actual mode selected.Is there anyway to overcome this so that when in the appropriate mode (via the switch) that PIN 3 and PIN 18 ground properly through their respective connection? Quote
Staigen Posted March 22, 2006 Report Posted March 22, 2006 HiI didn't get that!Are "limit" an input or outpt to the machine?Are "forward limit" an input or output to the macine?Are "reverse limit" an input or output to the macine?Maybee they should be ored or anded together?//Staigen Quote
MrHeckles Posted March 22, 2006 Author Report Posted March 22, 2006 Its a bit hard to describe, so heres the setupAs you can see, when the switch is open, and as long as there isnt to much voltage on the load signal feed, the forward comparator will latch on, turning on LED2.When the switch is closed, it SHOULD ground the forward comparator (thus turning it off) and turn on the reverse comparator (assuming that again, there is not too much load signal) and latch on, thus turning on LED1 (and turning off LED2).However, the MAX333CPP doesnt seem to ground PIN 3 or 18 very well, and the comparators do not turn off, and so the LED's stay on.Is there some way to get a good grounding through the chip for those forward and reverse limit feeds to the comparators? Quote
Staigen Posted March 22, 2006 Report Posted March 22, 2006 Hi MrHecklesI think i find one error, the pin number 5 of max333 shall be connected to anegative voltage, i Quote
Staigen Posted March 22, 2006 Report Posted March 22, 2006 Hi again MrHecklesI belive i found one more error, the bases of your LED driving transistors isnot protected, a reversed diode(1N4148 or similar) will help that!//Staigen Quote
MrHeckles Posted March 23, 2006 Author Report Posted March 23, 2006 I have hooked the negative 9 volt rail to the MAX333CPP.The voltage on PIN 3 when it is supposidly grounding is now 0.08v. Lower, but not low enough to turn off the comparator.What is this other solution of yours? Quote
Staigen Posted March 23, 2006 Report Posted March 23, 2006 HiThe other method is called BFS and stands for Brute Force Solution, inother words, use a relay! At least for the malfunktion switches. A DPDTrelay, together with the MAX333, or a 4PDT relay without the MAX333!Sorry Quote
Staigen Posted March 23, 2006 Report Posted March 23, 2006 Hi againMaybee there is an another solution after all, i didn't thought of it at first!The smitt-trigger- action resistors, do they need to be that big? Is it possibleto rise them to, lets say, 100K or so? Than the current throu the switches arereduced, and also the voltage. Also an another possibillity come to my mind,that we take later.//Staigen Quote
MrHeckles Posted March 23, 2006 Author Report Posted March 23, 2006 I'll keep it in mind :)But I had another idea.I changed PIN's 2 and 17 to connect to -5v, rather than ground. That way I figured it would drag the comparators + inputs to a negative voltage (and turn them off).However, it didnt seem to work. When I changed the switch, the LED's would flick off, then come straight back on. On checking the outputs of the comparators, I found that when the switch was changed, they would drop voltage for a moment, then go back up again, in effect turning off for a split second, then back on again. Why would this be happening if there was a negative voltage on the + input to a comparator and 0v or very slightly positive on the - input? Quote
Staigen Posted March 23, 2006 Report Posted March 23, 2006 HiHow did you make your -5Volt?//Staigen Quote
windoze killa Posted March 23, 2006 Report Posted March 23, 2006 I have hooked the negative 9 volt rail to the MAX333CPP.The voltage on PIN 3 when it is supposidly grounding is now 0.08v. Lower, but not low enough to turn off the comparator.What is this other solution of yours?Try putting a voltage divider with a pot on the other input to the comparator. Adjust the pot to cancel the small voltage you are seeing on the other input. You could even go a little further so you need a high voltage to switch the comparator. Quote
MrHeckles Posted March 23, 2006 Author Report Posted March 23, 2006 Got it sorted now. I had changed the comparator to the -5v rail, and I figure that the -5v through the max333cpp was too close to V-.I changed it back to -9v for the comparator and it works fine. I also put in the reverse diodes to protect the transistors bases.Staigen - the -5v comes from a regulator elsewhere in the circuit (part that wasnt important to the original question, so I didnt bother showing the whole thing).Works a treat now - thanks guys. Quote
Staigen Posted March 24, 2006 Report Posted March 24, 2006 Hi Mr HecklesGood to hear that it works! Have a nice weekend, and good luck with your project! ;D//Staigen Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.