💬 Using Arduino
-
Using Arduino IDE 1.6.2, no problem compiling MySensors/AltSoftwareSerial/Test/test.ino. Had to make two changes: add some #defines and include an extra library. I'm using a Nordic nRF24L01+ on a Chinese board. I had to add:
#define MY_RADIO_NRF24
#define MY_RF24_PA_LEVEL RF24_PA_LOW
#define MY_GATEWAY_SERIALbefore
#include <MySensors.h>
Also, had to add the AltSofwareSerial library, otherwise I received the error "AltSoftSerial.h: No such file or directory".
If I don't follow up with a new comment it means that this config worked. I'm on Windows 10, using a fakeduino Uno, hoping to connect to an nRF24LE1 over 250Kbps.
and MySensors libraries. A
-
couldn't get nRF24L01+ to work. Making do with two nRF24LE1s communicating with each other.
-
Would be nice to have a link to the example sketches (the ones using external libraries) here: https://github.com/mysensors/MySensorsArduinoExamples
-
Would be nice to have a link to the example sketches (the ones using external libraries) here: https://github.com/mysensors/MySensorsArduinoExamples
-
So this is going to cause an argument in the sketch?:
void loop()
{
// This will be called contentiously after setup.
}Maybe should be "continuously"
-
Why do i get this error? Any idea how to fix it?
Arduino: 1.6.5 (Windows 8.1), Board: "Arduino Uno"In file included from C:\Users\Audrey\Documents\Arduino\libraries\MySensors/drivers/RF24/RF24.cpp:23:0,
from C:\Users\Audrey\Documents\Arduino\libraries\MySensors/MySensors.h:290,
from GatewayW5100.ino:116:
C:\Users\Audrey\Documents\Arduino\libraries\MySensors/drivers/RF24/RF24.h:37:17: fatal error: SPI.h: No such file or directory
#include <SPI.h>
^
compilation terminated.
Error compiling.This report would have more information with
"Show verbose output during compilation"
enabled in File > Preferences. -
Messing around with it and got this message, still not idea how to fix it
Arduino: 1.6.5 (Windows 8.1), Board: "Arduino Uno"
Using library MySensors in folder: C:\Users\Audrey\Documents\Arduino\libraries\MySensors
Using library Ethernet in folder: C:\Program Files (x86)\Arduino\libraries\Ethernet
C:\Program Files (x86)\Arduino\hardware\tools\avr/bin/avr-g++ -c -g -Os -w -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics -MMD -mmcu=atmega328p -DF_CPU=16000000L -DARDUINO=10605 -DARDUINO_AVR_UNO -DARDUINO_ARCH_AVR -IC:\Program Files (x86)\Arduino\hardware\arduino\avr\cores\arduino -IC:\Program Files (x86)\Arduino\hardware\arduino\avr\variants\standard -IC:\Users\Audrey\Documents\Arduino\libraries\MySensors -IC:\Program Files (x86)\Arduino\libraries\Ethernet\src C:\Users\Audrey\AppData\Local\Temp\build1062139905146989693.tmp\GatewayW5100.cpp -o C:\Users\Audrey\AppData\Local\Temp\build1062139905146989693.tmp\GatewayW5100.cpp.o
In file included from GatewayW5100.ino:2:0:
C:\Users\Audrey\Documents\Arduino\libraries\MySensors/MySensors.h:328:2: error: #error No forward link or gateway feature activated. This means nowhere to send messages! Pretty pointless.
#error No forward link or gateway feature activated. This means nowhere to send messages! Pretty pointless.
^
Error compiling. -
Messing around with it and got this message, still not idea how to fix it
Arduino: 1.6.5 (Windows 8.1), Board: "Arduino Uno"
Using library MySensors in folder: C:\Users\Audrey\Documents\Arduino\libraries\MySensors
Using library Ethernet in folder: C:\Program Files (x86)\Arduino\libraries\Ethernet
C:\Program Files (x86)\Arduino\hardware\tools\avr/bin/avr-g++ -c -g -Os -w -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics -MMD -mmcu=atmega328p -DF_CPU=16000000L -DARDUINO=10605 -DARDUINO_AVR_UNO -DARDUINO_ARCH_AVR -IC:\Program Files (x86)\Arduino\hardware\arduino\avr\cores\arduino -IC:\Program Files (x86)\Arduino\hardware\arduino\avr\variants\standard -IC:\Users\Audrey\Documents\Arduino\libraries\MySensors -IC:\Program Files (x86)\Arduino\libraries\Ethernet\src C:\Users\Audrey\AppData\Local\Temp\build1062139905146989693.tmp\GatewayW5100.cpp -o C:\Users\Audrey\AppData\Local\Temp\build1062139905146989693.tmp\GatewayW5100.cpp.o
In file included from GatewayW5100.ino:2:0:
C:\Users\Audrey\Documents\Arduino\libraries\MySensors/MySensors.h:328:2: error: #error No forward link or gateway feature activated. This means nowhere to send messages! Pretty pointless.
#error No forward link or gateway feature activated. This means nowhere to send messages! Pretty pointless.
^
Error compiling. -
The MySensors library is missing from the arduino library manager again. Should I just log a new issue and reference the previous one?
-
@benji_lb yes please do. Could you post the link to the issue here when it has been created so we can follow it?
-
@benji_lb
Fixed. I noticed I was running an older version of the software. Uninstalled completely and reinstalled, worked fine.Where would be the best place for an Arduino newbie to post to get some assistance? I'm looking at Gateways and i'm unsure which direction to take, and where would be best to post. Would this be OK? https://forum.mysensors.org/category/13/development
-
@benji_lb
Fixed. I noticed I was running an older version of the software. Uninstalled completely and reinstalled, worked fine.Where would be the best place for an Arduino newbie to post to get some assistance? I'm looking at Gateways and i'm unsure which direction to take, and where would be best to post. Would this be OK? https://forum.mysensors.org/category/13/development
-
Today, the "Basic Structure" section contains just a "normal" Arduino structure.
Wouldn't it be useful to also add a slightly extended version mentioning the split of the original Arduino-setup() to begin()->presentation()->setup() when using recent MySenors libs (since 2.1.0)?
This is not very transparent to quite a few users, and yet some of our examples do either not mention "before()" at all or do not make use of the new logical execution time of setup(), even if this would be helpful (!pcReceived in WaterMeter-Sketch, getControllerConfig(), for metric in Temperature, just to mention some examples) .
Also the text order of setup() still beeing above presentation() in at least some examples may be technically irrelevant but nevertheless misleading to some extend. -
Today, the "Basic Structure" section contains just a "normal" Arduino structure.
Wouldn't it be useful to also add a slightly extended version mentioning the split of the original Arduino-setup() to begin()->presentation()->setup() when using recent MySenors libs (since 2.1.0)?
This is not very transparent to quite a few users, and yet some of our examples do either not mention "before()" at all or do not make use of the new logical execution time of setup(), even if this would be helpful (!pcReceived in WaterMeter-Sketch, getControllerConfig(), for metric in Temperature, just to mention some examples) .
Also the text order of setup() still beeing above presentation() in at least some examples may be technically irrelevant but nevertheless misleading to some extend.@rejoe2 great feedback, thanks! For the examples, I have created https://github.com/mysensors/MySensors/issues/927
I have updated the "Using Arduino " page. I am not 100% sure I got it right and easy to understand so feedback is very welcome.
-
@rejoe2 great feedback, thanks! For the examples, I have created https://github.com/mysensors/MySensors/issues/927
I have updated the "Using Arduino " page. I am not 100% sure I got it right and easy to understand so feedback is very welcome.
@mfalkvidd
Your understanding of my suggestion seems to be 100% correct. I will add some additional comments and some (too complicated but working examples) as links at the github page.