Make/Model  Device VersionConnection Type
Caller ID Modems

Caller Id Modems supporting AT#CID=1 or AT+VCID=1

Serial

Description:

This driver interfaces CQC to a Caller ID capable modem for the purpose of decoding the Caller ID data that is sent between the first and second ring by the telephone company. This data is made available to CQC through fields and is also used as an index to look up extended information from a text file that can provide a more verbose description. The driver maintains a history file with the last 10 calls being able to be displayed and provides a number template file to format the number.

This driver provides the following functionality:

  1. Decodes the incoming CID data and presents it to CQC for display.
  2. Looks up enhanced information in a text file for more verbose data.
  3. Maintains a history of the last 10 callers, persistently stored in a text file.
  4. Presents the history data both as a single string with minimal formatting and as a set of individual fields for customized layout 
  5. Provides a dynamic field that indicates the line is ringing.
  6. Provides a Boolean flag field that is set when a new call arrives and can be reset by the user to indicate a call has arrived since last viewing.
  7. Provides an expanded number field for text to speech engines
  8. Provides a formatted number field that formats the callers number according to a set of templates.
  9. Allows the user to select either 12 or 24 hour time format.
  10. Prevents the modem from answering the call.

 Limitations:

This Driver has only been tested against a few of modems, so it is recommended that a Modem Test Procedure described below, is carried out to ensure modem compatibility before attempting to use this driver.

Connection Details

The Modem CID Driver connects directly to a Caller ID compatible modem using a standard modem cable.

Driver Fields

This section lists the fields that the driver makes available, their types, minimum and maximum values, etc...

NameTypeR/WDescription/Limits
DateMonthStringRHolds a numeric version of the current Month eg 01 = Jan, 12 = Dec
DateMonthLongStringRHolds an English version of the month eg January, February...
DateDayStringRHolds the current day of the month
TimeStringRHolds the time the call arrived
NumberStringRHolds the Callers Number (where presented)
NameStringRHolds the name of the caller (where presented)
RingingStringRIndicates the line is ringing
FullNameStringRHolds the callers full name (derived from the data.txt file)
AddressStringRHolds the callers address (derived from the data.txt file)
Data1StringRGeneral purpose field (derived from the data.txt file)
Data2StringRGeneral purpose field (derived from the data.txt file)
HistoryStringRHolds a history of the last 10 callers (derived from the history.txt file)
NewCallBooleanR/WProvides a user reset able flag that is set when a new call arrives.
ExpandedNumberStringRProvides a field with each digit of the number separated by a space. Useful for text to speech engines
FormattedNumberStringRProvides a field with the number formatted according to the templates defined in format.txt
HistoryRowXNameStringR The fields below are a collection of 70 fields generated to store the history data as separate fields for custom formatting. X = the row number
HistoryRowXFullNameStringRAs Above
HistoryRowXNumberStringRAs Above
HistoryRowXAddressStringRAs Above
HistoryRowXTimeStringRAs Above
HistoryRowXDateDayStringRAs Above
HistoryRowXDateMonthLongStringRAs Above

 

Driver text files

           Data.txt

This file is used to provide the CQC Modem CallerID Driver with enhanced fields. When a number is received via Caller ID this file is parsed looking for a match in the first token of each line. If a match is found then the other tokens are read and transferred into the relevant fields. A default entry can also be used as a catch all if desired.
The fields are comma delimited and are set up as follows:

Number,Name,Address,Data1,Data2
Default,Default Name,Default Address,data1,data2

The Data1 & Data2 fields are just provided as general fields which can hold anything. The original intent was to be able to provide a flag to the events system that it could use to decide if the person calling was important enough to interrupt the movie or whatever. Any lines beginning with // are ignored. Do not leave any blank lines. Do not leave any white space characters at the end of the file eg CR This file should be placed in CQCData\MacroFileRoot\ModemCallerID\Data.txt

Example:
12345678,Rohan Mobile,Out and About Somewhere,Friend,Interrupt
87654321,Uncle Bill,123 Smith St,Relation,No Interrupt
18273645,Luscious Leticia,At Home,Professional Acquaintance,Interrupt

 

History.txt

Also as of V2.0 you need a History.txt file in the same directory. Note: the Delimiter is a vertical pipe | character!

Example:
Time|DateDay|DateMonthLong|Name|FullName|Address|FormattedNumber
Time|DateDay|DateMonthLong|Name|FullName|Address|FormattedNumber
Time|DateDay|DateMonthLong|Name|FullName|Address|FormattedNumber
Time|DateDay|DateMonthLong|Name|FullName|Address|FormattedNumber
Time|DateDay|DateMonthLong|Name|FullName|Address|FormattedNumber
Time|DateDay|DateMonthLong|Name|FullName|Address|FormattedNumber
Time|DateDay|DateMonthLong|Name|FullName|Address|FormattedNumber
Time|DateDay|DateMonthLong|Name|FullName|Address|FormattedNumber
Time|DateDay|DateMonthLong|Name|FullName|Address|FormattedNumber
Time|DateDay|DateMonthLong|Name|FullName|Address|FormattedNumber
 

This file should be placed in CQCData\MacroFileRoot\ModemCallerID\history.txt

Format.txt

This file is used to provide the CQC Modem CallerID Driver with templates that allow the user to customise the formatting of the callers number. When a number is received it is compared to each template in the format.txt file for a match. If a match is found then the number is formatted to match the template.

Each template consists of # characters, digits and other characters.
Each # character represents the position of a number.
Each digit represents an actual fixed digit position.
The total number of # characters and digits, on each line (template) is used to match against the total number of digits in the callers number.
Combinations of # and digits must be unique for each template.
If a matching template is not found then the number is copied to the FormattedNumber field unchanged.
 

Any lines beginning with // are ignored. Do not leave any blank lines. Do not leave any white space characters at the end of the file eg CR This file should be placed in CQCData\MacroFileRoot\ModemCallerID\format.txt

Example:

// Any 10 digit number beginning with 02 will match (New South Wales & Australian Capital Territory)
(02) #### ####
// Any 10 digit number beginning with 03 will match (Victoria & Tasmania)
(03) #### ####
// Any 10 digit number beginning with 07 will match (Queensland)
(07) #### ####
// Any 10 digit number beginning with 08 will match (Western Australia, South Australia & Northern Territory)
(08) #### ####
// Any 10 digit number beginning with 04 will match (Mobile phones)
04## ### ###
// Any 8 digit number will match
#### ####
// This is an extreme example
The first two digits are ## and the next two digits must be the numbers 7 and 8 and the rest of the twelve digit number must look like ##6#90##

Note: These files are NOT provided with the Driver, and should be built by hand using notepad or similar, and placed in the CQCData\MacroFileRoot\ModemCallerID\ directory.

Modem test procedure

  1. Plug it in to a free serial port (no need to load drivers or anything like that)
  2. Fire up HyperTerminal, which is in the Accessories area of the Start Menu
  3. Connect to the modem via the serial port that you plugged into.
  4. type AT&f enter (this resets it to factory defaults) you should get OK returned
  5. type each of the following commands to see if any of them return ok

        For Rockwell chipset modems: AT#CID=1
        For USRobotics chipset modems: AT#CID=1
        For Cirrus Logic chipset modems: AT+VCID=1
        For Lucent chipset modems: AT+VCID=1
        For Conexant HCF chipset modems: AT+VCID=1

        If you get an ok then you should be good to go.
  6. Connect the modem to a phone line and ring that number from another phone, you should see the data displayed on HyperTerminal.

Note: You may need the phone company to activate this service first.