Skip to content
radio.h 788 B
Newer Older
natsfr's avatar
natsfr committed
/*
 * radio.h
 *
 *  Created on: 3 Jul 2018
 *      Author: nats
 */

#ifndef RADIO_H_
#define RADIO_H_

#define OUTDIV 24
#define BAND 5
#define FREQ 144800000
#define FCINT 65
#define FCFRACT 959850

#define PART_INFO 0x01
#define POWER_UP 0x02
#define SET_PROPERTY 0x11
#define GET_PROPERTY 0x12
#define GET_CHIP_STATUS 0x23
#define START_TX 0x31
#define START_RX 0x32
#define READ_CMD_BUFF 0x44

/* 35: 15dBm | 20: 10dBm | 10: 5dBm | 7: 0dBm */
#define POWER_LEVEL 127
#define CLK_DUTY_LOW 3<<6
#define CLK_DUTY_HIGH 2<<6

#define GLOBAL_XO_TUNE 0x0000

#define GLOBAL_CONFIG 0x0003
#define PREAMBLE_TX_LENGTH 0x1000
#define PREAMBLE_CONFIG 0x1004
#define SYNC_CONFIG 0x1100
#define MODEM_MOD_TYPE 0x2000
#define MODEM_CLKGEN_BAND 0x2051
#define PA_MODE 0x2200

#endif /* RADIO_H_ */