Decoding Pulse Telephone


Closed Thread
Results 1 to 13 of 13

Hybrid View

  1. #1
    Join Date
    May 2013
    Location
    australia
    Posts
    2,705


    Did you find this post helpful? Yes | No

    Default Re: Decoding Pulse Telephone

    most dials have a 66/33 mark/space ratio and fixed impulse rate of 10 impulses / second , there is also a fixed minimum interdigital pause between digits built into the dial mechanism . a pause in dialing longer than the 66/33 ratio will always indicate a new digit or the end of dialing

  2. #2
    Join Date
    Nov 2003
    Location
    Greece
    Posts
    4,172


    Did you find this post helpful? Yes | No

    Default Re: Decoding Pulse Telephone

    Thanks for the info. Did not knew there is a 66/33 ratio. Soon the scope will reveal the case.

    Ioannis

  3. #3
    Join Date
    Feb 2003
    Posts
    432


    Did you find this post helpful? Yes | No

    Default Re: Decoding Pulse Telephone

    Its a long time since I did my BT apprenticeship (40 years!) and I no longer have any of my notes but this thread triggered something in my brain about the minimum Inter Digit Pause being 450mS as that is the amout of time that was needed for a strowger switch to detect the end of the dialled digit and sweep the bank looking for a free outlet. If its a rotary dial tone you wont be able to get the minimum below about 1 second as thats how long it takes to turn the dial for the next digit but if its Pulse Dial push button phone then the minimum Inter Digit Pause will be determined by the dialling chip in the phone.
    Keith

    www.diyha.co.uk
    www.kat5.tv

  4. #4
    Join Date
    Nov 2003
    Location
    Greece
    Posts
    4,172


    Did you find this post helpful? Yes | No

    Default Re: Decoding Pulse Telephone

    OK, Thanks Keith.

    The first pulse does not seem to be different than the rest.

    The pause between digits is between 500-750ms according to the phone.

    Each pulse is 1Hz or 600/400msec ratio.

    Ioannis

  5. #5
    Join Date
    Aug 2003
    Posts
    985


    Did you find this post helpful? Yes | No

    Default Re: Decoding Pulse Telephone

    If I recall correctly there’s a switch to tell the dial is in the home position to tell it was the end of a set of pulses,
    or that a set of pulses is about to arrive if you want to look at it that way.

    You can avoid any debounce hardware. All you have to do is pick whether you’re going to count rising or falling edges,
    and look for a decent consecutive samples of the switch in one position, and then the same number of samples indicating
    the switch is in the opposite position to qualify a rising or falling edge of the dial switch.

  6. #6
    Join Date
    Nov 2003
    Location
    Greece
    Posts
    4,172


    Did you find this post helpful? Yes | No

    Default Re: Decoding Pulse Telephone

    Thats interesting. I see two pair of wires coming out of the dial. So one pair is sure the digit pulser, the other might be exactly that, the home position. Maybe they used that to mute the earpiece?

    Sure I can make good use to it.

    Ioannis

  7. #7
    Join Date
    Aug 2003
    Posts
    985


    Did you find this post helpful? Yes | No

    Default Re: Decoding Pulse Telephone

    The other wire might be for the rotary switch normally open and closed positions.
    I found code I did if it helps. This was to time dialling zero (ten) to calibrate a dial.
    The LED should land int he middle, but most dials are a little off.
    It happens to know the number dialled too, though the hardware wasn’t for displaying it.



    Code:
    '
    '
    '***********************************************************************************
    '*                                                                                 *
    '*                          [email protected]                               *
    '*                             Brek Martin 2013-14                                 *
    '***********************************************************************************
    '
    '
    DEFINE OSC 20								' but we are really using 8 MHz
    DEFINE NO_CLRWDT							' watchdog is cleared manually
    LCD_DATAUS CON 50							' LCD timing
    LCD_COMMANDUS CON 2000						'
    '
    'INTCON.4 = 1									'enable portb.0 interrupt
    'OPTION_REG.6 = 0								'interrupt on falling edge of portb.0
    '
    '
    INCLUDE "Elapsed.bas"							'
    '
    '
    '
    ' execution time!
    '
    CMCON = 7	' set portb to digital
    trisb.7 = 0	' set LED outputs
    trisb.6 = 0	'
    trisb.5 = 0	'
    trisb.4 = 0	'
    trisb.3 = 0	'
    trisb.2 = 0	'
    trisb.1 = 0	'
    trisb.0 = 1 ' set rotary dial switch input (pulse)
    trisa.1 = 1 ' set rotary dial switch input (home)
    '
    @ clrwdt			; clear watchdog timer manually
    '
    flashrate var byte
    timea var byte
    index var byte	' declare values for LED test startup
    indexb var byte
    bpattern var byte
    dialcount var byte
    '
    oldlast var byte
    '
    errstart:
    '
    @ clrwdt			; clear watchdog
    bpattern = %00000001
    dialcount = 0
    flashrate = 8
    timea = 64
    '
    FOR indexb = 0 TO 6  ' fancy led test startup
    FOR index = 0 TO 6
    @ rlf _bpattern
    portb = bpattern
    pause flashrate
    NEXT index
    FOR index = 0 TO 6
    @ rrf _bpattern
    portb = bpattern
    pause flashrate
    NEXT index
    flashrate = flashrate - 1
    NEXT indexb
    portb = 0
    '
    @ clrwdt			; clear watchdog timer manually
    '
    extint = 0			'reset external variables
    freq = 0
    ticcnt = 0
    '
    ready var bit		'declare internal variables
    ready = 0
    counting var bit
    counting = 0
    thetime var byte
    thetime = 0
    '
    lasta var byte'		'bit to check for last rising edge
    lasta = 0
    '
    '
    Gosub ResetTime		'Reset Time 00:00:00
    '
    '
    '
    cycle:				' main routine - 3D Cube user program
    @ clrwdt			; clear watchdog timer manually
    '
    '
    IF porta.1 = 1 && counting = 0 THEN
    portb = %11111110 ' dial not home indicator
    ready = 1 ' set ready to count time status
    thetime = 0
    bpattern = 0
    '
    ELSE
    '
    IF counting = 1 THEN
    '
    IF portb.0 = 0 THEN
    portb = %11111110 ' flash LEDs on for break
    pauseus 50
    portb = 0
    ELSE
    portb = 0		' flash LEDs off for make
    ENDIF
    '
    ELSE
    portb = 0
    ENDIF
    ENDIF
    '
    '
    IF ready = 1 THEN ' check ready to count status
    IF portb.0 = 0 THEN ' look for first falling edge
    gosub StartTimer	'start clock timer
    thetime = 0
    dialcount = 0
    timea = 64
    counting = 1
    ready = 0  ' lock routine
    ENDIF
    ENDIF
    '
    '
    IF counting = 1 THEN ' check counting and dial at home position
    '
    IF portb.0 = 1 && lasta > 3 THEN ' look for last rising edge otherwise is overwritten
    thetime = Seconds*100
    thetime = thetime + Ticks
    ENDIF
    '
    oldlast = lasta
    '
    IF portb.0 = 0 THEN		' dial switch debounce in software
    lasta = lasta + 1
    ELSE
    lasta = 0
    ENDIF
    '
    
    
    IF lasta < oldlast THEN ' increment dial pulse counter
    dialcount = dialcount + 1
    ENDIF
    
    
    
    '
    IF porta.1 = 0 THEN
    gosub StopTimer
    counting = 0
    '
    timea = 10
    '
    IF dialcount < 10 THEN	' check that zero was dialed
    goto errstart			' or error condition
    ENDIF
    '
    Gosub ResetTime			'Reset Time 00:00:00
    ENDIF
    ENDIF
    '
    '
    '
    '
    IF thetime > timea && thetime < 75 THEN	' LED time display
    bpattern = %00000010 ' dial too fast
    ENDIF
    IF thetime > 74 && thetime < 85 THEN
    bpattern = %00000100
    ENDIF
    IF thetime > 84 && thetime < 95 THEN
    bpattern = %00001000
    ENDIF
    IF thetime > 94 && thetime < 105 THEN
    bpattern = %00010000 ' ideal time
    ENDIF
    IF thetime > 104 && thetime < 115 THEN
    bpattern = %00100000
    ENDIF
    IF thetime > 114 && thetime < 125 THEN
    bpattern = %01000000
    ENDIF
    IF thetime > 124 THEN
    bpattern = %10000000 ' dial too slow
    ENDIF
    '
    portb = bpattern
    pauseus 500
    portb = 0
    '
    '
    goto cycle		' end main routine - do the next cycle
    '
    '

  8. #8
    Join Date
    Sep 2010
    Location
    Las Vegas, NV
    Posts
    305


    Did you find this post helpful? Yes | No

    Default Re: Decoding Pulse Telephone

    Though I doubt it, European phones may be different than in the USA but here in the USA only two wires, a pair, are needed for a phone to work.

    The other pair at one time was used for enhancements and power. Those old phones often had several incandescent light bulbs that wouldn't allow the main line to function because the current draw was excessive. Typically nowadays those wires are used for a second line inside the house.

    I think the home position you articulate is really time. If the handset is on the phone long enough the circuit resets and waits for the pulses or the tones. When I was younger you were cool if you didn't use the dial to call someone. You had to be talented enough to bang on the phone cradle the correct number of times to dial a phone. Ah the good old days.

    I'm pretty sure all the pulses are the same time on/pause ratio. You just need to count the number of pulses and not wait too long to dial.

  9. #9
    Join Date
    Feb 2003
    Posts
    432


    Did you find this post helpful? Yes | No

    Default Re: Decoding Pulse Telephone

    Quote Originally Posted by Ioannis View Post
    Thats interesting. I see two pair of wires coming out of the dial. So one pair is sure the digit pulser, the other might be exactly that, the home position. Maybe they used that to mute the earpiece?

    Sure I can make good use to it.

    Ioannis
    The dials in British phones had 5 contacts. 2 of them were the pulsing contacts which were normally closed and pulsed open for the dial pulses. The other three contacts were normally open and are referred to as the "Dial Off Normal" contacts. They placed a short across the earpiece to prevent acoustic shock and also a short across the carbon granule microphone to prevent the back EMF surges from welding the granules together.

    http://www.britishtelephones.com/howdial.htm

    Keith
    Keith

    www.diyha.co.uk
    www.kat5.tv

Similar Threads

  1. Telephone interface questions
    By Skarr11 in forum Schematics
    Replies: 18
    Last Post: - 5th December 2010, 00:08
  2. Melabs Labx??? Evaluationboard for telephone applications
    By Pedro Pinto in forum mel PIC BASIC Pro
    Replies: 2
    Last Post: - 18th October 2010, 21:40
  3. Lab-XT telephone connection question
    By percychen in forum Schematics
    Replies: 1
    Last Post: - 7th February 2010, 00:18
  4. Pulse Decoding
    By Freman in forum General
    Replies: 12
    Last Post: - 2nd June 2008, 22:31
  5. DTMF decoding
    By maria in forum mel PIC BASIC Pro
    Replies: 3
    Last Post: - 12th May 2004, 16:11

Members who have read this thread : 0

You do not have permission to view the list of names.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts