kunaakos / RotaryDialMM

Arduino library to receive numbers dialed by a rotary telephone dial via pulse dialing

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Rotary Dial MM

Arduino library to read numbers from a rotary dial (or otherwise using pulse dialing; see Wikipedia: Rotary dial).

front of a rotary telephone dial

This is based on the Rotary-Dial library, modified for the rotary dial used in Hungarian "Mechanikai Művek" phones (and possibly other Eastern European dials). It's not a drop-in replacement for the original version.

Connection & Circuit

On the back of the dial are two connections relevant for this implementation. One (the 'ready' switch) is normally open (NO). The other (the 'pulse' switch) is normally closed (NC), and is opened briefly for each pulse (roughly 10 - 20 Hz).

The expected circuit is:

 ready switch (NO) connected to Arduino readyPin
 pulse switch (NC) connected to Arduino pulsePin
 GND

The expected sequence is:

readyPin  pulsePin  state
HIGH      LOW       default (waiting)
LOW       LOW       ready to dial / for first pulse
HIGH      HIGH      pulse received (number = 1)
LOW       LOW       ready for next pulse
HIGH      HIGH      pulse received (number = 2)
LOW       ...       (repeat)
HIGH      LOW       rotation complete, count recorded

There is 15ms allowed for debounce, which is the implementation's only constraint on pulse speed.

About

Arduino library to receive numbers dialed by a rotary telephone dial via pulse dialing


Languages

Language:C++ 91.9%Language:Processing 8.1%