Author Topic: Steps to pick up JeeLib packets  (Read 279 times)

dgbatman

  • Newbie
  • *
  • Posts: 5
  • currently working of a rfm69 stm32 project
Steps to pick up JeeLib packets
« on: February 03, 2019, 10:50:27 AM »
I'm working my way through the LPL RFM69 lib written in C.
I'm trying to create firmware which can be set to pickup either JeeLib or LPL packets via a software switch and perhaps a function.
The differences I've found so far, by going through the register settings:
BitRate
FDev
SyncConfig and SyncAddress setup
Header Length (LPL has three bytes, JL has two).

Yet I can't pick up the JeeLib packets, what have I missed?

All the basics like frequency and group have been checked, and I can receive LPL or JP packets fine on their respectively configured gateways.

We're going LPL direction with the project, but it'd be nice to pickup Jee packets for previous customers/users.

Regards,

Dan

emjay

  • Full Member
  • ***
  • Posts: 120
  • Country: nl
Re: Steps to pick up JeeLib packets
« Reply #1 on: February 04, 2019, 08:45:02 AM »
Rx Bandwidth?
You don't need to know fdev on the receiver side - just match baud rate and  Rx bandwidth settings from Jeelib.  There is a block in rf69.cp that has the parameter set up used at module init time.

static ROM_UINT8 configRegs_compat [] ROM_DATA = {
  0x01, 0x04, // OpMode = standby
  0x02, 0x00, // DataModul = packet mode, fsk
  0x03, 0x02, // BitRateMsb, data rate = 49,261 khz
  0x04, 0x8A, // BitRateLsb, divider = 32 MHz / 650
  0x05, 0x05, // FdevMsb = 90 KHz
  0x06, 0xC3, // FdevLsb = 90 KHz .......
 

dgbatman

  • Newbie
  • *
  • Posts: 5
  • currently working of a rfm69 stm32 project
Re: Steps to pick up JeeLib packets
« Reply #2 on: February 06, 2019, 06:20:28 AM »
Hi, only just seen this, for some reason the email notification didn't come through  ???

I've copied those very same lines with no luck. I've tried combining various part of the init code in all sorts of ways.

I'm wondering if there's a difference in preamble size, header structure, or CRC settings that I'm missing.

JeeLib is a bit of a maze.

emjay

  • Full Member
  • ***
  • Posts: 120
  • Country: nl
Re: Steps to pick up JeeLib packets
« Reply #3 on: February 08, 2019, 05:12:46 AM »
Are the legacy transponders RFM12B or RFM69 based?  If the latter, are you running in RFM12 compatibility mode or native?
Information and further pointers here.
Even with a bad CRC, a received packet is still in the Rx buffer so you can at least see what the module thinks has arrived.

dgbatman

  • Newbie
  • *
  • Posts: 5
  • currently working of a rfm69 stm32 project
Re: Steps to pick up JeeLib packets
« Reply #4 on: February 08, 2019, 06:17:22 AM »
I'm using JeeLib to transmit, RFM69 compat on with RFM69CW modules.
It's all RFM69.

I thought the same with the CRC check, I should be able to read out the bytes.

I'm checking the way JeeLib sets the frf frequency (433MHz here), and copying the function over to my LPL based test.. see if there's a subtle frequency calculation difference..

emjay

  • Full Member
  • ***
  • Posts: 120
  • Country: nl
Re: Steps to pick up JeeLib packets
« Reply #5 on: February 08, 2019, 11:03:38 AM »
How about the Rx threshold level? You are probably testing this on the bench consequently with RSSI values in the -40 to -30 dB range.  You could set the threshold artificially high for a while - this will prevent the known issue with a very weak Rx threshold setting making the Rx section appearing to go deaf.   Random noise has triggered the preamble and the state machine is busy looking for the synch pattern and subsequent decode in the noise and misses the real incoming packet preamble.

dgbatman

  • Newbie
  • *
  • Posts: 5
  • currently working of a rfm69 stm32 project
Re: Steps to pick up JeeLib packets
« Reply #6 on: February 08, 2019, 04:51:49 PM »
I found a subtle difference in the frequency settings left over from RF12 JeeLib, something to do with an offset of 1600.

I've resorted to porting a program from JeeLabs project 'embello', for the stm32 f103, available on github. I've converted the code to C and uploaded it to my f303 nucleo and I'm now receiving packets.. unable to decode them though..
The RSSI thresh setting had a big impact on the received packet number. Noise, like you say.

I'm looking at the FIFO buffer settings next.. Thresholds.. IRQFLAGS.. etc.. Not sure where I'm going with this  :/

emjay

  • Full Member
  • ***
  • Posts: 120
  • Country: nl
Re: Steps to pick up JeeLib packets
« Reply #7 on: February 09, 2019, 10:20:17 AM »
In case you haven't spotted it already, IIRC embello uses a "native" packet format that is incompatible with the RFM12/RFM69 compatibility mode.

dgbatman

  • Newbie
  • *
  • Posts: 5
  • currently working of a rfm69 stm32 project
Re: Steps to pick up JeeLib packets
« Reply #8 on: February 09, 2019, 12:59:45 PM »
I'll look into that, thanks.
What's IIRC embello?