-
Notifications
You must be signed in to change notification settings - Fork 133
/
wspr.h
30 lines (21 loc) · 1 KB
/
wspr.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
/* Functions for wspr encoding
F8CHK 29/03/2011 */
#ifndef __WSPR_H
#define __WSPR_H
void Code_msg(char[], unsigned long int*, unsigned long int*); // encode callsign, locator and power
void Pack_msg(unsigned long int, unsigned long int, unsigned char[]);// packed 50 bits in 11 bytes
void Generate_parity(unsigned char[], unsigned char[]); // generate 162 parity bits
void Interleave( unsigned char[], unsigned char[]); // interleave the 162 parity bits
void Synchronise(unsigned char[], unsigned char[]); // synchronize with a pseudo random pattern
void code_wspr(char* wspr_message, unsigned char* wspr_symbol); // encode the wspr message
void go_wspr(void); // start WSPR beacon mode
void go_wspr_tx(void); // set cube in wspr tx mode
#define WSPR_OFFSET 1.4648 // tone separation
#define POLYNOM_1 0xf2d05351 // polynoms for
#define POLYNOM_2 0xe4613c47 // parity generator
typedef struct tuning_data {
double requested;
unsigned long tuning_word;
double actual;
} tuning_data;
#endif