PSK 31 modulator

PSK-31 waveform and data stream modulator. More...


Defines

#define PSK_MAX_PACKET   160
 The maximum ASCII length of a PSK 31 message.
#define PSK31_TIMESLOT   0
 The UTC time in seconds to send a PSK31 data stream.
#define PSK_SYNC_LENGTH   32
 Number of 0 bits to transmit at start of message.
#define PSK_END_LENGTH   8
 Number of 0 bits to transmit at end of message.

Enumerations

enum  PSK_MODE { PSK_WAIT_MSG, PSK_TX_SYNC, PSK_TX_MESSAGE, PSK_TX_END }
 PSK-31 state machine. More...

Functions

bool_t psk31CreateDataPacket ()
 Create the PSK 31 packet.
void psk31Init ()
 Initialize the PSK 31 modulator.
bool_t psk31IsFree ()
 Determine if the hardware if ready to a PSK 31 packet.
void psk31TimeUpdate ()
 This method should be called every 1 milliseconds by the timer interrupt.
void psk31TxPacket (uint8_t minutes)
 Generate and start transmision of PSK-31 message.
void psk31TxByte (uint8_t value)
 Write value to the PSK 31 buffer.
void psk31TxString (char *string, uint8_t length)
 Write length characters of string.
void psk31TxNull ()
bool_t psk31IsMessageDone ()

Variables

const uint16_t PSK31_VARICODE []
const uint32_t PSK31_FREQ_LIST [] = { 14070450, 14070450, 14070450 }
 PSK 31 frequency and amplitude list for minutes 0 through 2 modulo 2.
const uint16_t PSK31_AMP_LIST [] = { 105, 105, 105 }
uint8_t pskCount
 Counts the number of 1mS time slices in each 32mS of a bit time.
uint16_t pskData
 The current PSK output character.
bool_t pskPhase
 The current DDS phase offset where true is 180 degreees and false is 0 degrees.
char pskBuffer [PSK_MAX_PACKET]
 Buffer that holds PSK packet.
PSK_MODE pskMode
 State machine variable that indicates current transmit state.
uint8_t pskLastBits
 Last 4 bits that were transmitted.
uint8_t pskIndex
 Index into the PSK packet buffer.
bool_t pskMessageDoneFlag
 Flag that is set when PSK-31 message is completed.


Detailed Description

PSK-31 waveform and data stream modulator.

Define Documentation

#define PSK31_TIMESLOT   0

The UTC time in seconds to send a PSK31 data stream.

Referenced by main().

#define PSK_END_LENGTH   8

Number of 0 bits to transmit at end of message.

Referenced by psk31TimeUpdate().

#define PSK_MAX_PACKET   160

The maximum ASCII length of a PSK 31 message.

Referenced by psk31TxByte().

#define PSK_SYNC_LENGTH   32

Number of 0 bits to transmit at start of message.

Referenced by psk31TxPacket().


Enumeration Type Documentation

enum PSK_MODE

PSK-31 state machine.

Enumerator:
PSK_WAIT_MSG  Ready to accept a new message.
PSK_TX_SYNC  Send the sync pattern at the start of the message. This is typically 200-300mS.
PSK_TX_MESSAGE  Send the text message data.
PSK_TX_END  Send the end sequence.


Function Documentation

bool_t psk31CreateDataPacket (  ) 

Create the PSK 31 packet.

References ballastGetPumpCount(), cutDownIsActivate(), gpsPosition, lm92GetTemp(), LOG_TEMPERATURE_1, logInt16(), logType(), psk31TxByte(), and psk31TxNull().

Referenced by psk31TxPacket().

Here is the call graph for this function:

void psk31Init (  ) 

Initialize the PSK 31 modulator.

References PSK_WAIT_MSG, pskCount, pskData, pskIndex, pskLastBits, pskMessageDoneFlag, pskMode, and pskPhase.

Referenced by main().

bool_t psk31IsFree (  ) 

Determine if the hardware if ready to a PSK 31 packet.

Returns:
true if ready; otherwise false

References PSK_WAIT_MSG, and pskMode.

Referenced by tncTxPacket().

bool_t psk31IsMessageDone (  ) 

References pskMessageDoneFlag.

Referenced by main().

void psk31TimeUpdate (  ) 

This method should be called every 1 milliseconds by the timer interrupt.

References DDS_MODE_POWERDOWN, ddsPhase(), ddsSetMode(), IO_OSK, logSetDisableFlag(), PSK31_VARICODE, PSK_END_LENGTH, PSK_TX_END, PSK_TX_MESSAGE, PSK_TX_SYNC, PSK_WAIT_MSG, pskBuffer, pskCount, pskData, pskIndex, pskLastBits, pskMessageDoneFlag, pskMode, pskPhase, and sysPAOutput().

Referenced by timeUpdate().

Here is the call graph for this function:

void psk31TxByte ( uint8_t  value  ) 

Write value to the PSK 31 buffer.

Maintain the pointer to the buffer. The value pskIndex must be set to 0 (zero) before calling this function for the first time.

Parameters:
value to save to telemetry buffer

References PSK_MAX_PACKET, pskBuffer, and pskIndex.

Referenced by psk31CreateDataPacket(), psk31TxNull(), psk31TxPacket(), and psk31TxString().

void psk31TxNull (  ) 

References psk31TxByte().

Referenced by psk31CreateDataPacket(), and psk31TxPacket().

Here is the call graph for this function:

void psk31TxPacket ( uint8_t  minutes  ) 

Generate and start transmision of PSK-31 message.

If a message is already being transmitted, nothing occurs. The UTC time in minutes is required to set the DDS frequency.

Parameters:
minutes UTC time in minutes

References DDS_MODE_PSK31, ddsSetAmplitude(), ddsSetFreq(), ddsSetMode(), logSetDisableFlag(), PSK31_AMP_LIST, PSK31_FREQ_LIST, psk31CreateDataPacket(), psk31TxByte(), psk31TxNull(), PSK_SYNC_LENGTH, PSK_TX_SYNC, PSK_WAIT_MSG, pskCount, pskData, pskIndex, pskMode, sysPAOutput(), TIME_MODE_PSK31, timeSetMode(), and tncIsFree().

Referenced by main().

Here is the call graph for this function:

void psk31TxString ( char *  string,
uint8_t  length 
)

Write length characters of string.

References psk31TxByte().

Here is the call graph for this function:


Variable Documentation

const uint16_t PSK31_AMP_LIST[] = { 105, 105, 105 }

Referenced by psk31TxPacket().

const uint32_t PSK31_FREQ_LIST[] = { 14070450, 14070450, 14070450 }

PSK 31 frequency and amplitude list for minutes 0 through 2 modulo 2.

Referenced by psk31TxPacket().

Referenced by psk31TimeUpdate().

char pskBuffer[PSK_MAX_PACKET]

Buffer that holds PSK packet.

Referenced by psk31TimeUpdate(), and psk31TxByte().

Counts the number of 1mS time slices in each 32mS of a bit time.

Referenced by psk31Init(), psk31TimeUpdate(), and psk31TxPacket().

The current PSK output character.

Referenced by psk31Init(), psk31TimeUpdate(), and psk31TxPacket().

Index into the PSK packet buffer.

Referenced by psk31Init(), psk31TimeUpdate(), psk31TxByte(), and psk31TxPacket().

Last 4 bits that were transmitted.

Referenced by psk31Init(), and psk31TimeUpdate().

Flag that is set when PSK-31 message is completed.

Referenced by psk31Init(), psk31IsMessageDone(), and psk31TimeUpdate().

State machine variable that indicates current transmit state.

Referenced by psk31Init(), psk31IsFree(), psk31TimeUpdate(), and psk31TxPacket().

The current DDS phase offset where true is 180 degreees and false is 0 degrees.

Referenced by psk31Init(), and psk31TimeUpdate().


Generated on Sun Oct 5 11:29:37 2008 for HF-APRS Beacon by  doxygen 1.5.7