Giter VIP home page Giter VIP logo

rak-stm32-rui's Introduction

rak-stm32-rui's People

Contributors

beegee-tokyo avatar eddieho1124 avatar ianlo-rak avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

rak-stm32-rui's Issues

dtostrf() build failure

RUI3 SDK release 3.4.2
WisDuo_RAK3172_Evaluation_Board

Sketch dtostrf_test.ino:

#include <avr/dtostrf.h>

float f_val = 123.6794;
char outstr[15];

void setup()
{
  dtostrf(f_val,7, 3, outstr);
}
void loop()
{
}

Build:

$ arduino  --verify --verbose-build dtostrf_test.ino

< ... skipped ... >

system/WisDuo_RAK3172_Evaluation_Board/librui_v3_api.a(dtostrf.o): in function `dtostrf':
(.text.dtostrf+0x14): undefined reference to `asm'
collect2: error: ld returned 1 exit status
exit status 1

Serial config not modified.

Hi!
I'm currently using the RAK3172 module for my project.
My application needs to have an even parity mode in order to read and send data through Serial.
For this communication, I'm using USART1, which is Serial1 according to the documentation.
Tried first with Serial1.begin(2400, SERIAL_8E1); with no success.
I have tried, also, modifying the core of RUI to select a default mode of SERIAL_8E1 but it seems like the Serial won't change in any mode.
If my code is needed, I'm able to share it.
Thanks!

P2P example not working

The example listed here is not working: https://github.com/RAKWireless/RAK-STM32-RUI/blob/main/libraries/RUI_V3_examples/examples/Example/LoRa_P2P/LoRa_P2P.ino

It send/receives a couple of messages and then stops with a failure message saying that it fails to switch to RX mode.

Kongduinos code in the reply/answer here is fully working. https://forum.rakwireless.com/t/rak3172-lora-p2p-not-psend/8393/4

Maybe github should be updated to follow Kongduinos example code instead?

Release

It seems that the latest version 3.5 has not been released

system_powersave example wakeup from pin WB01 seems not working

Hi Champs,
refering to the System_Powersave Arduino example, and this line :
api.system.sleep.setup(RUI_WAKEUP_FALLING_EDGE, WB_IO1);
I would expcet the CPU to wake up from sleep.all(10000) and print the millis().
Looking at the power profiler kit's power consumption, I feel like activation of Falling edge on WB01 wakes up the CPU, but the expectation is that as per the example code, when wakes up, the serial.print will print the millis. but this doesn't happen and the code still prints the millis() every 10000ms no matter the hardware interrupt has waken the CPU up. Is there any improvement to the code to enable the wakeup in arduino

Various issues with LoRa / LoRaWAN support

  1. The API has been split into two parts, RAKLorawan / RAKLoraP2P, which is great. However, a large chunk of RAKLoraP2P functions is still inside RAKLorawan files. Why?!?

  2. As a consequence of this, compiling with "Support LoRa P2P" does not work, as some of the required functions are in RAKLorawan. Oops.

  3. Also, there were many changes in the API, which is also kind of great, as they made the API more readable. However, it seems like the devs never bothered to recompile the examples published with the BSP: if they did they would have realized that the examples, especially the example for P2P (which is originally by me), would not compile, since they use the old API. Oops...

  4. In boards.txt we have these definitions, for what to do when the user wants support for LoRaWAN and/or LoRa P2P:

WisCoreRAK4631Board.menu.supportlora.1=Support LoRaWAN and LoRa P2P
WisCoreRAK4631Board.menu.supportlora.1.build.supportlora=-DSUPPORT_LORA
WisCoreRAK4631Board.menu.supportlora.1.build.supportlora_p2p=-DSUPPORT_LORA_P2P
WisCoreRAK4631Board.menu.supportlora.2=Support LoRaWAN
WisCoreRAK4631Board.menu.supportlora.2.build.supportlora=-DSUPPORT_LORA
WisCoreRAK4631Board.menu.supportlora.2.build.supportlora_p2p=
WisCoreRAK4631Board.menu.supportlora.3=Support LoRa P2P
WisCoreRAK4631Board.menu.supportlora.3.build.supportlora=
WisCoreRAK4631Board.menu.supportlora.3.build.supportlora_p2p=-DSUPPORT_LORA_P2P -DREGION_EU868
WisCoreRAK4631Board.menu.supportlora.4=Not Support
WisCoreRAK4631Board.menu.supportlora.4.build.supportlora=
WisCoreRAK4631Board.menu.supportlora.4.build.supportlora_p2p=

There are 2 issues here. SUPPORT_LORA should really be SUPPORT_LORAWAN. LoRa != LoRaWAN. And SUPPORT_LORA_P2P should be SUPPORT_LORA, really. This has an unfortunate consequence:

In sleep.cpp / sleep.h, sleep.lora() is restricted to SUPPORT_LORA (meaning LoRaWAN). Which doesn't make sense, since this is for LoRa P2P.

#ifdef SUPPORT_LORA
void sleep::lora(uint32_t ms_time) {
  if (ms_time == 0) {
    return;
  }
  udrv_radio_sleep_ms(ms_time);
}

void sleep::lora(int ms_time) {
  if (ms_time == 0) {
    return;
  }
  udrv_radio_sleep_ms((uint32_t)ms_time);
}
#endif

So either the SUPPORT_LORA is to be replaced with SUPPORT_LORA_P2P, or, as I suggest above, make SUPPORT_LORA for P2P, and use SUPPORT_LORAWAN for LoRaWAN...

All these points are valid for all platforms, but I happen to be using RAK3172 right now. I have made all these changes myself (except SUPPORT_LORAWAN, as it's quite more extensive), and it is working well. It makes code smaller too, since if you are using only P2P or LoRaWAN, the other API doesn't get included. I'd be happy to contribute โ€“ or put up an alternate version on my GitHub.

Use of EEPROM (?)

I'm trying to test the RAK3172 right now and I'm wondering if it is possible to use some sort of EEPROM. I see that the standard library from Arduino seems not to be included as I cannot compile it. Do you have any suggestion?

Sorry if this is not the correct repository to ask this. Please redirect me to the correct one if needed.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.