MESi makes telephony and wireless signal processing software components ported to popular DSP devices. Most telephony DSP products are derived from a C Source algorithm and channel model simulation called VSIM. You can download the VSIM command-line executable here and evaluate various modems, DTMF, call progress, etc. Most of the DSP Object and Assembly Source products were developed by manually porting the algorithms in VSIM to the target DSP's native assembly language and adding a C-to-assembly interface. This results in Object Code typically 40% of the size of optimizer-compiled C source, and the MIPs are the lowest in the industry.
For more detailed information on these products including ITU, Bellcore, ETSI compliance, please download manual.pdf.
Baudot TDD - This module
modulates and demodulates Baudot Telecommunications Devices for the Deaf (TDD)
FSK-modulated characters at 45.45 bits/sec. It is fully compliant with TIA/EIA-825,
formerly EIA Draft 9, PN 1663. Unlike other FSK telecom
modems such as Bell103, the Baudot modulator only turns carrier on when a
character is being modulated and switches to silence after the complete
character and extended stop-bit are transmitted. Thus the Baudot modem functions
as a burst-mode modem where the carrier is present only during the transmission
of characters, and there is no MARKing tone when there are no characters.
On the transmit side, the baudot modulator scans the transmit data buffer, Tx_data, for the presence of a start bit (a SPACE or “0”) and transmits silence until a start-bit is detected. After a start-bit is detected, the modulator then transmits the next 5 bits normally as the data payload. The sixth bit is treated as the stop-bit and is extended to 250 msec. If no more characters are present for transmission. This stop-bit extension can be overridden by the user at build-time (requires source code), or at run-time by modifying the value in Tx->interpolate during the stop-bit modulation interval. It is important for users to understand that the FSK modulator is continuously running when transmitter() is configured for Baudot operation. It simply mutes the signal while in the TX_BAUDOT_SILENCE_ID state, when it is not transmitting characters and their start/stop bits.
The receiver searches the receive samples for a modulated start-bit (SPACE tone at 1400 Hz) and upon detection, begins data collection into a shift-register. All 5 data bits plus start and one stop bit are collected and released into Rx_data only if all of these bits are validated as data bits. This prevents the Baudot demodulator from false detecting Baudot characters in the presence of voice or other line impairments. The User can monitor Rx_data head and tail pointers, Rx->data_head and Rx->data_tail, for any displacement to determine if any bits have been received. If Rx->data_head=Rx->data_tail, then no character is present. When the complete character is received and validated, then 7 bits (one start bit, 5 data bits, and one stop bit) will appear in Rx_data, and Rx->data_head will be ahead of Rx->data_tail by 7.
Command-line demonstration program is available at BAUDDEMO that modulates and demodulates text files, and it can process signal files (8 kHz sample rate, 16-bit linear ascii decimal file format).
Caller ID, Bellcore/ETSI - This module generates and detects the Calling Number Delivery service specified in Bellcore GR-30-CORE and in the European Telecommunications Standards Institute ETS 300 778 standards. The transmitter can be configured to generate transmission without power ringing which includes Caller Alert Signal (CAS) or Terminal Equipment Alert Signal (TAS), and transmission with power ringing which inserts between the first and second rings. The receiver detects the start and stop of CAS and automatically detects and demodulates the Caller ID presentation message layer and validates the checksum. Assembly-time options let you build the object with only transmitter or receiver code generation if desired to minimize the size.
Caller ID, DTMF - This module generates and detects the Calling Line Identification Presentation (CLIP) as specified in TeleDanmark Technical Specification TDK-TS 900 216. Countries other than Denmark using this form of Caller ID, either similar to or a variation of this implementation, include Finland, Iceland, the Netherlands, India, Belgium, Sweden, Brazil, Saudi Arabia and Uruguay. The transmitter appends the preamble and post-amble characters. The receiver detects the preamble character and automatically demodulates the caller ID presentation message layer and end of information character. Assembly-time options let you build the object with only transmitter or receiver code generation if desired to minimize the size. The demonstration program provides a digital loop-back that loops the Tx sample outputs back into the Rx sample inputs. Standard output provides an indication of the detection of a Caller ID burst along with the received data.
Caller ID, Japan - This module generates and detects the Number Display service as specified in Nippon Telegraph and Telephone Corporation (NTT) Technical Reference for Telephone Service Interfaces, Edition 5. The transmitter appends the preamble and post-amble, calculates parity and the CRC. The receiver detects the beginning and end of the preamble sequence and automatically demodulates the caller ID presentation message layer, strips parity and validates the CRC. Assembly-time options let you build the object with only transmitter or receiver code generation if desired to minimize the size. The demonstration program provides a digital loop-back that loops the Tx sample outputs back into the Rx sample inputs. Standard output provides an indication of the detection of a Caller ID burst along with the received data.
Channel Memory - This module creates static channel memory for MESi Components from default size parameters in the build-time configuration parameters file, and provides a function call to initialize it. Standard Component products are shipped with "memory.obj" built for one channel. Object code users can specify additional channels at time of purchase for an additional per-channel fee. Source code users set the channel memory size parameters and number of channels at build-time without restriction.
- This module generates and detects 16-DTMF digits with configurable
parameters and talk-off abatement. The user can configure many generation and detection
parameters either at compile-time or at run-time, including transmit tone pair
twist and receive detection power level.
° DTMF digits (0-9, #,*, A,B,C, D) generation and detection.
Extensive performance testing was conducted by Lucent Technologies in Middletown, NJ for Q.24, Bellcore, and Mitel test tape compliance for signal impairments and speech simulations. Please click here to review test results.
The Fax Intercept product is a collection of C Source code modules that contain the required modem, signal processing, call progression processing, fax protocol, and pixel format conversion components from the following ITU-T Recommendations and MESi signal processing products:
G.711 μ-law decoder
“GenDet” signal detection module
T.30 Group 3 fax protocol with ECM
T.4 processor supporting Modified Huffman and Modified Read formats, and T.6 Modified-Modified Read format.
V.17 (14.4 Kbps, 12.0 Kbps, 9.6 Kbps, and 7.2 Kbps)
V.21 (300 bits/sec. FSK)
V.27ter (4.8 Kbps, and 2.4 Kbps)
V.29 (9.6 Kbps, and 7.2 Kbps)
In addition to the above processing, the Fax Intercept product includes a “Fax-to-TIF” post-processor that re-formats raw pixel data into the Tagged Image File Format (TIFF) for storage of images to files. The Fax Intercept module opens a specified “WAV” formatted binary file, and processes all of the samples captured at an 8 kHz sample rate (standard PCM rates). A switch option is provided to enable μ-law or A-law decoding if required to convert the samples to linear form at 16-bit resolution. The samples are processed by the standard MESi “Fax Bundle” modem and tone processing software to detect the T.30 control tones and demodulate the V.21 binary formatted messages and the high rate (v.27, v.29, and v.17) TCF and page data bursts. The Fax Intercept module implements the ITU-T T.30 Group 3 Fax protocol as required to control and sequence the Fax Bundle signal processing software through a complete fax transmission. The raw demodulated page data is then decoded and converted into pixel information per the ITU-T T.4 Recommendation. The pixel data are finally be converted to the TIFF format and written to one or more files corresponding to the pages present in the processed WAV file. The V.21 Binary-coded messages are captured to a separate log file and include Fax protocol information such as:
The number of faxed pages.
Identification information of the calling and answering terminals.
Standard capabilities of the calling and answering terminals
Type of non-standard capabilities of the calling and answering terminals not covered by the T.30 recommendation
Bit rate of the page data will be output to a separate log file.
ECM and other error control information.
The Fax Intercept module has been designed to simplify integration and usage, and is further enhanced to combine all interfaces, options, and memory elements required into a single structure and Applications Programmer Interface (API) function as shown below:
int faxIntercept(struct FAX_INTERCEPT_STRUCT *
This function operates as a “run to completion” process and is self-initializing. It expects the user to supply several parameters, such as input sample file and output TIFF and log file handles, in the FAX_INTERCEPT_STRUCT structure, which is the function’s only argument.
The structure “FAX_INTERCEPT_STRUCT” allows the user to completely manage memory allocation and have direct access to Fax Intercept context, state, and all of the v.21 binary message information.
The input samples are in the file specified by the filename supplied in “InWavFileName”. If NULL, then the function exits. The Intercept module is capable of determining the compression format of the data from WAV file header information, and configurable for operation with binary linear, μ-law, or A-law formatted data, or ascii text format by default
The output page image data is stored in the TIFF file specified by the filename supplied in “OutTifFileName”. If NULL then the output image data will not be written to file. All pages in the fax transmission embodied in the “InWavFileName” input file will be written to the single TIFF file in in “OutTifFileName”.
The Fax T.30 binary formatted messages and fax protocol state logging information are captured in the text file specified by the filename supplied in “BufLogFileName”. If NULL, then no logging will be saved.
The FaxIntercept command-line demonstration program (download download\faxInterceptCmdLine.zip) allows users to process signal files in linear and compressed formats, and generate TIFF files to display the page contents. The usage information (listed below) is displayed when the program is run with the -help argument
faxintercept input_file_name output_tif_filename [summary_file]
[-mulaw | -alaw | -bigendian | -littleendian | -ascii] [-single] [-buflog]
[-ecm64 | -ecm256 | -nonecm ] [ -215mm | -255mm |303mm ] [ -mh | -mr -mmr ]
input_file_name: name of the audio sample file,
the default is "..\..\csrc\faxintercept\v29.wav"
output_tif_filename: name of the output tif[base] filename,
the default is ".\outtif"
summary_file: name of a text file that summaries the call
ascii when the input file is ascii signed decimal (-32768..32767)
mulaw when the input file is Mu law encoded
alaw when the input file is A law encoded
bigendian when the input file is 16 bit binary with the msbtye first
littleendian when the input file is 16 bit binary with the lsbtye first
ecm64 to set no-dcs default to 64 byte ecm frames
ecm256 to set no-dcs default to 256 byte ecm frames
mh to set the no-dcs default to modified huffman encoding
mr to set the no-dcs default to modified read encoding
mmr to set the no-dcs default to modified modified read encoding
nonecm to set no-dcs default to non-ecm
215mm to set no-dcs scanline to 215mm
255mm to set no-dcs scanline to 255mm
303mm to set no-dcs scanline to 303mm
single when the output is 1 page per tif,
the default is 1 tif per call (multi-page tif)
GenDet signal Generator and Detector
GenDet module provides for the generation and detection of a variety of signals associated
with call progress, digit processing, and fax modem startup. It provides a generic 2 tone
generator module with configuration functions to produce the following signals:
° Dialtone - 350 Hz + 440 Hz tones (North American default)
° Ringback - 440 Hz + 480 Hz tones, 4.0 sec. on, 2.0 sec. off (North American default)
° Busy - 480 Hz + 620 Hz tones, 0.5 sec. on, 0.5 sec. off (North American default)
° Reorder - 480 Hz + 620 Hz tones, 0.25 sec. on, 0.25 sec. off (North American default)
° CNG - 1100 Hz tone (FAX)
° CED/ANSWER - 2100 Hz tone (FAX and legacy data modems)
° ECSD - 2100 Hz tone with phase reversals at .55 sec.
GenDet includes detection and auto-startup for Generic Call Progress tones, Fax start-up tones, and fax modem startup modulations:
° Dialtone detector and tone tracker for 350 Hz to 650 Hz continuous tone(s).
° Ringback - detector and tone tracker for 350 Hz to 650 Hz tone(s) ending with at least 0.8 msec of silence.
° Busy/Reorder - detector and tone tracker for 350 Hz to 650 Hz 50% duty cycle tone(s) over 1.4 to 2.2 sec.
° CNG detector and tone tracker for 1100 Hz fax Calling tone.
° CED/ANSWER detector and tone tracker for 2100 Hz fax Called tone detection.
° ECSD - Echo Canceller/Supressor Disable (2100 Hz with phase reversals) discriminator.
° TEP1700 - detector and tone tracker for 1700 Hz fax Talker Echo Protection tone for v.29.
° TEP1800 - detector and tone tracker for 1800 Hz fax Talker Echo Protection tone for v.17 and v.27.
° v.17 detection and demodulator startup.
° v.21 channel 2 HDLC Flags detection and demodulator startup.
° v.22 USB1detection and Rx_v22A (ANSwer-side) demodulator startup.
° v.27ter detection and demodulator startup - discriminates between 2,400 and 4,800 rates.
° v.29 detection and demodulator startup.
MF - This module generates and detects 15-R1, 15-R2 forward, and 15-R2 backward digits per ITU Recommendation Q.320. The user can configure many generation and detection parameters either at compile-time or at run-time, including transmit tone pair twist and receive detection power level.
° R1 digits (0-9, codes 11, 12, KP, KP2, ST) detection.
° R2 Forward and Backward digits (0-9, A,B,C,D,E) generation and detection.
Extensive performance testing was conducted for Q.24, Bellcore, and Mitel test tape compliance for signal impairments and speech simulations. Please click here to review the results.
MSK - This half-duplex modem implements ITU-R M.623 recommendation and is used in both wire-line telecom and wireless data radio applications. It employs Minimum Shift Keyed modulation at data rates of 1.2 and 2.4 kbits/sec. at symbol rates of 600 symbols/sec. and 1200 symbols/sec. respectively, and at carrier frequencies of 1500 Hz and 1800 Hz respectively. It is a 'raw' modem in the sense that there is no preamble or training sequence associated with it, so the user must insert data bits as required for acquisition and sync.
STU-III Relay - The MESi STU-III Relay Software System supports Future Secure Voice Systems (FSVS-210) secure telephone relay through digital continuous and packet-based network systems such as Internet or satellite channels. It performs the recognition, deconstruction, and reconstruction of all STU-III telephone line signals, and may be inserted between two STU-III telephone units to connect them transparently. It can operate as a stand-alone software system without the need for any operating system support, or as an adjunct to an existing telephony system, such as a VoIP, running under virtually any operating system.
Supports 2,400, 4,800, and 9,600 bits per sec operation, full and half-duplex.
Terminating or Pass-thru modes: the relay can terminate a PCM highway on a single port, or it can be configured to pass PCM samples from one port to a second port and inhibit passage when a STU-III call is detected. The pass-thru mode is ideal for adding STU-III capability to existing voice\fax\data relay systems.
Run-time selectable PCM frame size and network packet size/packet rate.
Low-overhead network packet structure - only three header octets per packet with variable payload length and packet routing (channel-ization) capability. Optional redundant packet feature to mitigate network packet errors or dropped packets. Built-in programmable jitter buffer accommodates variable delay networks, such as Internet.
Optional "headerless data" feature - allows for direct transport of continuous data packets with zero packet overhead.
Packet structure similar to ITU T.38 and suitable for encapsulation under TCP, UDP, and RTP protocols. Packet types segregated into either STU_EVENT" control packets and STU_DATA continuous data packets.
High performance - compliant with PSTN impairments under FSVS-220; tolerates network delays up to 750 msec., dropped packets, and network packet jitter. Optional data packet sequence numbers/time stamps available to resolve network packet out-of-order arrival impairment.
Low MIPs - full 30-channel E1 can fit in a single TMS320C6400 DSP device.
- The MESi FaxRelay is a full featured T.38-compliant fax relay. Built on
top of the MESi fax modems, the relay can easily be configured to operate in it's native packet mode for custom
applications, T.38, or AAL-2 Frame Relay. The fax modems are available in both
C and manually-ported and optimized assembly versions for selected targets. The protocol layers are
available in C source or object code on a variety of platforms. All C code is
ANSI compliant, so the user is assured compatibility with a custom target.
The relay is highly scaleable. The minimal configuration requires users to buffer network packets until the relay has enough memory to accept them. Alternatively, the user can configure the relay with more internal memory so that network packets are accepted by the relay when available.
RlyRelayInitChannel - initialize the Relay channel memory
RlyRelayIf - continuously call this to generate/consume 8 kHz samples.
RlyPacketFmRelay - get network packets produced by the relay to be sent on to the network (i.e. to the TCP/IP stack)
RlyPacketToRelay - put your received network packets into the relay for analog signal re-generation
Analog Devices: BF53x BlackFin, ADSP-219x, ADSP-211xx (Sharc)
GNU: Linux, coLinux, ucLinux
LSI Logic\Verisilicon: ZSP400, ZSP500
Microsoft: Windows 2000, XP
Texas Instruments: TMS320C5400, 'C5500, 'C6400
V.14 Sync/Async Converter - This module implements the synchronous-to-asynchronous conversion protocol specified in ITU-T Recommendation v.14. On the transmit side, it inserts a zero start bit and a one stop bit to a transmit byte, slices it to the modem's symbol data format, and writes it to the modem's Tx_data transmit symbol buffer. On the receive side, it searches the incoming bit stream for a zero start bit. Upon detection, it de-slices the received symbols from the modem's Rx_data receive symbol buffer to form an output byte, and strips out the start and stop bits. V14 can be built to create it's own input and output byte buffers, or to make use of existing input and output byte buffers in a software UART or other byte-driven I/O device.
V.17 Modem - This half-duplex modem is intended for use in FAX applications. It employs trellis coded modulation at data signaling rates of 7.2, 9.6, 12, and 14.4 kbit/s with a symbol rate of 2400 symbols per sec. The modulation methods are rectangular 16-QAM at 7.2 kbit/s, modified cross 32-QAM at 9.6 kbit/s, rectangular 64 -QAM at 12 kbit/s, and modified cross 128-QAM at 14.4 kbit/s. It includes an automatic adaptive equalizer, long-train and re-sync sequences, and optional Talker Echo Protection tone generation.
V.21/Bell 103 Modem - This modem is used in fax and v.34 startup applications. It is a 2 channel modem operating at a data signaling rate of 300 bit/s with a symbol rate of 300 symbols/sec. The modulation method is continuous phase frequency shift keying (CP-FSK).
V.22bis/Bell 212a Modem - This split-band data modem supports full duplex data transfer at 1200 and 2400 bit/s with a symbol rate of 600 symbols/sec. The modulation methods are differential QPSK at 1200 bit/s, and rectangular 16-QAM at 2400 bit/s.
V.23/Bell 202 Modem - This modem is used generic data and caller ID applications. It is a 2 channel modem with the forward channel operating at data signaling rate of 600 and 1200 bit/s with symbol rates of 600 and 1200 symbols/sec., and the backward channel operating at a data signaling rate of 75 bit/s with a symbol rate of 75 symbols/sec. The modulation method is continuous phase frequency shift keying (CP-FSK).
V.26 Modem - This full duplex echo canceller data modem implements the v.26 and v.26bis standards and operates at 1.2 and 2.4 kbits/sec, and is used primarily for remote terminals, POS readers, and STU-III applications. The modulation method is essentially QPSK and has two phase plans - Alternative A which has ±90 degree increments, and Alternative B which has ±45 and ±135 degree increments. By default, the Rx_init_v26() functions enable a detector for the synchronizing signal to detect start-up and discriminate 1.2 and 2.4 kbits/sec. rates. The detector also searches for the "P1800" pattern (0202... dibits) associated with the FSVS-201 application in STU-III phones.
V.27 ter Modem - This half/full duplex modem is used in half duplex FAX applications, and full duplex in leased-line applications. It employs QPSK and 8-PSK modulation at data signaling rates of 2.4 and 4.8 kbits/sec with symbol rates of 1200 and 1600 symbols/sec respectively. It includes an automatic adaptive equalizer, long and short training sequences, and optional Talker Echo Protection tone generation.
V.29 Modem - This half duplex modem was intended for 4 wire operation but is used in FAX applications. It employs an unusual amplitude-phase shift modulation scheme at 4.8, 7.2, and 9.6 kbits/sec with a symbol rate of 2400 symbols/sec. It includes an automatic adaptive equalizer, long-train and re-sync sequences, and optional Talker Echo Protection tone generation.
V.32 Modem - This full duplex echo canceller data modem operates at 4.8 and 9.6 kbits/sec. The symbol rate for all data signaling rates is 2400 symbols/sec. The modulation methods are: QPSK at 4.8 kbit/s, rectangular 16-QAM at 9.6 kbit/s non-trellis coded modulation (TCM). This version is offered for users who do not need the V.32 trellis coded option and want a lower cost, smaller modem.
V.32 bis Modem - This full duplex echo canceller data modem operates with trellis-coded modulation at 4.8, 7.2, 9.6 (TCM and non-TCM), 12.0, and 14.4 kbit/sec. The symbol rate for all data signaling rates is 2400 symbols/sec. The modulation methods are: QPSK at 4.8 kbit/s, rectangular 16-QAM at 9.6 kbit/s non-trellis coded modulation (TCM), rectangular 16-QAM at 7.2 kbit/s, modified cross 32-QAM at 9.6 kbit/s, rectangular 64 -QAM at 12 kbit/s, and modified cross 128-QAM at 14.4 kbit/s.
V.42 Error Control - This module implements the LAP-M error control protocol specified in ITU-T v.42. The frame and window sizes and string length can be altered at build-time, and a fail-down monitor bit indicates when to fall-back to V.14 framing as needed.
V.42bis Data Compression - This module implements the ITU-T v.42bis data compression standard. The codeword size defaults to 2048 and can be reduced at build-time to save memory. V42bis can be built optionally as a stand-alone compressor, or as a companion to the v42 error control component. When used with v42, it is enabled by default and operates under the same Data Handler API, so that the user does not need any modifications to his interfaces.
UART - This module implements a software Universal Asynchronous Receiver/Transmitter using one of the DSP serial ports. Using an intermediate clock frequency of approximately 460.8 kHz, it can operate from 300 baud up to 115,200 baud. In most applications it can derive suitable timing from the CPU clock and no external baud clock is required. The parallel data interface consists of two circular, byte-wide buffers, TxU_data and RxU_data, and the hardware flow control signals RTS, CTS, DSR, and DTR are optionally supported through a variety of DSP pin options or an external I/O port. The user APIs and a functional description are briefly presented below
void UART_block_init(struct UART_BLOCK *) - This function initializes
the UART_block structure members for default operation. The user MUST
call this function before any UART operations are enabled, and it is
recommended that it be called immediately after reset or entry into
main(). However, it only needs to be called once.
int Tx_UART(struct UART_BLOCK *) - This function implements the UART
transmitter, and it returns the 16 bit integer digital sample stream
representing samples at 460.8 kHz. In a typical application, this
function is called in the serial port interrupt service routine to
produce the next 16 bit transmit word. It can also be called in a
foreground loop where sample buffering is provided, such as in
serial port auto-buffering or TDM-slotted applications.
int Rx_UART(int, struct UART_BLOCK *) - This function implements the
UART receiver, and it's first argument is the 16 bit integer digital
sample stream representing samples at 460.8 kHz. In a typical
application, this function is called in the serial port interrupt
service routine to process the current 16 bit receive word. It can also
be called in a foreground loop where sample buffering is provided, such
as in serial port auto-buffering or TDM-slotted applications.
void init_UART_hardware(void) - This function initializes the serial
port peripheral as configured by the compile-time options for
TXD/RXD operations. It also initializes, as necessary, the hardware
device used for RTS and CTS. Note that the interrupt vector is "hooked"
and replaced withg a vector to the UART_ISR() routine so the interrupt
vectors must be write-able.
interrupt void UART_ISR(void) - This function is the serial port
interrupt service routine operating at 28,800 Hz. It calls both the
Tx_UART() and Rx_UART() routines to process the serial stream bits.
This module has a variety of compile-time hardware configuration options. When the UART serial data circuits (TXD and RXD) are mapped into one of the serial ports, then the serial bit stream is generated by "sampling" the TXD and RXD signals at approximately 460,800 kHz. This is 4 times the maximum baud rate of 115,200 bits per second -> higher baud rates could be achieved by scaling this sample rate higher. It is approximate because RS-232/v.14 start/stop bit communications allow significant error in the bit duration. The default CPU clock speed of 100 mHz divides to 460.829 kHz, which is about 63 ppm in error, but the UART functions reliably at all baud rates. The default serial port word size is 16 bits, which results in a serial port interrupt rate of 460,800/16=28,800 kHz. At each interrupt, the Tx_UART() and Rx_UART() process the serial port receive and transmit words as a frame of 16 bits. The user must ensure that the combination of TXD_RXD_CLK_DIVIDER and BAUD_DIVISOR result in a digital sample rate 460.8 kHz and the desired baud rate. There are several choices for mapping the RTS and CTS flow control signals since these signals are not synchronous nor are they tightly coupled with the TXD/RXD data conditions. For hardware where serial port bits can be re-mapped into an input and an output pin, the RTS_CTS_MAPPING additionally enables serial port initialization code in init_UART_hardware() to be inserted.