BTN is not working

Discussion about Z-Uno product. Visit http://z-uno.z-wave.me for more details.
Post Reply
thisguy
Posts: 2
Joined: 28 Apr 2020 21:22

BTN is not working

Post by thisguy »

Hi all,

So I have tried a lot of different things, even bought a razberry just because I thought my uno was not compatible with my current controller.

It appears that the button does not work, the reset one does but the BTN does not. loading a simple sketch that would log the button being pressed shows nothing.

This also makes it impossible to include the device in anything.

It never worked and I believe my device might be faulty, can someone please verify?

Code: Select all

#define BTN_PIN     18
byte lastButtonState;

void setup() {
  Serial.begin(115200);
  pinMode(BTN_PIN, INPUT_PULLUP); // set button pin as input
}
void loop() {
  byte currenButtonState = digitalRead(BTN_PIN);
  Serial.println("");
      if (currenButtonState == LOW) { // if button is pressed
      Serial.print("LOW");
    } else {                        // if button is released
      Serial.print("HIGH");
    }
  delay(100);  
}

thisguy
Posts: 2
Joined: 28 Apr 2020 21:22

Re: BTN is not working

Post by thisguy »

Ok, so terminating both ends of the button with a male <-> male cord triggers a LOW so the button is actually broken, that sucks. guess return to store

User avatar
PoltoS
Posts: 5696
Joined: 26 Jan 2011 19:36

Re: BTN is not working

Post by PoltoS »

Unfortunatelly this happened few times due to the aggressive flux. Please swap it in the shop.

Post Reply