RFM22B and packet length

186 views
Skip to first unread message

dave.f...@gmail.com

unread,
May 21, 2014, 1:13:07 AM5/21/14
to rf22-a...@googlegroups.com
I have got the EWS_RFM22B_CHAT_EXAMPLE working and spent hours reading the RFM22B and Silicon Labs AN440.pdf datasheets.

I have a test link passing a single byte command back and forth to control some hardware. I have my own code to make it "reliable".

The example works with PKTSIZE, as in write(0x3E, PKTSIZE);, down to somewhere between 10 and 17 then stops working. For sending one byte, all my reading suggests that PKTSIZE could be 1.

Are there other parameters that need to change for really short messages?  Or is my understanding of PKTSIZE incorrect?

Appreciate your comments.

Thanks
davef

Mike McCauley

unread,
May 21, 2014, 3:05:02 AM5/21/14
to rf22-a...@googlegroups.com
Hi

RF22 should support very short packets down to 1 octet.

Cheers.
--
Mike McCauley VK4AMM mi...@airspayce.com
Airspayce Pty Ltd 9 Bulbul Place Currumbin Waters QLD 4223 Australia
http://www.airspayce.com
Phone +61 7 5598-7474 Fax +61 7 5598-7070

dave.f...@gmail.com

unread,
May 21, 2014, 3:31:54 AM5/21/14
to rf22-a...@googlegroups.com
Thanks for that, Mike.  I have the RadioHead code.  After a quick look through it and while it looks quite professional, I like to understand the nuts and bolts of the low-level code to run this type of peripheral.

I have done a lot of embedded C but hesitate to put effort in to move to C++

Another thing that confuses me is that the above code example and you appear to do it as well, is tweak register 0x6A, which is not in the RFM22B datasheet or Silicon Labs AN440.pdf  HopeRF would not answer my queries, before giving them my "forecast"!

If I can't understand what is happening at this level I don't like my chances to do anything more complex then what I am doing at the moment.

Cheers,
Dave

Mike McCauley

unread,
May 21, 2014, 7:39:25 AM5/21/14
to rf22-a...@googlegroups.com
Hello,

register 6A is 'AGC Override 2' its in my copy of the RF22 doc.
But none of my RadioHead RF22 code touches register 6a.

Cheers.

dave.f...@gmail.com

unread,
May 21, 2014, 5:28:18 PM5/21/14
to rf22-a...@googlegroups.com
My mistake, it was register 58 that says it is a reserved register in the docs I quoted, but appears to be in RH_RF22.cpp  I say appears because I am not sure I correctly understand:

PROGMEM static const RH_RF22::ModemConfig MODEM_CONFIG_TABLE[] =

The other registers that say reserved in docs I quoted are: 56, 59, 5A and 68 and yet EWS_RFM22B_CHAT_EXAMPLE write values to these registers.

What would satisfy my curiosity is: how did you know to write a value to 6A?

Thanks,
Dave

 

Mike McCauley

unread,
May 22, 2014, 2:51:55 AM5/22/14
to rf22-a...@googlegroups.com
I dont know why you say it is reserved. My doc says register 58 is Charge Pump
Current Trimming Override. Its value is specified by the results of the
register calculator:

http://www.hoperf.com/upload/rf/RF22B%2023B%2031B%2042B%2043B%20Register%20Settings_RevB1-v5.xls

Cheers.

>
> Thanks,

dave.f...@gmail.com

unread,
May 22, 2014, 4:55:44 AM5/22/14
to rf22-a...@googlegroups.com
Ah, so this information is in the EXCEL spreadsheets.  I have only been looking at the datasheet from HopeRF and AN440.pdf which says registers 50-5F are reserved. And well as all of 2F, 4C-4E, 61, 63-68, 6A-6C, 78 and 7B and other individual bits. I will look at the spreadsheet to find out what register 68 does as that one does seem to be important!

If the spreadsheets are the definitive source for this product I will go with that.  Does seem to be an odd way to describe the operation of your product.

Thank you for taking the time to explain.

Cheers
Dave

Mike McCauley

unread,
May 22, 2014, 5:21:23 AM5/22/14
to rf22-a...@googlegroups.com
On Thursday, May 22, 2014 01:55:44 AM dave.f...@gmail.com wrote:
> Ah, so this information is in the EXCEL spreadsheets. I have only been
> looking at the datasheet from HopeRF and AN440.pdf which says registers
> 50-5F are reserved. And well as all of 2F, 4C-4E, 61, 63-68, 6A-6C, 78 and
> 7B and other individual bits. I will look at the spreadsheet to find out
> what register 68 does as that one does seem to be important!

Try
https://www.sparkfun.com/datasheets/Wireless/General/RFM22.PDF
and
https://www.sparkfun.com/datasheets/Wireless/General/RFM22B.pdf


>
> If the spreadsheets are the definitive source for this product I will go
> with that. Does seem to be an odd way to describe the operation of your
> product.

RFM22 transceiver is not our product, Its from HopeRF

Cheers.

>
> Thank you for taking the time to explain.
>
> Cheers
> Dave

dave.f...@gmail.com

unread,
May 22, 2014, 5:14:52 PM5/22/14
to rf22-a...@googlegroups.com
Downloaded both of those and I see in the older (?) RFM22.PDF file descriptions of many registers marked reserved in the later (?) documentation.  Thank you for pointing me to the definitive document.

I am aware it is not your product.

Dave 


dave.f...@gmail.com

unread,
May 23, 2014, 2:44:03 AM5/23/14
to rf22-a...@googlegroups.com
On closer inspection:

RFM22B_23B.pdf is V1.0
RFM22B.pdf is V1.1
RFM22.pdf is V1.2

And don't bother trying to find it on the HopeRF site, use the link Mike posted earlier in this thread.
Reply all
Reply to author
Forward
0 new messages