bug fix 0.26_2

beta0.26
phdlee 5 years ago
parent b9b8f4b46f
commit 924db221f4
  1. 28
      ubitx_20/ubitx_20.ino
  2. 50
      ubitx_20/ubitx_menu.ino

@ -327,7 +327,7 @@ void setNextHamBandFreq(unsigned long f, char moveDirection)
byteWithFreqToMode(loadMode);
}
void saveBandFreqByIndex(unsigned long f, unsigned long mode, byte bandIndex) {
void saveBandFreqByIndex(unsigned long f, unsigned long mode, char bandIndex) {
if (bandIndex >= 0)
EEPROM.put(HAM_BAND_FREQS + 4 * bandIndex, (f & 0x3FFFFFFF) | (mode << 30) );
}
@ -739,7 +739,7 @@ void initSettings(){
EEPROM.get(TX_TUNE_TYPE, tuneTXType);
if ((3 < tuneTXType && 100 < tuneTXType) || 103 < tuneTXType || useHamBandCount < 1)
if ((3 < tuneTXType && tuneTXType < 100) || 103 < tuneTXType || useHamBandCount < 1)
tuneTXType = 0;
//Read band Information
@ -843,37 +843,23 @@ void setup()
*/
//Serial.begin(9600);
delay(100);
lcd.begin(16, 2);
printLineF(1, F("CECBT v0.27"));
//remark for John test
Init_Cat(38400, SERIAL_8N1);
initMeter(); //not used in this build
initSettings();
printLineF(1, F("CECBT v0.263"));
if (userCallsignLength > 0 && ((userCallsignLength & 0x80) == 0x80))
{
if (userCallsignLength > 0 && ((userCallsignLength & 0x80) == 0x80)) {
userCallsignLength = userCallsignLength & 0x7F;
printLineFromEEPRom(0, 0, 0, userCallsignLength -1); //eeprom to lcd use offset (USER_CALLSIGN_DAT)
delay(500);
}
else
{
else {
printLineF(0, F("uBITX v0.20"));
delay(500); //< -- replace from delay_background(500, 0) //johns bug report / on raspberry
delay(500);
printLine2("");
}
//replace above to below (before initSettings(); position)
/*
printLine2("CECBT v0.27");
printLine1("uBITX v0.20");
delay(500);
printLine2("");
Init_Cat(9600, SERIAL_8N1);
initMeter(); //not used in this build
initSettings();
*/
initPorts();
initOscillators();

@ -38,17 +38,19 @@ int menuBand(int btn){
tuneTXType = 2;
//if empty band Information, auto insert default region 1 frequency range
//This part is made temporary for people who have difficulty setting up, so can remove it when you run out of memory.
useHamBandCount = 10;
hamBandRange[0][0] = 1810; hamBandRange[0][1] = 2000;
hamBandRange[1][0] = 3500; hamBandRange[1][1] = 3800;
hamBandRange[2][0] = 5351; hamBandRange[2][1] = 5367;
hamBandRange[3][0] = 7000; hamBandRange[3][1] = 7200;
hamBandRange[4][0] = 10100; hamBandRange[4][1] = 10150;
hamBandRange[5][0] = 14000; hamBandRange[5][1] = 14350;
hamBandRange[6][0] = 18068; hamBandRange[6][1] = 18168;
hamBandRange[7][0] = 21000; hamBandRange[7][1] = 21450;
hamBandRange[8][0] = 24890; hamBandRange[8][1] = 24990;
hamBandRange[9][0] = 28000; hamBandRange[9][1] = 29700;
if (useHamBandCount < 1) {
useHamBandCount = 10;
hamBandRange[0][0] = 1810; hamBandRange[0][1] = 2000;
hamBandRange[1][0] = 3500; hamBandRange[1][1] = 3800;
hamBandRange[2][0] = 5351; hamBandRange[2][1] = 5367;
hamBandRange[3][0] = 7000; hamBandRange[3][1] = 7200;
hamBandRange[4][0] = 10100; hamBandRange[4][1] = 10150;
hamBandRange[5][0] = 14000; hamBandRange[5][1] = 14350;
hamBandRange[6][0] = 18068; hamBandRange[6][1] = 18168;
hamBandRange[7][0] = 21000; hamBandRange[7][1] = 21450;
hamBandRange[8][0] = 24890; hamBandRange[8][1] = 24990;
hamBandRange[9][0] = 28000; hamBandRange[9][1] = 29700;
}
printLineF2(F("Ham band mode"));
}
delay_background(1000, 0);
@ -57,7 +59,7 @@ int menuBand(int btn){
}
}
byte currentBandIndex = -1;
char currentBandIndex = -1;
//Save Band Information
if (tuneTXType == 2 || tuneTXType == 3 || tuneTXType == 102 || tuneTXType == 103) { //only ham band move
//Get Now Band Index
@ -263,30 +265,6 @@ void menuTxOnOff(int btn, byte optionType){
}
}
/*
void menuSplitOnOff(int btn){
if (!btn){
if ((isTxType & 0x02) == 0)
printLineF2(F("Split OFF?"));
else
printLineF2(F("Split ON?"));
}
else {
if ((isTxType & 0x02) == 0){
isTxType |= 0x02;
printLineF2(F("Split OFF!"));
}
else {
isTxType &= ~(0x02);
printLineF2(F("Split ON!"));
}
delay_background(500, 0);
printLine2ClearAndUpdate();
menuOn = 0;
}
}
*/
/**
* The calibration routines are not normally shown in the menu as they are rarely used
* They can be enabled by choosing this menu option

Loading…
Cancel
Save