Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update MKRWAN.h to expose RX2 parameters #1

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

MITEL-UNIUD
Copy link
Owner

The method setRX2DR is needed to allow receiving downlinks from TTN when using ABP in EU region with SF9-SF12. In this case, TTN chose not to follow the standard parameters for the RX2 window (that is, SF12 at 869.525KHz), but is sending at SF9.
Since the MKR WAN 1300 firmware implements the standard, to successfully send downlinks on TTN it is necessary to modify the RX2 data rate to SF9.
This fork adds methods to get and set data rate and, for completeness, frequency, for the RX2 receiving window:

  • getRX2DR(), to get the current data rate for RX2
  • getRX2Freq(), to get the current frequency for RX2
  • setRX2DR(uint8_t dr), to set data rate for RX2 (the only one really needed: use modem.setRX2DR(3) after joining with ABP to set the data rate to SF9)
  • setRX2Freq(uint32_t freq) to set the RX2 frequency (no need to change it at present).

Please note that when joining with OTAA this is not needed because parameters are communicated back to the node by the network.

The method setRX2DR is needed to allow receiving downlinks from TTN when using ABP in EU region with SF9-SF12.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant