I'm using WLS 1-14 and Axon II and I can't get the push button to work on the Axon II.
Below is the my code and you can see that every second I'm outputting "Hello World!" to the standard out which does exactly that.
However, when I press the button on the Axon II, it's not recognizing any action because I'm not getting any of the output that is programmed in any of the "if" statements.
Does anybody know what my problem might be?
TICK_COUNT appControl(LOOP_COUNT loopCount, TICK_COUNT loopStart)
{
TICK_COUNT delta, now;
static TICK_COUNT last = 0;
now = clockGetus();
delta = now - last;
if (delta > 1000000) // 1.0 second
{
cout << "Hello World!\n";
last = now;
}
if (button.isPressed())
{
cout << "Pressed\n";
}
if (button.isReleased())
{
cout << "Released\n";
}
if (button.isDepressed())
{
cout << "Depressed\n";
}
if (button.isWorking())
{
cout << "Working\n";
}
if (button.isChanged())
{
cout << "Changed\n";
}
return 0;
}