We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
How to simulate this kind of code ?
bool bp_on; void setup() { pinMode(3, INPUT); } void loop() { bp_on = digitalRead(3); }
Currently, it just displays:
pinMode pin 3 set to : INPU pinMode pin 4 set to : INPU
But no interaction possible to simulate button pressed.
By the way, typo at https://github.com/marcmerlin/ArduinoOnPc-FastLED-GFX-LEDMatrix/blob/master/src/cores/arduino/wiring_digital.cpp#L19 should be INPUT (no INPU).
Full ino code:
bool bp_on; // variable associee au bouton poussoire on bool bp_off; // variable associee au bouton poussoire off enum Etat { MARCHE, ARRET }; // Declaration des etats possibles Etat etatCourant; // variable associee à l'etat courant void setup() { pinMode(3, INPUT); // La pin 3 est definie comme une entree (bouton poussoire) pinMode(4, INPUT); // La pin 4 est definie comme une entree (bouton poussoire) etatCourant = MARCHE; // Etat initial } void loop() { // Mise a jour des entrees bp_on = digitalRead(3); bp_off = digitalRead(4); // Gestion de l'evolution des etats switch (etatCourant) { case MARCHE: // Action etat Marche //... // Transition vers l'etat ARRET if (bp_off) { etatCourant = ARRET; } break; case ARRET : // Action etat Arret //... //Transition vers l'etat MARCHE if (bp_on) { etatCourant = MARCHE; } break; } }
The text was updated successfully, but these errors were encountered:
Good question, this part of the code I did not write and I don't use, it was forked from https://github.com/ChrisMicro/ArduinoOnPc I suggest you ask file the issue in https://github.com/ChrisMicro/ArduinoOnPc , sorry that I can't help with this
Sorry, something went wrong.
No branches or pull requests
How to simulate this kind of code ?
Currently, it just displays:
But no interaction possible to simulate button pressed.
By the way, typo at https://github.com/marcmerlin/ArduinoOnPc-FastLED-GFX-LEDMatrix/blob/master/src/cores/arduino/wiring_digital.cpp#L19 should be INPUT (no INPU).
Full ino code:
The text was updated successfully, but these errors were encountered: