Author Topic: Speeding Up The RFM69 Library  (Read 15493 times)

zingbat

  • NewMember
  • *
  • Posts: 15
Re: Speeding Up The RFM69 Library
« Reply #30 on: February 04, 2018, 12:02:25 PM »
Sounds great! I have receive working now and will hopefully post a proof of concept soon.

ChemE

  • Sr. Member
  • ****
  • Posts: 419
  • Country: us
Re: Speeding Up The RFM69 Library
« Reply #31 on: February 05, 2018, 05:36:59 AM »
I would love to see the code extended to a working receive!  Please post it for everyone when you get a chance.

LukaQ

  • Sr. Member
  • ****
  • Posts: 302
  • Country: si
Re: Speeding Up The RFM69 Library
« Reply #32 on: April 10, 2018, 08:43:02 AM »
hey ChemE, do you have gateway also available for this?
And I don't know where you set 915M or 868M freq.
« Last Edit: April 10, 2018, 09:39:13 AM by LukaQ »

ChemE

  • Sr. Member
  • ****
  • Posts: 419
  • Country: us
Re: Speeding Up The RFM69 Library
« Reply #33 on: April 10, 2018, 02:10:50 PM »
hey ChemE, do you have gateway also available for this?
And I don't know where you set 915M or 868M freq.

When the module powers up, it is already set to 915MHz so I don't bother setting the carrier frequency.  To change it is 868MHz though you would use the following:

Code: [Select]
  // Change the carrier frequency to 868MHz
  writeReg( REG_FRFMSB, 0xD9 );
  writeReg( REG_FRFMID, 0x00 );
  writeReg( REG_FRFLSB, 0x00);

My gateway is not quite finished yet.  I have been successful in listening for packets and detecting payloadready in DIO0 though.

LukaQ

  • Sr. Member
  • ****
  • Posts: 302
  • Country: si
Re: Speeding Up The RFM69 Library
« Reply #34 on: April 10, 2018, 03:31:28 PM »
what is you cpu freq.? You've set TWBR=1, which would mean that i2c clock would be very fast, 888kHz? Prescaler is 1?
I have too much capacitance on bus, I had to go with 48.

I can confirm, that is works with si7021, this would then also work with si7051.
But would like to ask, if 278 for Vcc is correct? as far as I know you are looking at bandgap voltage, right?

Any reason you are going for "everything done fast as possible"?
« Last Edit: April 10, 2018, 03:35:24 PM by LukaQ »

ChemE

  • Sr. Member
  • ****
  • Posts: 419
  • Country: us
Re: Speeding Up The RFM69 Library
« Reply #35 on: April 10, 2018, 04:21:08 PM »
what is you cpu freq.? You've set TWBR=1, which would mean that i2c clock would be very fast, 888kHz? Prescaler is 1?
I have too much capacitance on bus, I had to go with 48.

I can confirm, that is works with si7021, this would then also work with si7051.
But would like to ask, if 278 for Vcc is correct? as far as I know you are looking at bandgap voltage, right?

Any reason you are going for "everything done fast as possible"?

Fcpu is 16MHz yes.  278 is roughly what I measure on my Moteinos and yes my code is using the internal bandgap voltage as the reference.  As for why I'm doing everything as fast as possible, I always code that way!  I enjoy speeding code up, always have.  Things cannot break, but until they break, to me faster is better.

LukaQ

  • Sr. Member
  • ****
  • Posts: 302
  • Country: si
Re: Speeding Up The RFM69 Library
« Reply #36 on: April 11, 2018, 02:28:15 AM »
Also very refreshing to have code without dependency. Totally different approach for doing the same job. I like your code, give me insight into how things work "in the background".
Do you have any other code like that, that you would share? maybe github?