Minggu, 02 Agustus 2009

Login / Register How to Design a Soft Modem Using a Digital Signal Controller from Freescale

This article presents the hardware and software design of a low-cost V.21/V.22/V.22bis soft modem. The article doesn't include a traditional telecommunications Pulse Code Modulation Coder/Decoder (PCM codec). An optional serial port with AT command set is included as a test fixture. Modem performance figures measured on the implementation are included for reference.

A soft modem is one that can be used to modulate/demodulate data to be sent serially over an analog channel directly, without the need for a serial data path to another entity to supply data or control signals. It includes a simple way to dial phone numbers, detect ringing signals, control the hook relay of the DAA, input and output analog data, connect with remote modems and communicate with them.

Low-Cost Soft Modem System
Low-Cost Soft Modem System

This project shows the simplicity of such a design, how few resources of the processor it takes, and how well it performs on USA average lines. This design omits the standard telecommunications codec, instead using a Pulse Width Modulation (PWM) for output and Analog-to-Digital Converter (ADC) for input. Since both of these peripherals are readily available from the many peripherals on one 56F8300 series device, along with more processing power than required from the single core, the design is a true one-chip, one-core system that includes telecommunications ability with room for even more system functionality.

Modem Analog Block Design
Modem Analog Block Design

Online commands supported are:

•ato, which returns to online data state

•ath, which hangs up the phone

•atz, which hangs up the phone and performs a soft reset of the modem

•+++ escape sequence, with three second pre- and post-guard times

Offline commands supported are:

•ata causes the modem to go offhook and answer
It is not necessary to use this command, since the test fixture will automatically answer two seconds after the first ring•atd sets the number to dial string
When this string is set to the nonempty condition, the soft modem dials that number in the string and attempts a connection. (A production program interfacing to the soft modem would simply set this string to effect a dialed connection from the soft modem.)

•ati issues the modem test fixture model and version number

•atq1 puts the AT command set into quiet mode, where it operates without responding

•atq0 undoes the atq1 command

•atz performs a soft reset of the soft modem, which hangs up the phone and frees RAM resources

•at+0 puts the modem into V.21 mode, where it will attempt to force all subsequent connections; a modem soft reset is also performed

•at+2 puts the modem into V.22/V.22bis mode, where the modem will attempt to force all subsequent connections; a modem soft reset is also performed

Modem Test Set-up
Modem Test Set-up

A standard off-the-shelf Freescale 56F8357EVM was used for this project. The Low-Cost Freescale Modem Demonstration Kit comes with a 56F8367EVM and a Low-Cost Modem Daughter Card (LCMDC) in one box. The EVM has a connector for this daughter card. The LCMDC was developed to house the Data Access Arrangement (DAA) as well as conditioning circuits for the single PWM signal from the EVM mother board.

To assemble the modem, snap the daughter card into the connector after making the following revisions to the EVM:

•To wire ring signal for detection by the controller, connect these two signals:

  • PWMA 1 (Pin 2, J7) source is ring indicator from the daughter card—Quadrature Decoder 0, PHASEA0 (Pin 1, J15) destination

•To wire flow control of data from serial test device to the controller, connect these two signals and a capacitor:

  • SCI 1 TXD1 (Pin 1, J14) source
  • RTS (Pin 1, J11) destination
  • One end of a 39pF cap to RTS, the other end to ground

•Clip pins 3, 4, 5, 6 of J8 to provide clearance for the DAA high voltage section of the daughter card

The first connection connects the ring signal from the DAA to a counter, enabling ring detection functionality. The second connection connects a GPIO for flow control. To avoid noise-induced glitches on the flow control signal, a small capacitor (39pF) should connect the RTS signal to ground.The Low-Cost Freescale Modem Demonstration Kit, available for evaluation upon reservation, contains an EVM factory modified as specified previously. The kit also includes documentation, as well as the LCMDC and required cables.

The modem is fully capable of error-free operation over average telephone lines in the USA. Limitations to performance are inherent in the limited dynamic range of the AGC. If desired, such limitation may be overcome by the addition of a hardware AGC circuit, since the amplitude variation of a land line telephone circuit over time is not dramatic.

Code Example. Routine File Transfer Testing

/ad,s03=1,s07=1,c3/
/exch,bal=1/
/file:cseq=usa1/
/io,i-100,l-230,r-100,t-230/
/ad,i3/
/gd,w17,x00,y16,z00/
/rn,l320,s1/
/nl,q520,c500,m0,x1,y1/
/fs,f+1250,m0,s1/
/pj,l0364,f1200,w0,s1/

Read the Italian version: Come progettare un Soft Modem utilizzando un controller di segnali digitali Freescale

Source: A Low-Cost Soft Modem using the Freescale Digital Signal Controller

CONTACT REQUEST
If you want to know more about this Freescale product, please submit your request to Arrow Italy using this form.

NOTE: this form is valid ONLY for Companies or Customers based in Italy and working in the Italian area.

http://dev.emcelettronica.com

Tidak ada komentar:

Posting Komentar