Code: Select all
case INPUTTING_STOP_BIT:
int level_test = p_rxd.input();
if (level_test == 0) {
p_rxd.event_when_pins_eq(1);
state = WAITING_FOR_HIGH;
}
stop_bit_count--;
t += bit_time;
if (stop_bit_count == 0) {
p_rxd.event_when_pins_eq(0);
state = WAITING_FOR_INPUT;
}
break;
}
break;
It causes the problem in the case that there is just single one to zero (start bit) transition at the input which causes library to read bits until zero to one transition.
Is it intended?
wbr
malo