Update & RFM69 lib bug fixes

For those wondering what’s going on with the silence, I have been quite busy but I am continuing to work on improving Moteino and the libraries behind it. I hope to release news on what I’m up to in a few weeks.

The forums are now picking up activity and they are a good place to check out for various support questions that have already been answered and also to see what others are saying/sharing about Moteino.

I encourage you to keep an eye on the library source code on github for bug fixes. I am working to extend the RFM69 library and occasionally I find code that I can improve and even bug fixes. For instance right now I patched a fix for the setPowerLevel(byte level) function which was declared incorrectly as protected and also had a bug. This bug fix is especially important for those that have Moteinos with RFM69HW radios. Overall my feeling as I develop with the RFM69 library is that it’s┬ábecoming a more and more stable piece of code. I do rely partially on others to provide feedback and I appreciate those who can participate and submit suggestions.

6 thoughts on “Update & RFM69 lib bug fixes

  1. I want to thank you for putting together such a nice system. I have spent about 40 hours reading and re-reading the rfm69hw data sheet and I have to take my hat off to you. I bet your copy is more dog eared than mine. A lot of flipping pages back and forth. You have done a great job with your library. Nice tight readable code. I’m sure you’ve put a ton of time into it.

    I’ve done some preliminary testing and found that your example code without any adjustments works fine up to 1/4 of a mile! At +20dbm.

    While I was trying to figure out what was going on in the tiny radio and your code, I re-formatted the ‘registers.h’ file. Also added more registers and commands. Let me know if you want it.

    Today I made some TX measurements and found I was able to get another 10db of sensitivity for the same 55.5K bit rate! And another 12db at 1200 bps. It is simply a matter of optimizing the dev, beta and rxBW.

    Two further improvements worth implementing soon are the AFC calibration and the effects of DC cancellation along with the LowBetaAfcOffset.

    My application is to simply send a byte to control a couple relays. But, now you’ve got me thinking.


    • John,
      Thanks so much for the feedback, indeed I spent a LOT of time putting this together. Many hours before I could get some RF data across, and many more to fine tune and get stable settings. Yeah the datasheet is a bit of a haystack yet feels a little slim when it comes to the core mechanics of the registers and the chip’s state machine. I am not an RF expert so I tried to follow the few recommendations and formulas from the datasheet to get a decent bitrate/settings/range. It seems to work fine at the current settings, but like you said, I’m sure there’s more fine tuning to do and more performance/range to squeeze out of these radios. I am betting on people like you to provide feedback and contribute in any way you can to make a good product even better. Sharing is caring.
      I played a lot with all the settings and it was hard for me to get a good combination, AFC and calibration was a bit beyond me. Still haven’t gotten the internal temp register to read right, maybe it’s also a matter of calibration, just gave up after a while since it’s not the core thing I need out of it. But 10/12db more is fantastic, could mean another 100-200m in open air. If you have better suggestions than those I got in the lib please feel free to share. The forum is a good place to continue the conversation or share anything else.

  2. I be happy to share. My measurements are very preliminary, but also very promising. I’ll get the AFC going.

    WRT the temp reading. I believe you have combined two separate issues in your code.

    The RC calibration is to get the low power timer in the ‘ball park’. It’s job is to wake up the rx in dc pwr savings mode.

    My take on the temperature sensor calibration is that you simply read the value when the radio is at a known temperature (say ambient=25c). Use that value to calculate the offset ‘b’ in Moteino code. Y = mX + b. Actually, T = -1*(reading) + b. For each 1 degree C increase the rfm69 decreases it’s returned value by one count.


  3. Just ordered a few R3 with RFM69HW to test their encryption capability to build a secure sensor network. Is the encryption function supported in the current library?

  4. Thank you, Felix for the amazing service. Just did a quick email check before I go to bed and to my surprise, the shipping notice for my order is in the inbox. I think I will start with doing a secure version of the mailbox notifier – I wonder how far the FRM69HW will go through two layers of reinforced concrete to the mailbox…..

Comments are closed.