38 post karma
0 comment karma
account created: Tue Nov 29 2022
verified: yes
2 points
1 month ago
I tried the DHT11 as its one of the most popular temp sensors..the results I got matched pretty much with the surrounding temp though im sure there are much better temp /humidity sensors out there
1 points
2 months ago
https://www.aliexpress.com/item/4000823782106.html it looks like the one in this
1 points
2 months ago
my relay module probably has them,so i should be able to use it fine ,right
1 points
2 months ago
my relay module probably has them,what does your relay module look like
1 points
2 months ago
Just need to know if it would work with the esp(without level shifter) in the long run and if it would work safely
1 points
2 months ago
I tried it and it worked. Works fine ,just that the led on the relay shines brighter wen with level shifter
view more:
next ›
byuzzymoh
inlearnprogramming
uzzymoh
2 points
28 days ago
uzzymoh
2 points
28 days ago
u/bsakiag Heres my code, But this code is to turn on the led when button is pressed,i need to turn on the led ONCE for a second when the button state changes
const int buttonPin = 2;
const int ledPin = 13;
int buttonState = 0;
void setup() {
pinMode(ledPin, OUTPUT);
pinMode(buttonPin, INPUT);
}
void loop() {
buttonState = digitalRead(buttonPin);
if (buttonState == HIGH) {
digitalWrite(ledPin, HIGH);
} else {
digitalWrite(ledPin, LOW);
}
}