novag / SlimLoRa

WIP, does NOT work yet. See https://github.com/novag/LoRa-ATtiny-Node for a working version made for the ATtiny85.
GNU Lesser General Public License v3.0
12 stars 1 forks source link

OTAA is almost fine with Arduino-1.8.12 #12

Open clavisound opened 3 years ago

clavisound commented 3 years ago

Compiles fine with OTAA (not tested with device)

One problem with OTAA two with ABP.

  1. Overflows for DR's 0-2 - unable to solve it. Will think about it.

    
     ((128 << 7) * MICROS_PER_SECOND + 500000) / 1000000, // SF12BW125 BUG with overflow.
    /home/USER/Arduino/libraries/SlimLoRa-master/SlimLoRa.cpp:67:17: warning: integer overflow in expression [-Woverflow]
     ((128 << 5) * MICROS_PER_SECOND + 500000) / 1000000, // SF10BW125 BUG with overflow.```
  2. With ABP I have this error - unable to solve it. /tmp/ccL4MkTE.ltrans0.ltrans.o: In function `SlimLoRa::ProcessDownlink(unsigned char)': /home/USER/Arduino/libraries/SlimLoRa-master/SlimLoRa.cpp:980: undefined reference to `SlimLoRa::CheckMic(unsigned char*, unsigned char*)'

I hope tomorrow to test with device. (Feather 32u4)

clavisound commented 3 years ago

Wow. Tested OTAA with device, it seems it works. I am feeling blessed with your work.

Now I have to test more uplinks, ADR, ABP.

I don't understand why. But the compile errors are dissapearring after second compile (!).

THANK YOU!

clavisound commented 3 years ago

Although the FIRST attempt join was fine, all others attempts are failing. I still can't join with OTAA. I don't know if my gateway or my network or SlimLoRa is the problem.

ABP seems to work. I will check ADR.