66 lines
1.9 KiB
C
66 lines
1.9 KiB
C
/*
|
|
Configuration file for Nextion LCD and Control MCU
|
|
The parameter can be set according to the CPU used.
|
|
|
|
KD8CEC, Ian Lee
|
|
-----------------------------------------------------------------------
|
|
|
|
**********************************************************************/
|
|
|
|
#include <Arduino.h>
|
|
#include "Debug.h"
|
|
#include "DSP.h"
|
|
#include "Nextion.h"
|
|
#include "Sensors.h"
|
|
#include "TR.h"
|
|
|
|
//================================================================
|
|
//COMMUNICATION SECTION
|
|
//================================================================
|
|
|
|
//================================================================
|
|
// FFT and Decode Morse
|
|
//================================================================
|
|
|
|
#define FFTSIZE 64
|
|
#define SAMPLE_FREQUENCY 6000
|
|
#define SAMPLESIZE (FFTSIZE * 2)
|
|
#define DECODE_MORSE_SAMPLESIZE 48
|
|
|
|
extern uint8_t cwDecodeHz;
|
|
extern int magnitudelimit_low;
|
|
|
|
//================================================================
|
|
// EEPROM Section
|
|
//================================================================
|
|
|
|
#define MAX_FORWARD_BUFF_LENGTH 128
|
|
#define EEPROM_DSPTYPE 100
|
|
#define EEPROM_SMETER_UART 111
|
|
#define EEPROM_SMETER_TIME 112
|
|
|
|
#define EEPROM_CW_FREQ 120
|
|
//#define EEPROM_CW_MAG_LIMIT 121
|
|
#define EEPROM_CW_MAG_LOW 122
|
|
#define EEPROM_CW_NBTIME 126
|
|
#define EEPROM_RTTYDECODEHZ 130
|
|
|
|
//================================================================
|
|
// DEFINE for I2C Command
|
|
//================================================================
|
|
|
|
//S-Meter Address
|
|
#define I2CMETER_ADDR 0x58 //changed from 0x6A
|
|
//VALUE TYPE============================================
|
|
//Signal
|
|
#define I2CMETER_CALCS 0x59 //Calculated Signal Meter
|
|
#define I2CMETER_UNCALCS 0x58 //Uncalculated Signal Meter
|
|
|
|
//Power
|
|
#define I2CMETER_CALCP 0x57 //Calculated Power Meter
|
|
#define I2CMETER_UNCALCP 0x56 //UnCalculated Power Meter
|
|
|
|
//SWR
|
|
#define I2CMETER_CALCR 0x55 //Calculated SWR Meter
|
|
#define I2CMETER_UNCALCR 0x54 //Uncalculated SWR Meter
|