hello everyone
we have a remote working with 433 MHz frequency, the remote have 4 keys (A,B,C,D)
also we have RXB12 receiver ,vcc and gnd connected to esp12 and one of the data pin connected to D04
using this library airspayce
problem is when hit any key of remote in monitor don't show anything
and this code i used
we have a remote working with 433 MHz frequency, the remote have 4 keys (A,B,C,D)
also we have RXB12 receiver ,vcc and gnd connected to esp12 and one of the data pin connected to D04
using this library airspayce
problem is when hit any key of remote in monitor don't show anything
and this code i used
code used:
#include <RH_ASK.h>
#ifdef RH_HAVE_HARDWARE_SPI
#include <SPI.h> // Not actually used but needed to compile
#endif
RH_ASK driver(2000, 4, 5, 0); // ESP8266 or ESP32: do not use pin 11 or 2
void setup()
{
#ifdef RH_HAVE_SERIAL
Serial.begin(9600); // Debugging only
#endif
if (!driver.init())
#ifdef RH_HAVE_SERIAL
Serial.println("init failed");
#else
;
#endif
}
void loop()
{
uint8_t buf[RH_ASK_MAX_MESSAGE_LEN];
uint8_t buflen = sizeof(buf);
if (driver.recv(buf, &buflen)) // Non-blocking
{
int i;
// Message with a good checksum received, dump it.
driver.printBuffer("Got:", buf, buflen);
}
}