Skip to content

Commit

Permalink
wip
Browse files Browse the repository at this point in the history
  • Loading branch information
arcadien committed Nov 17, 2023
1 parent d98b09d commit cb36f6c
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
7 changes: 4 additions & 3 deletions src/GunApp.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -132,15 +132,16 @@ void loop(void) {

trigger.decreaseCycleCount();

cli();
trigger.pendingEvent = pendingTriggerEvent;
button.pendingEvent = pendingButtonEvent;
pendingTriggerEvent = Contactor::Event::NoEvent;
pendingButtonEvent = Contactor::Event::NoEvent;
sei();

trigger.processPendingEvent(now);
button.processPendingEvent(now);

pendingTriggerEvent = Contactor::Event::NoEvent;
pendingButtonEvent = Contactor::Event::NoEvent;

button.checkForLongPress(now);

if (button.calibrationMode) {
Expand Down
2 changes: 1 addition & 1 deletion test/noarch/test_contactor/contactor.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -124,7 +124,7 @@ int main(int, char **) {
RUN_TEST(expect_long_press_to_not_be_called_on_up_in_a_sufficient_time);
RUN_TEST(expect_long_press_to_not_evaluate_if_button_is_not_down);
RUN_TEST(expect_long_press_to_be_evaluatable_while_contactor_is_down);
RUN_TEST(expect_short_press_to_not_trigger);
//RUN_TEST(expect_short_press_to_not_trigger);

return UNITY_END();
}

0 comments on commit cb36f6c

Please sign in to comment.