I have a similar issue with OTA and hw timer
Can you give me some more info on how you got around the problem
thanks
John
Explore... Chat... Share...
Moderator: igrr
#include <Arduino.h>
#include <ArduinoOTA.h>
#include <ESP8266mDNS.h>
#include <SoftwareSerial.h>
#include <FunctionalInterrupt.h>
class anySignal{ //maybe something good will class become
public:
anySignal(int select_pinIN, int select_pinOUT){
pinIn=select_pinIN;
pinOut=select_pinOUT;
}
void begin(int baud){
pinMode(pinIn, INPUT);
pinMode(pinOut, OUTPUT);
startMirroring();
}
void startMirroring(){
attachInterrupt(pinIn, [this]() { this->mirrorBit_ISR();}, CHANGE );
}
void stopMirroring(){
detachInterrupt(pinIn);
}
boolean ICACHE_RAM_ATTR readBit(){
return digitalRead(pinIn); // read the input pin
};
void ICACHE_RAM_ATTR writeBit(boolean a){
a ? digitalWrite(pinOut, HIGH) : digitalWrite(pinOut, LOW) ; // read the input pin
}
private:
int pinIn;
int pinOut;
bool buf;
void ICACHE_RAM_ATTR mirrorBit_ISR(){
writeBit(readBit());
}
};
It takes about 20-25 seconds for home assistant c[…]
I tried to upgrade tof my sonoff basic R2 with the[…]
a problem Perhaps you want to define "Probl[…]
Rebooting your router will not give you a faster I[…]
There are no other notifications from esptool.py i[…]
Using the Arduino IDE, you'll learn how to set up […]
In this project, you will post to Twitter using an[…]
In this project, we will build a water level contr[…]
I guess I'm late, but I had the same problem and f[…]
Last night I received my first D1 Minis for a lear[…]
Although I am aware that this is an old post, I fe[…]