Skip to content

Commit

Permalink
[FL-2684, FL-2685] bugfix subghz (#1446)
Browse files Browse the repository at this point in the history
* [FL-2684] SubGhz: fix incorrect CAME TWICE protocol definition
* [FL-2685] SubGhz: fix the recorded RAW signal is deleted when trying to transmit on a prohibited frequency

Co-authored-by: あく <[email protected]>
  • Loading branch information
Skorpionm and skotopes authored Jul 26, 2022
1 parent 3fa5e18 commit ed7db33
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions applications/subghz/scenes/subghz_scene_read_raw.c
Original file line number Diff line number Diff line change
Expand Up @@ -202,6 +202,7 @@ bool subghz_scene_read_raw_on_event(void* context, SceneManagerEvent event) {
if((subghz->txrx->txrx_state == SubGhzTxRxStateIDLE) ||
(subghz->txrx->txrx_state == SubGhzTxRxStateSleep)) {
if(!subghz_tx_start(subghz, subghz->txrx->fff_data)) {
subghz->txrx->rx_key_state = SubGhzRxKeyStateBack;
scene_manager_next_scene(subghz->scene_manager, SubGhzSceneShowOnlyRx);
} else {
DOLPHIN_DEED(DolphinDeedSubGhzSend);
Expand Down
2 changes: 1 addition & 1 deletion lib/subghz/protocols/came_twee.c
Original file line number Diff line number Diff line change
Expand Up @@ -354,7 +354,7 @@ void subghz_protocol_decoder_came_twee_feed(void* context, bool level, uint32_t
} else if(
duration >= ((uint32_t)subghz_protocol_came_twee_const.te_long * 2 +
subghz_protocol_came_twee_const.te_delta)) {
if(instance->decoder.decode_count_bit >=
if(instance->decoder.decode_count_bit ==
subghz_protocol_came_twee_const.min_count_bit_for_found) {
instance->generic.data = instance->decoder.decode_data;
instance->generic.data_count_bit = instance->decoder.decode_count_bit;
Expand Down

0 comments on commit ed7db33

Please sign in to comment.