SubGhz: support for custom frequencies for SubGhz (#1108)

* SubGhz: add load setting
* SubGhz: add support file upload with custom frequencies
* SubGhz: add load region setting
* SubGhz: fix syntax
* SubGhz: fix furi_halt error
* Desktop: hide dolphin controls in production build
* Notification: fix crash on NotificationMessageTypeLedDisplayUnlock message

Co-authored-by: あく <alleteam@gmail.com>
This commit is contained in:
Skorpionm
2022-04-14 18:05:40 +04:00
committed by GitHub
parent 8cc3fd579c
commit a5cc3453c8
15 changed files with 511 additions and 109 deletions

View File

@@ -514,9 +514,9 @@ void subghz_hopper_update(SubGhz* subghz) {
} else {
subghz->txrx->hopper_state = SubGhzHopperStateRunnig;
}
// Select next frequency
if(subghz->txrx->hopper_idx_frequency < subghz_hopper_frequencies_count - 1) {
if(subghz->txrx->hopper_idx_frequency <
subghz_setting_get_hopper_frequency_count(subghz->setting) - 1) {
subghz->txrx->hopper_idx_frequency++;
} else {
subghz->txrx->hopper_idx_frequency = 0;
@@ -527,7 +527,8 @@ void subghz_hopper_update(SubGhz* subghz) {
};
if(subghz->txrx->txrx_state == SubGhzTxRxStateIDLE) {
subghz_receiver_reset(subghz->txrx->receiver);
subghz->txrx->frequency = subghz_hopper_frequencies[subghz->txrx->hopper_idx_frequency];
subghz->txrx->frequency = subghz_setting_get_hopper_frequency(
subghz->setting, subghz->txrx->hopper_idx_frequency);
subghz_rx(subghz, subghz->txrx->frequency);
}
}