All strange time constants are now frequency multipliers (#834)

This commit is contained in:
Oleg Schwann 2021-11-22 21:49:57 +03:00 committed by GitHub
parent efded63bcb
commit 949079cb74
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
6 changed files with 7 additions and 7 deletions

View File

@ -35,10 +35,10 @@ static void bt_carrier_test_start(BtCarrierTest* bt_carrier_test) {
furi_assert(bt_carrier_test);
if(bt_carrier_test->mode == BtTestModeRx) {
furi_hal_bt_start_packet_rx(bt_carrier_test->channel, 1);
osTimerStart(bt_carrier_test->timer, 1024 / 4);
osTimerStart(bt_carrier_test->timer, osKernelGetTickFreq() / 4);
} else if(bt_carrier_test->mode == BtTestModeTxHopping) {
furi_hal_bt_start_tone_tx(bt_carrier_test->channel, bt_carrier_test->power);
osTimerStart(bt_carrier_test->timer, 2048);
osTimerStart(bt_carrier_test->timer, osKernelGetTickFreq() * 2);
} else if(bt_carrier_test->mode == BtTestModeTx) {
furi_hal_bt_start_tone_tx(bt_carrier_test->channel, bt_carrier_test->power);
}

View File

@ -31,7 +31,7 @@ static void bt_packet_test_start(BtPacketTest* bt_packet_test) {
furi_assert(bt_packet_test);
if(bt_packet_test->mode == BtTestModeRx) {
furi_hal_bt_start_packet_rx(bt_packet_test->channel, bt_packet_test->data_rate);
osTimerStart(bt_packet_test->timer, 1024 / 4);
osTimerStart(bt_packet_test->timer, osKernelGetTickFreq() / 4);
} else if(bt_packet_test->mode == BtTestModeTx) {
furi_hal_bt_start_packet_tx(bt_packet_test->channel, 1, bt_packet_test->data_rate);
}

View File

@ -49,7 +49,7 @@ int32_t blink_test_app(void* p) {
view_port_draw_callback_set(view_port, blink_test_draw_callback, NULL);
view_port_input_callback_set(view_port, blink_test_input_callback, event_queue);
osTimerId_t timer = osTimerNew(blink_test_update, osTimerPeriodic, event_queue, NULL);
osTimerStart(timer, 1000);
osTimerStart(timer, osKernelGetTickFreq());
// Register view port in GUI
Gui* gui = furi_record_open("gui");

View File

@ -21,7 +21,7 @@ void desktop_scene_locked_on_enter(void* context) {
desktop_locked_with_pin(desktop->locked_view, state == DesktopLockedWithPin);
view_port_enabled_set(desktop->lock_viewport, true);
osTimerStart(locked_view->timer, 63);
osTimerStart(locked_view->timer, osKernelGetTickFreq() / 16);
view_dispatcher_switch_to_view(desktop->view_dispatcher, DesktopViewLocked);
}

View File

@ -152,7 +152,7 @@ void subghz_test_carrier_enter(void* context) {
furi_hal_subghz_rx();
osTimerStart(subghz_test_carrier->timer, 1024 / 4);
osTimerStart(subghz_test_carrier->timer, osKernelGetTickFreq() / 4);
}
void subghz_test_carrier_exit(void* context) {

View File

@ -198,7 +198,7 @@ void subghz_test_packet_enter(void* context) {
furi_hal_subghz_start_async_rx(subghz_test_packet_rx_callback, instance);
osTimerStart(instance->timer, 1024 / 4);
osTimerStart(instance->timer, osKernelGetTickFreq() / 4);
}
void subghz_test_packet_exit(void* context) {