Reduce duration of initial sweeps

pull/4/head
erikkaashoek 6 years ago
parent 46616a6ce7
commit 27eaa8f4b3

@ -2704,13 +2704,15 @@ int main(void)
// menu_mode_cb(setting.mode,0); // menu_mode_cb(setting.mode,0);
// } // }
redraw_frame(); redraw_frame();
set_mode(M_HIGH); set_mode(M_HIGH);
set_sweep_frequency(ST_STOP, (uint32_t) 30000000);
sweep(true); sweep(true);
osalThreadSleepMilliseconds(100); osalThreadSleepMilliseconds(100);
set_mode(M_LOW); set_mode(M_LOW);
set_sweep_frequency(ST_STOP, (uint32_t) 4000000);
sweep(true); sweep(true);
set_sweep_frequency(ST_STOP, (uint32_t) 35000000);
set_refer_output(-1); set_refer_output(-1);
// ui_mode_menu(); // Show menu when autostarting mode // ui_mode_menu(); // Show menu when autostarting mode

@ -192,7 +192,7 @@ void SI4432_Transmit(int d)
SI4432_Write_Byte( 0x07, 0x02); SI4432_Write_Byte( 0x07, 0x02);
chThdSleepMilliseconds(20); chThdSleepMilliseconds(20);
SI4432_Write_Byte( 0x07, 0x0b); SI4432_Write_Byte( 0x07, 0x0b);
chThdSleepMilliseconds(30); chThdSleepMilliseconds(100);
while (count++ < 100 && ( SI4432_Read_Byte ( 0x02 ) & 0x03 ) != 2) { while (count++ < 100 && ( SI4432_Read_Byte ( 0x02 ) & 0x03 ) != 2) {
chThdSleepMilliseconds(10); chThdSleepMilliseconds(10);
} }
@ -207,7 +207,7 @@ void SI4432_Receive(void)
SI4432_Write_Byte( 0x07, 0x02); SI4432_Write_Byte( 0x07, 0x02);
chThdSleepMilliseconds(20); chThdSleepMilliseconds(20);
SI4432_Write_Byte( 0x07, 0x07); SI4432_Write_Byte( 0x07, 0x07);
chThdSleepMilliseconds(30); chThdSleepMilliseconds(100);
while (count++ < 100 && ( SI4432_Read_Byte ( 0x02 ) & 0x03 ) != 1) { while (count++ < 100 && ( SI4432_Read_Byte ( 0x02 ) & 0x03 ) != 1) {
chThdSleepMilliseconds(5); chThdSleepMilliseconds(5);
} }

Loading…
Cancel
Save

Powered by TurnKey Linux.