Skip to content

Commit

Permalink
Fix UART unlisten calls so they clear the interrupt enable bit instea…
Browse files Browse the repository at this point in the history
…d of setting it
  • Loading branch information
raiker committed Nov 13, 2022
1 parent 86049a5 commit 5523a7b
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions esp-hal-common/src/serial.rs
Original file line number Diff line number Diff line change
Expand Up @@ -361,7 +361,7 @@ where
self.uart
.register_block()
.int_ena
.modify(|_, w| w.at_cmd_char_det_int_ena().set_bit());
.modify(|_, w| w.at_cmd_char_det_int_ena().clear_bit());
}

/// Listen for TX-DONE interrupts
Expand All @@ -377,7 +377,7 @@ where
self.uart
.register_block()
.int_ena
.modify(|_, w| w.tx_done_int_ena().set_bit());
.modify(|_, w| w.tx_done_int_ena().clear_bit());
}

/// Listen for RX-FIFO-FULL interrupts
Expand All @@ -393,7 +393,7 @@ where
self.uart
.register_block()
.int_ena
.modify(|_, w| w.rxfifo_full_int_ena().set_bit());
.modify(|_, w| w.rxfifo_full_int_ena().clear_bit());
}

/// Checks if AT-CMD interrupt is set
Expand Down

0 comments on commit 5523a7b

Please sign in to comment.