Prosody data communications Protocols: FSK rx

FSK is 'frequency shift keying' which is a method of transmitting data using tones. Binary data is encoded by sending one of two tones for each bit, with one tone used for zero bits and another for one bits.

This protocol implements the receiver for FSK. Since it is only a receiver, it only uses the input half of a channel. Typically the output half is configured for FSK tx.

API function behaviour

This should be read in conjunction with the generic data communications documentation.

smdc_channel_config()

You must use #include "smdc_fsk.h" to get the appropriate declarations.

The protocol value is kSMDCProtocolFSKrx.

The config_data pointer must point to one of these structs:

	typedef struct smdc_fsk_config_parms {
		unsigned long speed;
		float mark_frequency;
		float space_frequency;
		unsigned long rx_carrier_on_mS;
		unsigned long rx_carrier_off_mS;
		unsigned long set_power;
		float user_power;
	} SMDC_FSK_CONFIG_PARMS;

'speed' is the data rate in bits per second.

'mark_frequency' is the frequency, in Hz, of the tone used to encode mark ('1') bits.

'space_frequency' is the frequency, in Hz, of the tone used to encode space ('0') bits.

'rx_carrier_on_mS' is the minimum duration of carrier (in milliseconds) that should be recognised as valid.

'rx_carrier_off_mS' is the maximum duration of loss of carrier (in milliseconds) that will be tolerated before deciding that the carrier has gone.

'set_power' is not used and applies only to FSK transmission.

'user_power' is the is not used and applies only to FSK transmission.

This table shows values of these parameters for some standard FSK modems:

Standard speed mark space on_mS off_mS
V.21 Channel 1 300 980 1180 20..700 20..80
V.21 Channel 2 300 1650 1850 20..700 20..80
Bell 103 answering 300 1270 1070 ? ?
Bell 103 originating 300 2225 2025 ? ?
V.23 mode 2 1200 1300 2100 10..700 5..15
V.23 mode 1 600 1300 1700 10..700 5..15
V.23 back 75 390 450 0..80 15..80
Bell 202 1200 1200 2200 ? ?
Bell 202 back 75, 110, to 150 387 487 ? ?
V.18 Annex A 50 1400 1800 1 80

Note that for full duplex operation, V.21 channel 1 is the one used from the originator to the answering end, and channel 2 is used for the reverse direction. For half duplex, channel 2 is not used (at least, that's what the V.21 standard says, but fax machines complying with the T.30 standard use only channel 2).

There is also an alternative Bell 202 back channel which runs at 5 bps, but this uses a single carrier frequency of 387 Hz representing mark (1), with space (0) represented by no signal (so it's actually a continuous wave modem, not FSK).

This protocol can use these encodings: SYNC, ASYNC, and HDLC. Note that when using ASYNC encoding, the firmware module fskasyrx is used instead of asyrx, and when SYNC or HDLC encodings are used the firmware module fskpll is required in addition to the encoding module. Note that since an FSK signal contains no clock information, if SYNC or HDLC encodings are used, the data must contain enough transitions between the frequencies (i.e. no long runs of only zeros or only ones) to allow the receiver to keep locked onto the bit rate.

The firmware modules fskrx and inchan must have been downloaded.

smdc_line_control()

[note] not useful - receiver is always connected

smdc_line_status()

smdc_tx_status()

This function is not applicable since it only applies to the output half of a channel.

smdc_tx_control()

This function is not applicable since it only applies to the output half of a channel.

smdc_rx_status()

smdc_rx_control()

smdc_rx_data()

smdc_tx_data()

This function is not applicable since it only applies to the output half of a channel.