m0zah/GB3TX/repeater.h
Jim Colderwood 8c790fa4e0 GB3TX
2024-04-01 18:21:09 +01:00

62 lines
837 B
C

#ifndef REPEATER_H
#define REPEATER_H
typedef enum {
SLEEP,
IDLE,
KEYCHUNK,
HANG,
GW,
TT,
TOT,
}state;
typedef enum {
TONE,
CW,
}c_type;
typedef struct {
c_type courtesy;
int cw_pitch;
int cw_speed;
int pip_length;
char pip_letter;
int pip_pitch;
int pip_speed;
int pip_gw_length;
char pip_gw_letter;
int pip_gw_pitch;
}params;
typedef struct {
bool tx;
unsigned long long tx_time;
}transmitter;
typedef struct {
int id;
bool rx;
unsigned long long rx_time;
}receiver;
typedef struct {
bool enable;
receiver receiver;
transmitter transmitter;
}gateway;
typedef struct {
char* callsign;
int cw_pitch;
gateway gateway;
int hangtime;
unsigned long id_time;
state last;
params params;
receiver receiver;
state state;
transmitter transmitter;
}repeater;
#endif