The HT95R5x/6x FSK Decoder Functions

Similar documents
Using the HT95R6x for CID Phones

The HT6P20x2 Encoder IC

ZLS38503 Firmware for Voice Prompting and Messaging Firmware Manual

TSA 6000 System Features Summary

HT9032. Calling Line Identification Receiver. Block Diagram. Features. Applications. General Description

EUROPEAN ETS TELECOMMUNICATION January 1998 STANDARD

Using the HT66F016L and the HT66F50 to Implement Remote Encoding and Decoding

HT66F03T3/68F03T3 MCU with 315MHz/433MHz ASK Transmitter

OpenStax-CNX module: m Caller ID Decoder * Ed Doering

Using the 315M/433MHz ASK Transmitter HT4xR01T3 MCU

- 1 - Rep. ITU-R M.2009 REPORT ITU-R M.2009 DIRECT-DIAL TELEPHONE SYSTEMS FOR THE MARITIME MOBILE SERVICE

HT LCD Controller for I/O MCU

ECT-215 Homework #1 Solution Set Chapter 14 Problems 1-29

Using the Timer/Event Counter in the HT47R20A-1

Introduction to IS-95 CDMA p. 1 What is CDMA p. 1 History of CDMA p. 2 Forms of CDMA p MHz CDMA p MHz CDMA (PCS) p. 6 CDMA Parts p.

This document is designed to be used in conjunction with the CMX869A data sheet.

HT Level Gray Scale LCD Controller for I/O MCU. Technical Document. Features. Applications. General Description. FAQs Application Note

Crystalfontz. RAM Mapping 64 8 LCD Controller for I/O MCU. Built-in LCD display RAM Built-in RC oscillator

RAM Mapping 48 8 LCD Controller for I/O MCU. Built-in LCD display RAM Built-in RC oscillator

RAM Mapping 64 8 LCD Controller for I/O MCU. Built-in LCD display RAM Built-in RC oscillator

Artificial Sine Wave Generation Using SX Communications Controller

This manual refer to the latest version of the program for STORNO CQM6xxx radio, written by StrayCat.

BC68F2130 FSK Application Example

SERIAL INPUT AND SERIAL OUTPUT These ports are used for communications between the main CPU (controller) and the sub CPU.

HT162X HT1620 HT1621 HT1622 HT16220 HT1623 HT1625 HT1626 COM

TAN-008 Designing Caller Identification Delivery Using XR-2211 For U.S.

AB-44 APPLICATION BRIEF. Using the 87C51GB SHARON LOPEZ APPLICATIONS ENGINEER. March Order Number

Perpetual Calendar using the HT1382

Topics Introduction to Microprocessors

Generating DTMF Tones Using Z8 Encore! MCU

RAM Mapping 32 8 LCD Controller for I/O MCU. R/W address auto increment Built-in RC oscillator

Back to. Communication Products Group. Technical Notes. Local/Remote Control, 9300 Series

AN913 APPLICATION NOTE

Wireless Communications

HT162X HT1620 HT1621 HT1622 HT16220 HT1623 HT1625 HT1626 COM

MT8843 CMOS. Calling Number Identification Circuit 2. Preliminary Information. Features. Description. Applications

!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!"

CMX860 Telephone Signalling Transceiver

73M2901CE AT Command User Guide

Introduction. DRAFT DRAFT DRAFT JHU/APL 8/5/02 NanoSat Crosslink Transceiver Software Interface Document

Technical Proposal for COMMON-ISDN-API. Version 2.0. Generic Tone Generator and Detector Support for Voice Applications. Extension.

C Mono Camera Module with UART Interface. User Manual

Single Chip High Performance low Power RF Transceiver (Narrow band solution)

Application Note Security Industry Protocols with the CMX865A

HC08 SCI Operation with Various Input Clocks INTRODUCTION

Microprocessor & Interfacing Lecture Programmable Interval Timer

HT /4 to 1/11 Duty VFD Controller

HT162X HT1620 HT1621 HT1622 HT16220 HT1623 HT1625 HT1626 COM

HT /8 to 1/16 Duty VFD Controller

APPENDIX A PARAMETER DESCRIPTIONS

HT9200A HT9200A-8DIP DTMF GENERATOR HT9200B HT9200B-14SOP DTMF GENERATOR. Remote control & communications

CDS CALLING LINE IDENTIFICATION SERVICE TERMINAL EQUIPMENT REQUIREMENTS PART 1 IDLE STATE, DOWN STREAM SIGNALLING PART 2 LOOP STATE SIGNALLING

DTMF Detection and Generation Virtual Peripheral Modules

DNT900. Low Cost 900 MHz FHSS Transceiver Module with I/O

CAT-700 Repeater Controller

CMX868 Low Power V.22 bis Modem

CMX867 Low Power V.22 Modem

FM HANDHELD TRANCEIVER. Connect Systems Incorporated 1802 Eastman Ave., Suite 116 Ventura CA Version 1.00

Complete information on monitor and control software is contained in the following sections.

Computer Networks. Week 03 Founda(on Communica(on Concepts. College of Information Science and Engineering Ritsumeikan University

AAA. Figure 1: Test setup for output power measurement

Engineering Order Wire Implementation

SAT SCD/ARGOS INSTRUCTION MANUAL

RAM Mapping 48 8 LCD Controller for I/O C

CAT-700B Repeater Controller Computer Automation Technology, Inc

Input/Output Control Using Interrupt Service Routines to Establish a Time base

CMT2300A Configuration Guideline

Catalog

CS/ECE/EEE/INSTR F241 MICROPROCESSOR PROGRAMMING & INTERFACING MODULE 8: I/O INTERFACING QUESTIONS ANUPAMA KR BITS, PILANI KK BIRLA GOA CAMPUS

HT162X HT1620 HT1621 HT1622 HT16220 HT1623 HT1625 HT1626 COM

B & D Enterprises 1P repeater controller pg 1 INTRODUCTION:

8XC51FA FB FC PCA Cookbook

RF ISM Transparent Transceiver Module V4.0

Draft ETSI EN V1.3.1 ( )

CTCSS FAST CTCSS. Tx MOD1 SELCALL. Tx MOD2 DCS RSSI CARRIER DETECT TIMER. ANALOG Rx LEVEL CONTROL AUDIO FILTER AUDIO SIGNALS MX828

Pulse Width Modulated Linear LED Bar Graph Display

HT162X HT1620 HT1621 HT1622 HT16220 HT1623 HT1625 HT1626 COM

NetPage Network Wireless Paging System (POCSAG) NP-14 Series. Operation Manual CCW

Logical Trunked. Radio (LTR) Theory of Operation

Local Asynchronous Communication. By S.Senthilmurugan Asst.Professor/ICE SRM University. Chennai.

Decoding ALERT with your StormLink IQ Receiver White Paper

Hewlett-Packard Company 1995

Chapter 6 - Info codes

CMX869 Low Power V.32 bis Modem

Faculty of Engineering Electrical Engineering Department Communication Engineering I Lab (EELE 3170) Eng. Adam M. Hammad

CAT-300DXL Repeater Controller Computer Automation Technology, Inc

MODEL 640 DAPT XTRA. Dial Access Paging Terminals for Display and Voice Pagers

Hello and welcome to this Renesas Interactive Course that provides an overview of the timers found on RL78 MCUs.

ADVANCED USER S GUIDE

Design of Vehicle Lamp Control System based on LIN bus Wen Jian-yue1, a, Luo Feng1, b

Built-in LCD display RAM Built-in RC oscillator

R/W address auto increment External Crystal kHz oscillator

DTMF Signal Detection Using Z8 Encore! XP F64xx Series MCUs

HT /4 to 1/11 Duty VFD Controller. Features. Applications. General Description

RFID ACCESS CONTROL. SRðAN LALE FACULTY OF ELECTRICAL ENGINEERING EASTERN SARAJEVO

Catalog

Part VI: Requirements for Integrated Services Digital Network Terminal Equipment

ATB-7300 to NAV2000R Product Comparison

TMR880i technical details

DraftETSI EN V1.2.1 ( )

Transcription:

The HT95R5x/6x FSK Decoder Functions D/N:AN0228E Introduction A CID phone is used for Caller Identification, also known as caller ID, and is a telephone service provided by telecommunication companies to called parties. The CID system sends out information regarding the telephone number, caller ID and calling time to the called party for storage and number reviews. The usual way of implementing a caller ID function is to use a caller program control phone switch to transmit the related information such as the caller number to the called party and sending the caller information using FSK (Frequency-shift Keying) or DTMF (Dual Tone Multi-Frequency) between the first and second ring intervals to the called party. The China telecommunication industry is using FSK to provide a caller ID service for users to subscribe. Holtek s CID Phone 8-Bit MCUs, the HT95R5x/HT95R6x, includes an internal FSK decoder. The following content describes how to implement a Caller ID Identification with an FSK decoder in the HT95R5x/HT95R6x. Operating Principles The CID contains various specifications such as Bell 202 FSK and ETSI V.23 FSK, in which the Bell 202 is the FSK CID protocol made by Bell Laboratory and is the one mainly used in the China, Singapore and the US regional areas. The following gives an introduction to the Bell 202 FSK standard. The parameters of the CID data transmitted by the program controlled switch are as follows. Modulation Type:BFSK (Binary Frequency-Shift Keying) Mark (Logic 1): 1200 ± 12Hz Space (Logic 0): 2200 ± 22Hz Transmission Speed : 1200 ± 12bps A CID data transmission is divided into two types, an on-hook transmission and an off-hook transmission. CID data transmission in the on-hook status can also be classified 1

by ringing and non-ringing types. The figure below is the CID data transmission timing of the ringing type in the on-hook status. The FSK data includes Channel Seizure Signal, Mark Signal, Message and Checksum data. Channel Seizure Signal The first signal to be sent when transmitting the CID data, is composed of one group of 300 continuous 0 and 1 in turn with the first bit as a 0 and the last bit as a 1. Mark Signal Composed of 180 1. Message There are two Message types, the SDMF (Single Data Message Format) and MDMF (Multiple Data Message Format.) The data format that the program controlled switch transmits to the recipient is the 8-bit ASCII. Checksum One byte of data. The last byte of the result of all data from the Message plus with Checksum is 0. The SMDF and MDMF data formats are shown as follows. The following is one group of the FSK SDMF data: 04H, 0FH, 30H, 31H, 32H, 33H, 31H, 36H, 35H, 39H, 35H, 36H, 33H, 31H, 39H, 39H, 39H, 39H, D8H. 2

In the above data: 04H means the Message type, the SDMF. 0FH means the Message length. 30H, 31H, 32H, 33H mean the date of 23 rd January. 31H, 36H, 35H, 39H mean a time of 16:59. 35H, 36H, 33H, 31H, 39H, 39H, 39H, 39H means a telephone number: 5631999. D8H is a Checksum, used for CID data correcting. The HT95R5x/HT95R6x includes an internal FSK decoder which supports CID specifications, the Bell 202 and ETSI V.23 with Ring and Line Reversal detection functions. The FSK decoder supports four interrupt sources to the peripheral interrupt vector, which are FSK raw data falling edge, ring detect or line reversal detect, FSK carrier detect and FSK packet data. When a ring or line reversal occurs on the line, the internal signal R_DET is low. When an R_DET falling edge is detected by the device, the RDETF flag in the FSKS register will be set to 1. When an FSK carrier signal is detected by the device, the CDETF flag will set to 1. The reference circuit is shown below. Registers relevant to the HT95R5x/6x and FSK are FSKC, FSKS, FSKD, PERIC. FSKSEL: select FSK packet data source with 1 as DOUTC and 0 as DOUT. CMSK: FSK carrier detect interrupt control bit. Set 1 to disable and 0 to enable. RMSK: interrupt control bit for Ring or Line Reversal detect. Set 1 to disable and 0 to enable. FMSK: interrupt control bit for FSK packet data. Set 1 to disable and 0 to enable. F_PWDN: FSK decoder power control bit. Set 1 for power off and 0 for the operating mode. RINGF: ringing signal flag, read only, cannot be modified by software. FSKF: FSK packet data interrupt flag with 1 meaning ready and 0 meaning not ready. DOUTC: FSK decoder COOK data output, read only, cannot be modified by software. 3

DOUT: FSK raw data output, read only, cannot be modified by software. CDETF: FSK carrier detect interrupt flag, with 1 meaning detection of the 0 and 1 legal FSK signals, or 0 meaning illegal FSK signals. RDETF: Ring or Line Reversal detect interrupt flag, with 1 meaning detection of Ring or Line Reversal and 0 meaning no detection. FSKD is to store the FSK packet data. FSKDF: FSK raw data falling edge interrupt flag, which will be set to 1 when an interrupt occurs. DTMFF: DTMF receiver interrupt flag. EFSKDI: FSK raw data falling edge interrupt enable bit. Set to 1 to enable and 0 to enable. EDTMFI: DTMF receiver interrupt enable bit. Set to 1 to enable and 0 to disable. Note that when EFSKDI is enabled, the device will automatically disable RMSK, CMSK and FMSK. If an interrupt is allowable, FSKDF, RDETF, CDETF and FSKF will all enable the external interrupt located at the 10H entry address. It will not be cleared to 0 by hardware after exiting from the interrupt subroutine and needs to be cleared by software instead before entering the next interrupt. The FKS signals on the module analysis telephone lines, TIP and RING, of the FSK decoder can generate two data types, serial data and 8-bit packet data. To ensure normal operation of the FSK decoder, it is necessary to clear the F_PWDN in the FSKC register to 0. The serial FSK data is shown either by RAW or COOK data type monitored by the DOUT or DOUTC flags. When the decoder is in the operating mode, the DOUT flag outputs the decoder output data including Channel Seizure Signal (set by 0 and 1 in turn) and Message; the DOUTC flag means the decoder output which is similar to DOUT with Channel Seizure Signal excluded. If no FSK data is detected, both DOUT and DOUTC should remain at a high level. Therefore users can implement an FSK decoder function using the DOUT flag and a timer software. In addition to the serial data type, the decoder also provides FSK Packet data. When the decoder receives an FSK signal, it will transform 10-bit data into an 8-bit packet data by neglecting the first and the tenth bits of the 10-bit data. The effective 8-bit packet data will be stored in the FSKD bit in the FSK register and the FSK packet interrupt flag FSKF will be set to 1. If the FMSK bit in the FSKC register is zero and the external interrupt is allowable, a peripheral interrupt will occur. The FSK decoder can packet the data in the 4

DOUT and DOUTC by setting the FSKSEL bit in FSKC. It should be noted that the first bit of the 10-bit data to be packeted should be zero as the Mark Signal data will not be packeted. The device must be in the normal mode in order to detect FSK carriers, analyze serial data and transform 10-bit data into an 8-bit data packet. When in the green and sleep modes, the FSK decoder will analyze wrong data while the Ring and Line Reversal detect functions are still effective. The FSK decoder Timing Figure is shown below. 5

Application Circuits 6 A A F D A + EH? K EJ= @ 5 F A A? D A JM H 8,, 0 5 0, 1 0. 1 - N JH= 1 1 JA HHK F J 2 + 2 + # 2 + % 2 + 2 + " 2 + $! 4 6 / 6-5 6, 6. ) 7, ) 2, 6. K JF K J 8 2, 6. 8 4 -. 8 / 5 5 2 1 1+ 8,,. = I D A HO FSK Decoder 6 EF. 6 12 4-5 4 E C. " %!! 4, - 6 4 1 / 8,, # 8 8,,. 1 1 0 6 $ N! A O A O # A O ' " % # & $ ' A O A O! A O $ A O A O % A O 1-4 ; 5 6 4 - ), 1) 1 / 0, 2 ) * 4 6 7-9 -, 6 0 4. 4 1 5 ) 6 5 7 6 A O " A O = JH EN A O & A O +, 2 = A + 2 6 8 4 -. 1 + 2 6-6 12 4 1 /.. " % F. + 2 6 5 1 1 + 2 6-8 : :! % $ & 0 + 2 6 : + 2 6 :! % $ & 0 1 6 6 4 6 4 : + 8 5 5 #!. " %. - N JA H = 1 JA HHK F J 6 E A H (Refer to HT95R5x data sheet) 6 E A H 6

S/W Flowchart Start Initialize each register, F_PWDN=0, FMSK=0 External interrupt occurred from FKSF Interrupt management, read FSK Data Packet FSK data management Wait for the next interrupt CID receive compelete? N Y CID data store Program Description The program will receive CID data in SDMF and MDMF formats in the on hook status and store it in RAM Bank1 after processing. The SDMF data contains the time (ex. March 17 th, 16:18) and a telephone number (ex. 5551212). The MDMF data contains the time, a telephone number and a name (ex. John Smith.) Program Example ; Option: WDT Disable include HT95R55.inc ds.section 'data' VAR0 DB? RX DB 40DUP(0) ;save CID information COUNT0 DB? COUNT1 DB? COUNT2 DB? LENGTH DB? ; CID Length from CID LENGTH1 DB? ; LENGTH1=LENGTH+3,(Compared with LENGTH, Add message type, ; message length and checksum) FLAG_S DBIT ; Receive Single Data Message Format Flag FLAG1 DBIT ; Finish receiving flag FLAG0 DBIT ; Receive channel seizure signal 55H FLAG_M DBIT ; Receive Multiple Data Message Format Flag cs.section 'code' JMP 0000H MAIN_START 7

I I I JMP I I 0004H 0008H 000CH 0010H FSK_INT 0014H 0018H 0020H MAIN_START: SET UPEN CALL DELAY_20MS SET MODE1 CLR F0 CLR F1 CALL CLEAR_RAM0 MOV A, 01H MOV BP, A CALL CLEAR_RAM1 MOV A, OFFSET RX MOV MP0, A MOV A, 40H MOV MP1, A CLR F_PWDN CLR CMSK CLR RMSK CLR FMSK CLR EFSKDI CLR FSKSEL SET EMI SET EPERI L0: SZ FLAG_S JMP L1 SZ FLAG_M JMP L1 JMP L0 L1: SNZ FLAG1 JMP L0 CLR EPERI MOV A, 01H MOV BP, A MOV A, OFFSET RX MOV MP0, A L2: MOV A, IAR0 MOV IAR1, A INC MP0 INC MP1 INC COUNT0 MOV A, LENGTH1 SUB A, COUNT0 SNZ C ; System Clock: HCLK 3.58MHz ; Clear RAM bank0 and bank1 ; FSK decoder work at operation mode ; enable Carrier detect interrupt ; enable Ring or line reversal detect interrupt ; enable FSK packet data interrupt ; disable FSK RAW data falling edge interrupt ; select FSK packet data source DOUT ; enable peripheral interrupt ; store the CID from RX to ram bank1 8

JMP L3 MOV A, COUNT0 XOR A, LENGTH1 SNZ Z JMP L2 INC COUNT2 L3: CLR FLAG_S CLR FLAG_M CLR FLAG1 CLR FLAG0 CLR COUNT0 CLR COUNT1 CLR LENGTH CLR LENGTH1 MOV A, OFFSET RX MOV MP0, A SET EPERI JMP L0 FSK_INT: CLR EPERI SZ CDETF ; check FSK carrier detect interrupt flag CLR CDETF SZ RDETF ; check ring or reversal detect interrupt flag CLR RDETF SNZ FSKF ; check FSK packet data interrupt flag JMP EXIT_INT CLR FSKF SZ FLAG1 JMP EXIT_INT CALL DECODE_SUB EXIT_INT: CLR PERF CLR FSKDF CLR RDETF CLR CDETF CLR FSKF SET EPERI I DECODE_SUB: SZ FLAG0 JMP SUB0 MOV A, FSKD XOR A, 55H SNZ Z SET FLAG0 SUB0: SZ FLAG_S JMP M1 SZ FLAG_M JMP M1 MOV A, FSKD XOR A, 04H SZ Z JMP S0 MOV A, FSKD XOR A, 80H ; detect FSK channel seizure signal 55H ; check SDMF message type ; check MDMF message type 9

SZ Z JMP M0 S0: SET FLAG_S JMP M1 M0: SET FLAG_M M1: INC COUNT1 MOV A, COUNT1 XOR A, 02H SNZ Z JMP M2 MOV A, FSKD MOV LENGTH, A ADD A, 03H MOV LENGTH1, A M2: MOV A, FSKD MOV IAR0, A INC MP0 MOV A, COUNT1 SUB A, 3 SNZ C MOV A, COUNT1 XOR A, LENGTH1 SZ Z SET FLAG1 ; get message length ; save the CID information to RX ; check if Receive action finish CLEAR_RAM0: MOV A, 40H MOV MP0, A CLEAR0: CLR IAR0 MOV A, MP0 XOR A, 0FFH SZ Z INC MP0 JMP CLEAR0 CLEAR_RAM1: MOV A, 40H MOV MP1, A CLEAR1: CLR IAR1 MOV A, MP1 XOR A, 0FFH SZ Z INC MP1 JMP CLEAR1 DELAY_20MS: MOV A, 165 10

MOV VAR0, A DELAY: SDZ VAR0 JMP DELAY Conclusion The example program has implemented a SDMF and MDMF CID data decoding function which can be used as a reference source for user applications. 11