Skip to content

Commit

Permalink
quick and dirty fix for falling edges in type2 as i can't test this w…
Browse files Browse the repository at this point in the history
…ith an improved script like for type 1 as i don't have this device
  • Loading branch information
bemabalu committed Sep 4, 2024
1 parent 3914592 commit 4f892ab
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/type2/CollarRxType2.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -99,6 +99,7 @@ bool CollarRxType2::buffer_to_collar_message(const uint8_t buffer[5], struct col

void CollarRxType2::isr()
{
if (digitalRead(_rx_pin)==0) return; //quick and dirty don't check falling edges as interrupt is fired on signal change now
static unsigned long rx_micros =0;
static uint8_t pulse_count = 0;
delayMicroseconds(500); // BAD: really shouldn't do this in an ISR
Expand Down

0 comments on commit 4f892ab

Please sign in to comment.