Using rpi-rf with ESP 8266

Discussion about programs, libraries and tools that work with MicroPython. Mostly these are provided by a third party.
Target audience: All users and developers of MicroPython.
Post Reply
Hansblind
Posts: 1
Joined: Sun Jan 20, 2019 9:26 pm

Using rpi-rf with ESP 8266

Post by Hansblind » Sun Jan 20, 2019 9:35 pm

Can I use the library rpi-rf with ESP8266.? If so how do I include the library ?

User avatar
mcauser
Posts: 507
Joined: Mon Jun 15, 2015 8:03 am

Re: Using rpi-rf with ESP 8266

Post by mcauser » Thu Jan 24, 2019 3:44 am

I recently built an ESP8266 project using two of those cheap ASK/OOK modules and couldn't find any suitable libraries.
There's a few raspi / arduino libraries which add their own protocols which you could use for inspiration. eg. rpi-rf, rc-switch, radiohead, etc.

For TX, depending on the complexity of the signal you wish to generate, if all you are doing is transmitting a simple message, you could get away with a loop, a few pin toggles and some sleeps.

For RX, you'd want to add an interrupt on the rising/falling edge and calculate us timings for each bit. You'll get a lot of noise, so you'll need to train it with some sensible defaults. Most ASK/OOK signals are repeated several times to avoid collisions.

I'd recommend getting a $20 RTL-SDR dongle so you can capture the signals for analysis. Universal Radio Hacker is a good place to start.

User avatar
mcauser
Posts: 507
Joined: Mon Jun 15, 2015 8:03 am

Re: Using rpi-rf with ESP 8266

Post by mcauser » Thu Jan 24, 2019 3:46 am

Not to be confused with rpitx, which is a hack that can turn a raspberry pi into a crude transmitter using nothing more than a GPIO pin (and a bandpass filter).

Post Reply