Datasheet

CircuitPython for RFM69
It's easy to use the RFM69HCW radio with CircuitPython and the Adafruit CircuitPython
RFM69 (https://adafru.it/BjE) module. This module allows you to easily write Python code that sends and receives
packets of data with the radio. Be careful to note this library is for the RFM69 radio only and will not work with the
RFM9X LoRa radios!
Design Considerations
One thing to be aware of before you use the RFM69 series of radios with CircuitPython are some of the limitations and
design considerations for its module. Keep these in mind as you think about projects using the RFM69 and
CircuitPython:
You can only send and receive packets up to 60 bytes in length at a time. The size of the radio's internal buffer
dictates this limit so if you want to send longer messages you'll need to break them into a series of smaller send
calls in your application code.
Receiving packets is a 'best effort' in pure Python code. Unlike the Arduino versions of the RFM69 library there
is no interrupt support which means when a packet is received it must be immediately processed by the Python
code or it could be lost. For your application it will work best to only receive small, single packet messages at a
time. Don't try to receive kilobytes of data or else you'll lose packets. This module is really intended for simple
single packet messages like 'ON', 'OFF', etc.
Sending and receiving packets will 'block' your Python code until the packet is fully processed. This means you
can't do a lot of other things while sending and waiting for packets to be received. Design your application so
the radio usage is the primary scenario and very little other tasks need to happen in the background.
The module is written to be compatible with the RadioHead RFM69 Arduino library. This means by default the
module will setup the radio with the same GFSK, 250kbit/s, 250khz deviation, and bit whitening radio
configuration so it can send and receive data with itself and other RadioHead-driven modules. In addition the
CircuitPython module uses the same sync word and packet preamble (4 bytes) as RadioHead. If you want to use
different modulations or settings you'll need to configure the radio yourself (see the initialization
code (https://adafru.it/BjF) for the registers and bits to access, however you will need to consult the datasheet for
the necessary values).
The CircuitPython module does not support advanced RadioHead features like guaranteed delivery or its internal
node addressing scheme. Only the simple 'raw' RadioHead examples are supported (i.e. broadcasting a packet
to all listening radios). You can however enable encryption and set an AES encryption key just like with the
RadioHead library. If you need guaranteed delivery or other advanced features you'll need to implement them in
your application code, or design your application be resilient to failures or missed messages.
Wiring With Breakout
First wire up a RFM69 breakout to your board as shown on the previous pages for Arduino. Note that the G0/interrupt
line is not used by the CircuitPython module and can remain unconnected. Here's an example of wiring a Feather M0
to the radio with a SPI connection:
© Adafruit Industries
https://learn.adafruit.com/adafruit-rfm69hcw-and-rfm96-rfm95-rfm98-lora-packet-padio-
breakouts
Page 40 of 70