subghz - fix check, fix typos

temporarily replace with internal check, commented code in function added TODO comment
This commit is contained in:
MX
2023-08-17 03:01:40 +03:00
parent e892c977f3
commit fec80da3f4
7 changed files with 21 additions and 15 deletions

View File

@@ -115,14 +115,15 @@ bool subghz_key_load(SubGhz* subghz, const char* file_path, bool show_dialog) {
break;
}
if(!subghz_txrx_radio_device_is_frequecy_valid(subghz->txrx, temp_data32)) {
if(!subghz_txrx_radio_device_is_frequency_valid(subghz->txrx, temp_data32)) {
FURI_LOG_E(TAG, "Frequency not supported on chosen radio module");
load_key_state = SubGhzLoadKeyStateUnsuportedFreq;
break;
}
if(!subghz_txrx_radio_device_is_tx_alowed(subghz->txrx, temp_data32)) {
FURI_LOG_E(TAG, "This frequency can only be used for RX on chosen radio module");
// TODO: use different frequency allowed lists for differnet modules (non cc1101)
if(!furi_hal_subghz_is_tx_allowed(temp_data32)) {
FURI_LOG_E(TAG, "This frequency can only be used for RX");
load_key_state = SubGhzLoadKeyStateOnlyRx;
break;
}