On several occasions I have seen requests on different forums for a simple way to detect whether mains voltage is present in a system. There are always the suggestions of resistors and caps and diodes and optocouplers in all sorts of configurations.
The simplest way- a relay with a coil rated to the mains voltage. Of course there must be some consideration paid to the wetting current through the contacts, but still...
I actually think you could make a D-type latch with a clear input using just two relays (but I'll have to think about thsi some more).
Althoug not a D-Type we used to make a latching relay as follows: Let's presume a 24VDC coil and I'll polarize it, just to simplify the explanation. You will also need a 2 pole relay normally open, or changeover contacts- pole one is for general use. Connect the coil positive to 24Vdc and the negative end is what's used to activate the relay when connected to 0V. Connect C2 (common of pole 2) to 0V and NO2 (not laughing gas) to the negative of the coil. When the coil is activated, the closed contact connects 0V to the coil so that even if the external activation is removed the relay remains energised.
The only way to de-activate the relay is to somehow open circuit the power loop to the coil.
I am quite familiar with relay ladder diagrams. My first job with an industrial robot and automation manufacturer used PLCs for control, but also used a lot of relays. I remember discussing this with my boss. I thought it would make more sense to use TTL for a lot of things like safety interlocks. He correctly pointed out that that would require power supplies, and special mounting cabinets. It was always cheaper to use relays (at least in the 70s). Then there was the problem of fault modes. The relays tend to fail in know specific ways. With relays that have been tested/approved for safety interlock applications you can have some assurance that they will work in a safety application.
Another interesting thing about relay logic is that the combinatorial reduction for it is quite different (as others have noted) because unlike TTL or other logic families, there is no input & output. Current can flow in both directions. If you look at old relay designs that used complex circuits with hundreds of relays, they used the formal mathematical reduction techniques to eliminate large expensive relays. The resulting schematic seems impossible to figure out. It is not the simple contacts in series are AND, and in parallel are OR circuits. Kind of like code without comments.
I have an ancient Friden Flexowriter teletype with paper tape reader/punch that it took me weeks to repair when a contact got bent. It has complicated logic to do parity checking and all kinds of other control stuff. Even with schematics, it was very difficult to figure out the 90VDC relay logic.
Then there was the Friden Computyper that the teletype was connected to. It was a completely mechanical computer. It used many hundreds of relays as well as stepping relays, and a mechanical adding machine (the ALU) that used solenoids to press the buttons, and had means of reading out the output digits electrically. This particular machine was used in the 50s & 60s to calculate payroll and print paychecks for the USAF.
@SteveD_Aus :...wonder what was the fate of all those relays?
Sad to sad, I bet the yended up as scrap -- I know I'm finding it exceedingly difficult to find more copies of the Kurman 223C34 shown in my blog above. I really want to lay my hands on a couple of hundred at least.
I know I could opt for modern versions ... but that wouldn't be quite the same (sad face)
Those exchanges are what i thought of when I read the article. I got to look into one once on a stint with Telstra during summer holidays and listening to the racks of relays handling calls (decadic dialling, terminations) was like a strange kind of music. I imagine they've all been replace with digital technology now - wonder what was the fate of all those relays?
In the Telco of the 1960's era,dialtone was 53 volts.When dial tone was broekn by picking up the receiver and dialing,you had talking battery,which was 48 volts.When the phone rang, it was 96 volts pulsating DC.The ringer had a capacitor in seres that blocked the pure DC.
The Central Office had thousands of stepping relays,that stepped one step for every number dialed on the rotary phone.After a standard delay, it moved the to the next relay.This repeated through the whole number sequence.
Most service was party line service of 10 people or more sharing the same line,especially in the rural areas.
About 1970, the FCC mandated a maximum of 4 parties on one line,so a lot of infrstructure had to be upgraded.Open wire was replaced with buried wire,and eventually,2party lines became available,and now private lines are the standard.
Fiber optic has replace most copper now,and the "central office" is now mounted on a single circuit board in the field.
Cards called DSLAM (Digital Subscriber Line Analog Multiplexer) cards convert the analog voice into digital and pump it down a fiber cable.
Any logic that can be performed with gates can be performed with relays, and was done that way first.
Series circuits are AND circuit,Parallel circuits are OR circuit,and holding(interlocking) contacts are memory bits.
For NAND and NOR simply use the opposite contact.
You can make anything with these.
However, I prefer modern solid state logic.
It is so much eaiser to reprogram than to move wires around physically,as in PLCs.
Much easier to modify any part of the circuit or time delay or addressing.
Addresses had to be hard wired with wire-wrap terminals.What a pain.Especially if you had to change them.
Anyway, enough nostalgia for now.It is time for my toddy and nap.
What are the engineering and design challenges in creating successful IoT devices? These devices are usually small, resource-constrained electronics designed to sense, collect, send, and/or interpret data. Some of the devices need to be smart enough to act upon data in real time, 24/7. Specifically the guests will discuss sensors, security, and lessons from IoT deployments.