arduino / arduinocore-nrf528x-mbedos Goto Github PK
View Code? Open in Web Editor NEW[Archived] Arduino core supporting mbed-enabled boards
[Archived] Arduino core supporting mbed-enabled boards
Hi @facchinm, first great to see the launch of this! Second, I'm getting stuck quite early when including this project as an Mbed OS library:
./ArduinoCore-nRF528x-mbedos/cores/arduino/Arduino.h:42:28: fatal error: api/ArduinoAPI.h: No such file or directory
#include "api/ArduinoAPI.h"
Some other file that seem to be missing is api/RingBuffer.h
. Has the structure of this changed since the release?
Hi, i'm not really the most experienced arduino user, but while i was trying to write some sensor data to an external SD card with one of the new arduino Nano 33 BLE Sense boards, i've noticed that i'm not able to compile the SD.h library correctly when using the nRF528x core.
I'm always getting the following "expected unqualified-id before numeric constant in expansion of macro"-errors:
C:\Users\Voxcon\AppData\Local\Arduino15\packages\arduino\hardware\mbed\1.1.1\cores\arduino/mbed/platform/mbed_retarget.h:62:18: error: expected unqualified-id before numeric constant
#define O_RDONLY 0 ///< Open for reading
^
P:\Arduino\libraries\SD\src/utility/SdFat.h:55:15: note: in expansion of macro 'O_RDONLY'
uint8_t const O_RDONLY = O_READ;
^~~~~~~~
etc.
After some research i've figured out that the problem is that some of the macros (O_RDONLY, O_WRONLY, O_RDWR, O_ACCMODE, O_APPEND, O_CREAT, O_EXCL and O_TRUNC) defined in mbed_retarget.h are tried to be overwritten within the SdFat.h file, and because as far as i know macros can't easily be overwritten, this causes the compiliation errors. I'm not really sure where the macros defined in mbed_retarget.h are used within the current nRF528x core, but i would assume that the best way to solve this issue would be to simply not define the affected macros within that file or at all if they are defined by the SD.h library anyways. Alternatively we could update the SD.h library and comment out the overwriting statements for the macros within the SdFat.h file. I've tried this option and it works for me, but I'm not sure how this would affect the usability of the library for non-mbed based cores though.
It would be great if you could have a look at this.
Best regards,
Vox
Hi,
Is there a plan to expand the scope of this core to other mbed os devices, e.g. nucleo boards?
It would make RTOS functionality available to a wide range of boards that are currently supported through stm32duino and maximise the benefit from creating this core, while remaining within the Arduino environment.
BR
Rob
Hi,
after succesfully working for some time, the "port" selection is now disabled (grey color).
I'm working on windows 10 (1803 version) and the Arduino IDE is 1.8.10.
The last thing performed was the upload of the attached sketch, that is probably not related.
codice_gradi.txt
In the device manager the family "PORT (COM and LPT)" is not present. I could restore legacy hardware but I don't see arduino nano 33 ble drivers in the arduino list.
Any idea?
The following doesn't actually work:
ArduinoCore-nRF528x-mbedos/cores/arduino/Arduino.h
Lines 24 to 33 in 0573071
The problem here is that both Arduino and mbed-os have a PinMode
enum, and users of either platform expect that name to map to what they're used to.
I believe this was trying to get around the problem by #defining PinMode
to something that wouldn't conflict, pulling in all of the mbed headers so that they would use the new name, and then #undefining it so that the Arduino API could use the PinMode
name normally.
You might be able to do this with a header-only library if you're careful, but it won't work if you need to link against any pre-compiled artifacts that expect the original symbol name, like we do here with libmbed.a.
If you try to do this with a recent mbed-os, you'll get a linker error:
/tmp/arduino_build_196822/core/core.a(wiring_digital.cpp.o):
In function `pinMode':
.../cores/arduino/wiring_digital.cpp:57:
undefined reference to `mbed::DigitalIn::mode(MbedPinMode)'
which makes sense, since mode() expects a different type as the parameter:
$ arm-none-eabi-objdump -Ct libmbed.a | grep DigitalIn::mode
00000000 *UND* 00000000 mbed::DigitalIn::mode(PinMode)
00000000 g F .text._ZN4mbed9DigitalIn4modeE7PinMode 0000001a mbed::DigitalIn::mode(PinMode)
One way you could tell the linker that these types are the same is with a typedef, but you can't un-typedef a symbol name and reuse it later like you can with the macro.
Another option would be to apply this macro substitution when compiling libmbed.a. You'd end up needing two versions of libmbed.a (one compiled with the substitution, and another compiled without it) if you wanted to be able to use either name depending on whether ARDUINO_AS_MBED_LIBRARY is defined, which seems to be what was intended here. Although selectively linking based off of a #define sounds painful.
I think the simplest fix would be to simply rename Arduino's PinMode enum to ArduinoPinMode. I don't think this would cause incompatibilities with legacy Arduino sketches, since most of them just use the enum variants as constants without referring to the enum type directly, although I suppose it's possible that somebody did this at one point.
I got error message below when run the mbed-os-to-arduino.
+ sed -i s#drivers/SPI.h#drivers/SPIMaster.h#g cores/arduino/mbed/mbed.h
sed: can't read cores/arduino/mbed/mbed.h: No such file or directory
It on /tmp/mbed-os-program
.
Please check that.
Hello, everybody,
I read that the BLE part of the processor runs on its own. Now I wanted to put the main processor into sleep mode.
Normally the processor should find sleep/deepsleep by itself if there is nothing to do. However, I still measure currents in the examples of about 16mA (Arduino Nano 33 BLE).
So I assume that the sleep-mode is blocked by a function.
Can someone confirm this or give me a clue how to put the controller into sleep mode? I tried the mbed::sleep() command, but without luck too.
It should be possible to send the main core to sleep and maintain the BLE functionality, right?
Greetings,
knowless
The function tone() is not working as expected. It outputs only a tone when the function is called with the duration argument. If I try to call tone() non-blocking without a duration no tone is audible.
Using:
As stated in ArduinoCore-API's itoa.h:
https://github.com/arduino/ArduinoCore-API/blob/namespace_arduino/api/itoa.h#L21-L23
// Standard C functions required in Arduino API
// If these functions are not provided by the standard library, the
// core should supply an implementation of them.
but this core does not provide implementations of ltoa
and ultoa
:
#include <api/itoa.h>
void setup() {
char foo[3];
ltoa(42, foo, 10);
ultoa(42, foo, 10);
}
void loop() {}
C:\Users\per\AppData\Local\Temp\arduino_modified_sketch_625769/MissingConversions.ino:4: undefined reference to `ltoa'
C:\Users\per\AppData\Local\Temp\arduino_modified_sketch_625769/MissingConversions.ino:5: undefined reference to `ultoa'
This breaks the long
and unsigned long
overloads of the String
class's constructor and concat
:
void setup() {
String bar1 = String((long)42);
String bar2 = String((unsigned long)42);
String foobar = "asdf";
foobar.concat((long)42);
foobar.concat((unsigned long)42);
}
void loop() {}
C:\Users\per\AppData\Local\Temp\arduino_build_659526/..\arduino_cache_182898\core\core_arduino_mbed_nano33ble_d56c57e38ae8cd7b62a9772ac9829484.a(String.cpp.o): In function `arduino::String::String(long, unsigned char)':
C:\Users\per\AppData\Local\Arduino15\packages\arduino\hardware\mbed\1.1.1\cores\arduino\api/String.cpp:100: undefined reference to `ltoa'
C:\Users\per\AppData\Local\Temp\arduino_build_659526/..\arduino_cache_182898\core\core_arduino_mbed_nano33ble_d56c57e38ae8cd7b62a9772ac9829484.a(String.cpp.o): In function `arduino::String::String(unsigned long, unsigned char)':
C:\Users\per\AppData\Local\Arduino15\packages\arduino\hardware\mbed\1.1.1\cores\arduino\api/String.cpp:108: undefined reference to `ultoa'
C:\Users\per\AppData\Local\Temp\arduino_build_659526/..\arduino_cache_182898\core\core_arduino_mbed_nano33ble_d56c57e38ae8cd7b62a9772ac9829484.a(String.cpp.o): In function `arduino::String::concat(long)':
C:\Users\per\AppData\Local\Arduino15\packages\arduino\hardware\mbed\1.1.1\cores\arduino\api/String.cpp:316: undefined reference to `ltoa'
C:\Users\per\AppData\Local\Temp\arduino_build_659526/..\arduino_cache_182898\core\core_arduino_mbed_nano33ble_d56c57e38ae8cd7b62a9772ac9829484.a(String.cpp.o): In function `arduino::String::concat(unsigned long)':
C:\Users\per\AppData\Local\Arduino15\packages\arduino\hardware\mbed\1.1.1\cores\arduino\api/String.cpp:323: undefined reference to `ultoa'
I was unable to find a 3D model of the Arduino Nano 33 BLE Sense.
Is it available anywhere?
We have encountered an issue in using the toolchain included with this package (full thread here), whereby having too many libraries or paths in the compilation will fail with the error "arm-none-eabi-g++: error: CreateProcess: No such file or directory".
We have found that using a newer version of the arm-none-eabi toolset resolves this, and the one currently referenced in the packageindex.json is 2017-q4, which suffers from this issue, whereas updating to the STM32 9.2.1 version resolves this (from this toolchain, within this board package)
Is there a plan to update the dependency at present? (or should this be logged elsewhere?)
An example of a failed and working compilation command are attached:-
ArduinoBLE_FailedCompilationLengthIssue.txt
In official AVR Arduino core, delay() is based on yield(), which is turn has weak binding and is overridable.
I am asking that yield() has a weak binding to __yield(), which shall contain the default implementation for the given platform, and that delay() on any Arduino platform must either call yield() (at least once, preferably at the end of delay()), or have a weak binding to __delay() such that is can be shimmed.
This is for compatibility with libraries like Arduino Scheduler and similar implementations.
I was trying to make a test sketch to control a servo using my new Nano 33 Sense BLE board, I then received this error when I tried to compile the program:
WARNING: library Servo claims to run on (avr, megaavr, sam, samd, nrf52, stm32f4) architecture(s) and may be incompatible with your current board which runs on (mbed) architecture(s).
In file included from C:\Users\DellPC\AppData\Local\Temp\Temp1_Arduino Board Code.zip\ServoBody\ServoBody.ino:1:0:
C:\Users\DellPC\Documents\Arduino\libraries\Servo\src/Servo.h:75:2: error: #error "This library only supports boards with an AVR, SAM, SAMD, NRF52 or STM32F4 processor."
#error "This library only supports boards with an AVR, SAM, SAMD, NRF52 or STM32F4 processor."
^~~~~
Multiple libraries were found for "Servo.h"
Used: C:\Users\DellPC\Documents\Arduino\libraries\Servo
Not used: C:\Program Files\WindowsApps\ArduinoLLC.ArduinoIDE_1.8.21.0_x86__mdqgnx93n4wtt\libraries\Servo
exit status 1
Error compiling for board Arduino Nano 33 BLE.
Can I expect this issue to resolve this in the very near future? I can understand that its a fairly new piece of hardware but I wasn't aware that there was no current support for the Servo.h Library, which I need to use for an upcoming project. I'd hate to have to return and exchange for another Arduino board since I like the variety of sensors loaded on the Nano 33 Sense.
I have a problem with the Arduino Nano 33 BLE board with ArduinoBLE library. As soon as I try to connect to the device through the smartphone, the microcontroller freezes and the yellow LED flashes 5 times fast and 5 times slow and I am forced to reflash the firmware by double clicking the reset button. I have found similar problems also with the use of Wire library. What can this problem be due to?
I ask for help to insert the Keypad library i2c on the arduino nano 33, I tried but it gives me this error.I think there is a problem with enabling the Mbed os architecture to use wire.h pins.
In file included from C:\Users\Indagini Forensi 2\Documents\Arduino\libraries\Keypad_I2C\examples\CustomKeypad_I2C\CustomKeypad_I2C.ino:11:0:
C:\Users\Indagini Forensi 2\Documents\Arduino\libraries\Keypad_I2C/Keypad_I2C.h: In constructor 'Keypad_I2C::Keypad_I2C(char*, byte*, byte*, byte, byte, byte, byte)':
C:\Users\Indagini Forensi 2\Documents\Arduino\libraries\Keypad_I2C/Keypad_I2C.h:45:48: error: no matching function for call to 'arduino::MbedI2C::MbedI2C()'
Keypad(userKeymap, row, col, numRows, numCols) { i2caddr = address; i2cwidth = width;}
^
In file included from C:\Users\Indagini Forensi 2\Documents\Arduino\libraries\Keypad_I2C/Keypad_I2C.h:36:0,
from C:\Users\Indagini Forensi 2\Documents\Arduino\libraries\Keypad_I2C\examples\CustomKeypad_I2C\CustomKeypad_I2C.ino:11:
C:\Users\Indagini Forensi 2\AppData\Local\Arduino15\packages\arduino\hardware\mbed\1.1.2\libraries\Wire/Wire.h:30:5: note: candidate: arduino::MbedI2C::MbedI2C(int, int)
MbedI2C(int sda, int scl);
^~~~~~~
C:\Users\Indagini Forensi 2\AppData\Local\Arduino15\packages\arduino\hardware\mbed\1.1.2\libraries\Wire/Wire.h:30:5: note: candidate expects 2 arguments, 0 provided
C:\Users\Indagini Forensi 2\AppData\Local\Arduino15\packages\arduino\hardware\mbed\1.1.2\libraries\Wire/Wire.h:27:7: note: candidate: constexpr arduino::MbedI2C::MbedI2C(const arduino::MbedI2C&)
class MbedI2C : public HardwareI2C
^~~~~~~
C:\Users\Indagini Forensi 2\AppData\Local\Arduino15\packages\arduino\hardware\mbed\1.1.2\libraries\Wire/Wire.h:27:7: note: candidate expects 1 argument, 0 provided
C:\Users\Indagini Forensi 2\AppData\Local\Arduino15\packages\arduino\hardware\mbed\1.1.2\libraries\Wire/Wire.h:27:7: note: candidate: constexpr arduino::MbedI2C::MbedI2C(arduino::MbedI2C&&)
C:\Users\Indagini Forensi 2\AppData\Local\Arduino15\packages\arduino\hardware\mbed\1.1.2\libraries\Wire/Wire.h:27:7: note: candidate expects 1 argument, 0 provided
Più di una libreria trovata per "Keypad_I2C.h"
Usata: C:\Users\Indagini
Più di una libreria trovata per "Keypad.h"
Usata: C:\Users\Indagini
Più di una libreria trovata per "Wire.h"
Usata: C:\Users\Indagini
exit status 1
Errore durante la compilazione per la scheda Arduino Nano 33 BLE.
Looking further into the MBedOS code, it appears the I2C Slave functionality is not yet implemented for the nRF52840. Will there be any effort to implement this on the nRF528x?
Hi,
I've been testing an Arduino Nano 33 BLE to test it's functionality with pull-down resistors.
int testPin = 2;
void setup() {
Serial.begin(9600);
pinMode(LEDG, OUTPUT);
pinMode(LED_BUILTIN, OUTPUT);
pinMode(testPin, INPUT_PULLDOWN);
}
void loop() {
if(digitalRead(testPin)){
digitalWrite(LED_BUILTIN, HIGH);
digitalWrite(LEDG, HIGH);
}else{
digitalWrite(LED_BUILTIN, LOW);
digitalWrite(LEDG, LOW);
}
Serial.println(digitalRead(testPin));
}
A switch is hooked up between 3V3 and pin D2. With this code the micro controller is acting as if it's a pull-up resistor and not pulldown. The RGB-led seems also to not handle this code without adding a minimum of delay(1);
NB! another point worth mentioning. The RGB-led is fixed to 3V3, which means the code for "LOW" and "HIGH" is inverted.
Hello Arduino,
For an IoT project I need to connect a GPS and GPRS board, each needs a Serial port.
As there is only one Serial port available (the USB is taken) I need a second Serial port. Unfortunately SoftwareSerial and Uart libs don't work on Nano 33 and I'm stuck.
Is it something you could add? or clearly I can't build my project with a Nano 33?
Thanks
ping @ostaquet
I would like to be sure that my Arduino is in upload mode before pressing the upload button from IDE. This is because my Arduino is not easy to reach and I often have to press the reset button to load the sketch.
I could put Arduino in upload mode, from bluetooth, with a code if this were possible.
Thanks
When creating a simple program to read a button with a pull-down resistor (10k) the input registers no voltage for as long as digitalRead is not called. Once digitalRead is issued, the pin seems to go into internal pull-up configuration, what makes the pin to be always up for the above-mentioned pull-down resistor.
Reproduce the error
void setup() {
pinMode(2, INPUT);
}
void loop() {
}
On the multimeter this reads: 0V
void setup() {
pinMode(2, INPUT);
}
void loop() {
digitalRead(2);
}
The multimeter goes then into 3v3 for that pin.
On the other hand, when checking into the way digitalRead is defined, we find that it returns:
return (PinStatus)mbed::DigitalIn(digitalPinToPinName(pin)).read();
(as seen at: https://github.com/arduino/ArduinoCore-nRF528x-mbedos/blob/master/cores/arduino/wiring_digital.cpp#L79)
This call to DigitalIn seems to be lacking PullNone, what could be the reason for this not to work. However, this requires a deeper revision, as just adding PullNone, would force it also in the case when we would like INPUT_PULLUP to be active.
Scetch:
#include <sys/stat.h>
Target:
Arduino Nano 33 BLE
Dump:
Arduino: 1.8.11 (Windows 10), Board: "Arduino Nano 33 BLE"
C:\Program Files (x86)\Arduino\arduino-builder -dump-prefs -logger=machine -hardware C:\Program Files (x86)\Arduino\hardware -hardware C:\Users\Arduino\AppData\Local\Arduino15\packages -tools C:\Program Files (x86)\Arduino\tools-builder -tools C:\Program Files (x86)\Arduino\hardware\tools\avr -tools C:\Users\Arduino\AppData\Local\Arduino15\packages -built-in-libraries C:\Program Files (x86)\Arduino\libraries -libraries C:\Users\Arduino\Documents\Arduino\libraries -fqbn=arduino:mbed:nano33ble -ide-version=10811 -build-path C:\Users\Arduino\AppData\Local\Temp\arduino_build_861866 -warnings=none -build-cache C:\Users\Arduino\AppData\Local\Temp\arduino_cache_622342 -prefs=build.warn_data_percentage=75 -prefs=runtime.tools.openocd.path=C:\Users\Arduino\AppData\Local\Arduino15\packages\arduino\tools\openocd\0.10.0-arduino9 -prefs=runtime.tools.openocd-0.10.0-arduino9.path=C:\Users\Arduino\AppData\Local\Arduino15\packages\arduino\tools\openocd\0.10.0-arduino9 -prefs=runtime.tools.bossac.path=C:\Users\Arduino\AppData\Local\Arduino15\packages\arduino\tools\bossac\1.9.1-arduino1 -prefs=runtime.tools.bossac-1.9.1-arduino1.path=C:\Users\Arduino\AppData\Local\Arduino15\packages\arduino\tools\bossac\1.9.1-arduino1 -verbose C:\Users\Arduino\Desktop\sketch_feb08a\sketch_feb08a.ino
C:\Program Files (x86)\Arduino\arduino-builder -compile -logger=machine -hardware C:\Program Files (x86)\Arduino\hardware -hardware C:\Users\Arduino\AppData\Local\Arduino15\packages -tools C:\Program Files (x86)\Arduino\tools-builder -tools C:\Program Files (x86)\Arduino\hardware\tools\avr -tools C:\Users\Arduino\AppData\Local\Arduino15\packages -built-in-libraries C:\Program Files (x86)\Arduino\libraries -libraries C:\Users\Arduino\Documents\Arduino\libraries -fqbn=arduino:mbed:nano33ble -ide-version=10811 -build-path C:\Users\Arduino\AppData\Local\Temp\arduino_build_861866 -warnings=none -build-cache C:\Users\Arduino\AppData\Local\Temp\arduino_cache_622342 -prefs=build.warn_data_percentage=75 -prefs=runtime.tools.openocd.path=C:\Users\Arduino\AppData\Local\Arduino15\packages\arduino\tools\openocd\0.10.0-arduino9 -prefs=runtime.tools.openocd-0.10.0-arduino9.path=C:\Users\Arduino\AppData\Local\Arduino15\packages\arduino\tools\openocd\0.10.0-arduino9 -prefs=runtime.tools.bossac.path=C:\Users\Arduino\AppData\Local\Arduino15\packages\arduino\tools\bossac\1.9.1-arduino1 -prefs=runtime.tools.bossac-1.9.1-arduino1.path=C:\Users\Arduino\AppData\Local\Arduino15\packages\arduino\tools\bossac\1.9.1-arduino1 -verbose C:\Users\Arduino\Desktop\sketch_feb08a\sketch_feb08a.ino
Using board 'nano33ble' from platform in folder: C:\Users\Arduino\AppData\Local\Arduino15\packages\arduino\hardware\mbed\1.1.4
Using core 'arduino' from platform in folder: C:\Users\Arduino\AppData\Local\Arduino15\packages\arduino\hardware\mbed\1.1.4
Detecting libraries used...
"C:\\Users\\Arduino\\AppData\\Local\\Arduino15\\packages\\arduino\\tools\\arm-none-eabi-gcc\\9-2019q4/bin/arm-none-eabi-g++" -c -w -g -Os -nostdlib "@C:\\Users\\Arduino\\AppData\\Local\\Arduino15\\packages\\arduino\\hardware\\mbed\\1.1.4\\variants\\ARDUINO_NANO33BLE/defines.txt" "@C:\\Users\\Arduino\\AppData\\Local\\Arduino15\\packages\\arduino\\hardware\\mbed\\1.1.4\\variants\\ARDUINO_NANO33BLE/cxxflags.txt" -DARDUINO_ARCH_NRF52840 -mcpu=cortex-m4 -w -x c++ -E -CC -DARDUINO=10811 -DARDUINO_ARDUINO_NANO33BLE -DARDUINO_ARCH_MBED "-IC:\\Users\\Arduino\\AppData\\Local\\Arduino15\\packages\\arduino\\hardware\\mbed\\1.1.4\\cores\\arduino" "-IC:\\Users\\Arduino\\AppData\\Local\\Arduino15\\packages\\arduino\\hardware\\mbed\\1.1.4\\variants\\ARDUINO_NANO33BLE" "-IC:\\Users\\Arduino\\AppData\\Local\\Arduino15\\packages\\arduino\\hardware\\mbed\\1.1.4\\cores\\arduino/api/deprecated" "-iprefixC:\\Users\\Arduino\\AppData\\Local\\Arduino15\\packages\\arduino\\hardware\\mbed\\1.1.4\\cores\\arduino" "@C:\\Users\\Arduino\\AppData\\Local\\Arduino15\\packages\\arduino\\hardware\\mbed\\1.1.4\\variants\\ARDUINO_NANO33BLE/includes.txt" "C:\\Users\\Arduino\\AppData\\Local\\Temp\\arduino_build_861866\\sketch\\sketch_feb08a.ino.cpp" -o nul
Generating function prototypes...
"C:\\Users\\Arduino\\AppData\\Local\\Arduino15\\packages\\arduino\\tools\\arm-none-eabi-gcc\\9-2019q4/bin/arm-none-eabi-g++" -c -w -g -Os -nostdlib "@C:\\Users\\Arduino\\AppData\\Local\\Arduino15\\packages\\arduino\\hardware\\mbed\\1.1.4\\variants\\ARDUINO_NANO33BLE/defines.txt" "@C:\\Users\\Arduino\\AppData\\Local\\Arduino15\\packages\\arduino\\hardware\\mbed\\1.1.4\\variants\\ARDUINO_NANO33BLE/cxxflags.txt" -DARDUINO_ARCH_NRF52840 -mcpu=cortex-m4 -w -x c++ -E -CC -DARDUINO=10811 -DARDUINO_ARDUINO_NANO33BLE -DARDUINO_ARCH_MBED "-IC:\\Users\\Arduino\\AppData\\Local\\Arduino15\\packages\\arduino\\hardware\\mbed\\1.1.4\\cores\\arduino" "-IC:\\Users\\Arduino\\AppData\\Local\\Arduino15\\packages\\arduino\\hardware\\mbed\\1.1.4\\variants\\ARDUINO_NANO33BLE" "-IC:\\Users\\Arduino\\AppData\\Local\\Arduino15\\packages\\arduino\\hardware\\mbed\\1.1.4\\cores\\arduino/api/deprecated" "-iprefixC:\\Users\\Arduino\\AppData\\Local\\Arduino15\\packages\\arduino\\hardware\\mbed\\1.1.4\\cores\\arduino" "@C:\\Users\\Arduino\\AppData\\Local\\Arduino15\\packages\\arduino\\hardware\\mbed\\1.1.4\\variants\\ARDUINO_NANO33BLE/includes.txt" "C:\\Users\\Arduino\\AppData\\Local\\Temp\\arduino_build_861866\\sketch\\sketch_feb08a.ino.cpp" -o "C:\\Users\\Arduino\\AppData\\Local\\Temp\\arduino_build_861866\\preproc\\ctags_target_for_gcc_minus_e.cpp"
"C:\\Program Files (x86)\\Arduino\\tools-builder\\ctags\\5.8-arduino11/ctags" -u --language-force=c++ -f - --c++-kinds=svpf --fields=KSTtzns --line-directives "C:\\Users\\Arduino\\AppData\\Local\\Temp\\arduino_build_861866\\preproc\\ctags_target_for_gcc_minus_e.cpp"
Compiling sketch...
"C:\\Users\\Arduino\\AppData\\Local\\Arduino15\\packages\\arduino\\tools\\arm-none-eabi-gcc\\9-2019q4/bin/arm-none-eabi-g++" -c -w -g -Os -nostdlib "@C:\\Users\\Arduino\\AppData\\Local\\Arduino15\\packages\\arduino\\hardware\\mbed\\1.1.4\\variants\\ARDUINO_NANO33BLE/defines.txt" "@C:\\Users\\Arduino\\AppData\\Local\\Arduino15\\packages\\arduino\\hardware\\mbed\\1.1.4\\variants\\ARDUINO_NANO33BLE/cxxflags.txt" -DARDUINO_ARCH_NRF52840 -MMD -mcpu=cortex-m4 -DARDUINO=10811 -DARDUINO_ARDUINO_NANO33BLE -DARDUINO_ARCH_MBED "-IC:\\Users\\Arduino\\AppData\\Local\\Arduino15\\packages\\arduino\\hardware\\mbed\\1.1.4\\cores\\arduino" "-IC:\\Users\\Arduino\\AppData\\Local\\Arduino15\\packages\\arduino\\hardware\\mbed\\1.1.4\\variants\\ARDUINO_NANO33BLE" "-IC:\\Users\\Arduino\\AppData\\Local\\Arduino15\\packages\\arduino\\hardware\\mbed\\1.1.4\\cores\\arduino/api/deprecated" "-iprefixC:\\Users\\Arduino\\AppData\\Local\\Arduino15\\packages\\arduino\\hardware\\mbed\\1.1.4\\cores\\arduino" "@C:\\Users\\Arduino\\AppData\\Local\\Arduino15\\packages\\arduino\\hardware\\mbed\\1.1.4\\variants\\ARDUINO_NANO33BLE/includes.txt" "C:\\Users\\Arduino\\AppData\\Local\\Temp\\arduino_build_861866\\sketch\\sketch_feb08a.ino.cpp" -o "C:\\Users\\Arduino\\AppData\\Local\\Temp\\arduino_build_861866\\sketch\\sketch_feb08a.ino.cpp.o"
In file included from C:\Users\Arduino\Desktop\sketch_feb08a\sketch_feb08a.ino:1:
c:\users\Arduino\appdata\local\arduino15\packages\arduino\tools\arm-none-eabi-gcc\9-2019q4\arm-none-eabi\include\sys\stat.h:27:8: error: redefinition of 'struct stat'
27 | struct stat
| ^~~~
In file included from C:\Users\Arduino\AppData\Local\Arduino15\packages\arduino\hardware\mbed\1.1.4\cores\arduino/mbed/platform/mbed_error.h:21,
from C:\Users\Arduino\AppData\Local\Arduino15\packages\arduino\hardware\mbed\1.1.4\cores\arduino/mbed/rtos/Queue.h:28,
from C:\Users\Arduino\AppData\Local\Arduino15\packages\arduino\hardware\mbed\1.1.4\cores\arduino/mbed/rtos/Mail.h:28,
from C:\Users\Arduino\AppData\Local\Arduino15\packages\arduino\hardware\mbed\1.1.4\cores\arduino/mbed/rtos/rtos.h:33,
from C:\Users\Arduino\AppData\Local\Arduino15\packages\arduino\hardware\mbed\1.1.4\cores\arduino/mbed/mbed.h:23,
from C:\Users\Arduino\AppData\Local\Arduino15\packages\arduino\hardware\mbed\1.1.4\cores\arduino/Arduino.h:32,
from C:\Users\Arduino\AppData\Local\Temp\arduino_build_861866\sketch\sketch_feb08a.ino.cpp:1:
C:\Users\Arduino\AppData\Local\Arduino15\packages\arduino\hardware\mbed\1.1.4\cores\arduino/mbed/platform/mbed_retarget.h:500:8: note: previous definition of 'struct stat'
500 | struct stat {
| ^~~~
exit status 1
Error compiling for board Arduino Nano 33 BLE.
I did also try to update arm-none-eabi-gcc from 7-2017q4 to 9-2019q4 - same results.
Downloaded from GNU Arm Embedded Toolchain
This bug is also related to:
Error compiling for board Arduino Nano 33 BLE
Hi I report a problem of slow compilation for this board Arduino NANO 33 BLE, especially if you use heavy libraries like ArduinoBLE. I noticed this problem after upgrading to MacOS Catalina from Mojave. Before the upgrade, the compilation lasted 10 seconds, now it lasts almost 1 minute. I tried to do the same test in Windows also using different versions of the IDE (1.8.10 and 1.9.0), getting worst results (5 minute for compiling). Is it possible to speed up compilation in any way? What has changed from MacOS Mojave to Catalina?
Thank you!
I created a library for uart communications:
https://github.com/gianmarcov/arduino_vesc/tree/develop
With the WROOM ESP32 it's working and i have no problem, with the nano 33 BLE Sense i tried the same sketch changed the Serial2 to Serial1 and nothing happens, i also swapped rx and tx to the other board without results.
I have remote debugged the other controller and i see only 2 bytes incoming the other not.
So i soldered the wires to SWD pins and i flashed my own code without Andruino Core etc. directly using the Nordic nRF52 SDK and now it's working without problems.
So something is going wrong in the Arduino Core or MBed, that all bytes are not transferred via tx.
if you have questions or i should test some code changes don't hesitate to contact me.
Thread that i created in the Forum:
https://forum.arduino.cc/index.php?topic=639277.0
Attaching interrupts for multiple pin change events via attachInterrupt(...) doesn't appear to work on the new nRF52840 based nano boards.
In the simplified test case below, the first call to attachInterrupt appears to work (falling edge of IN3, or pin 6). The other ones don't work. You can change the order of the attachInterrupt calls to get a different pin change interrupt to start working, but I've only ever seen one interrupt working at a time.
I think pins 4, 5, and 6 are actually pins P1_15, P1_13, and P1_14 on the nRF52840 (from variant.cpp), although this could be wrong (the documentation for these new nano boards is pretty lacking). Could this be because all of the inputs are on the same port? This normally isn't a restriction, e.g. when using Nordic's SDK, although I haven't used mbed on a Nordic IC.
In any case, this seems like a bug.
#define IN1 4
#define IN2 5
#define IN3 6
// LEDs
#define OUT1 22
#define OUT2 23
#define OUT3 24
int out1 = 1;
int out2 = 1;
int out3 = 0;
void in1_handler() {
out1 = (out1 + 1) % 2;
digitalWrite(OUT1, out1);
}
void in2_handler() {
out2 = (out2 + 1) % 2;
digitalWrite(OUT2, out2);
}
void in3_handler() {
out3 = (out3 + 1) % 2;
digitalWrite(OUT3, out3);
}
void setup() {
// put your setup code here, to run once:
Serial.begin(9600);
while(!Serial) {}
Serial.println("setup");
digitalWrite(OUT1, out1);
digitalWrite(OUT2, out2);
digitalWrite(OUT3, out3);
pinMode(OUT1, OUTPUT);
pinMode(OUT2, OUTPUT);
pinMode(OUT3, OUTPUT);
pinMode(IN1, INPUT_PULLUP);
pinMode(IN2, INPUT_PULLUP);
pinMode(IN3, INPUT_PULLUP);
attachInterrupt(digitalPinToInterrupt(IN3), in3_handler, FALLING);
attachInterrupt(digitalPinToInterrupt(IN2), in2_handler, FALLING);
attachInterrupt(digitalPinToInterrupt(IN1), in1_handler, FALLING);
}
void loop() {
// put your main code here, to run repeatedly:
Serial.println("delay");
delay(500);
}
Ethernet library doesn't compile with this core because the IPAddress class in this core's release is in name space arduino
. there are two problems:
fix 1 in IPAddress.h. forward declare classes before namespace arduino {
class EthernetClass;
class DhcpClass;
class DNSClient;
declare friends as
friend ::EthernetClass;
friend ::DhcpClass;
friend ::DNSClient;
(or fix the Ethernet library, so it doesn't use private members of the IPAddress class)
fix 2 in IPAddress.cpp
const IPAddress arduino::INADDR_NONE(0,0,0,0);
Hi,
Since the nano 33 are based on MBED and run MBEDos (with arduino core on top of it) I wonder if it is possible to use MBED with arduino core on such board ? How would you do that (which target to use and how to connect the board to the PC to upload ?)
Thx
Hi, I am trying to generate a new variant:
$ mbed-os-to-arduino EFM32GG_STK3700:EFM32GG_STK3700
VARIANT=EFM32GG_STK3700 BOARD=EFM32GG_STK3700
Checking for prerequisites... done.
Creating MbedOS Application... done.
Checking out preferred 'mbed-os' version... done.
Setting up Mbed Application...[mbed] Working path "/private/tmp/mbed-os-program" (program)
[mbed] EFM32GG_STK3700 now set as default target in program "mbed-os-program"
[mbed] Working path "/private/tmp/mbed-os-program" (program)
[mbed] GCC_ARM now set as default toolchain in program "mbed-os-program"
Compiling Mbed Application...
Generating defines..../mbed-os-to-arduino: line 129: Arduino/hardware/arduino/mbed/variants/EFM32GG_STK3700/defines.txt: No such file or directory
The official board pinout diagram says D7 is P0.09, and D8 is P0.10.
However, the BSP v1.1.3 variant.cpp says they are 0.23 and P0.21, respectively:
ArduinoCore-nRF528x-mbedos/variants/ARDUINO_NANO33BLE/variant.cpp
Lines 12 to 15 in 8b642cc
Which of these are correct and should be our source of truth?
Can someone validate each of the pin definitions in variant.cpp for correctness?
There are many problems with the Wire library. I tried to run different sketches on two Arduino Nano BLE 33 boards (one master and one slave), including the examples, but the communication does not work. Specifically, the onRequest() and onReceive() functions do not seem to work. Furthermore, it is not possible to send a string with the Wire.write() function, as could be done with the AVR platform. I analyzed the signals with a logic analyzer and for example in the case of the requestFrom() I do not receive any response from the slave. How can the problem be solved?
Unfortunately, I noticed that the analogReference(uint8_t mode) function is not implemented in wiring_analog.cpp. It would be useful to have a function that uses the internal voltage reference at 0.6V and the relative multiplier. I await updates.
Originally reported by @LittleHobbyShop here: adafruit/Adafruit-GFX-Library#242
@facchinm any thoughts on this?
If I understand the intention correctly this is a generic library to bring the Arduino API into Mbed. In that case, maybe it make sense to reflect hat in the name to avoid confusion?
This is a fantastic development btw!
The last days I tried to gain access to the Nordic SDK below the mbed layer. My application needs tight timings and the mbed timers caused to much jitter. Therefore I tried going with the hardware timer and nrf52's PPI module. I tried to get a modified timer-example from the nordic SDK to compile. So far without success. I reached a dead end and are looking for advice.
I copied all missing files (nrfx_timer.c & nrf_drv_timer.h) into their respective folder. I took them from the nordic SDK 15.0.
Arduino: 1.8.10 (Windows 10), Board: "Arduino Nano 33 BLE"
sketch\sketch_mar06a.ino.cpp.o: In function `setup':
C:\Users\elims\Documents\Arduino\Tests\sketch_mar06a/sketch_mar06a.ino:51: undefined reference to `nrfx_timer_init'
C:\Users\elims\Documents\Arduino\Tests\sketch_mar06a/sketch_mar06a.ino:56: undefined reference to `nrfx_timer_extended_compare'
C:\Users\elims\Documents\Arduino\Tests\sketch_mar06a/sketch_mar06a.ino:59: undefined reference to `nrfx_timer_enable'
collect2.exe: error: ld returned 1 exit status
exit status 1
Here is the actual code I'm trying to compile. Via googling I got the hint, that it doesn't find the nrfx_timer.c. The include paths in the includes.txt are all set to these folders. How do I tell the linker where to look?
//override settings in sdk_config.h to enable timer support
#define NRFX_TIMER_ENABLED 1
#define NRFX_TIMER0_ENABLED 1
//enable legacy support
#define TIMER_ENABLED 1
#define TIMER0_ENABLED 1
#include "nrf.h"
#include "nrf_drv_timer.h"
#include "app_error.h"
const nrf_drv_timer_t TIMER_LED = NRF_DRV_TIMER_INSTANCE(0);
mbed::DigitalOut led1(digitalPinToPinName(LED_BUILTIN));
void flip() {
led1 = !led1;
}
/**
* @brief Handler for timer events.
*/
void timer_led_event_handler(nrf_timer_event_t event_type, void* p_context)
{
switch (event_type)
{
case NRF_TIMER_EVENT_COMPARE0:
flip();
break;
default:
//Do nothing.
break;
}
}
void setup() {
uint32_t time_ms = 500; //Time(in miliseconds) between consecutive compare events.
uint32_t time_ticks;
uint32_t err_code = NRF_SUCCESS;
//Configure all leds on board.
led1 = 1;
//Configure TIMER_LED for generating simple light effect - leds on board will invert his state one after the other.
nrf_drv_timer_config_t timer_cfg = NRF_DRV_TIMER_DEFAULT_CONFIG;
err_code = nrf_drv_timer_init(&TIMER_LED, &timer_cfg, timer_led_event_handler);
APP_ERROR_CHECK(err_code);
time_ticks = nrf_drv_timer_ms_to_ticks(&TIMER_LED, time_ms);
nrf_drv_timer_extended_compare(
&TIMER_LED, NRF_TIMER_CC_CHANNEL0, time_ticks, NRF_TIMER_SHORT_COMPARE0_CLEAR_MASK, true);
nrf_drv_timer_enable(&TIMER_LED);
}
void loop() {
while(1){
__WFI();
}
}
Arduino and mbed are perfect for most high level stuff. However, some things need to be done with dedicated hardware peripherals. I would highly appreciate if it would be possible to use the advanced hardware features of this fantastic chip out of the arduino environment. Like it is possible an all other platforms.
Hey guys,
Im seeing that you are releasing the Arduino Nano 33 BLE (NRF52840). Well done!
My question is, is this the core to use for that board? What is the level of stability and peripheral support?
How does this compare with adafruits core here?
Thanks!
I'm trying to work on a fix for #7, which should only be a one or two line change to the parent mbed-os, however I can't figure out which version/branch/tag/fork of mbed-os was used to build the current release of ArduinoCore-nRF528x-mbedos.
The git commit logs seem to be referencing mbed-os-5.4.0-rc2, but that doesn't make any sense, since that release is over two years old and the ARDUINO_NANO33BLE target only appeared in 5.13.4. I think this is either a mistake, or somebody is working off of a weird fork that I can't find.
Right now there's just mbed-to-arduino script, but this appears to be both partially incomplete as well as subtly incompatible with most of the mbed-os releases that I've tried to work with (from @ARMmbed and @facchinm). Playing with the dummy mbed project and figuring out how to generate the correct artifacts for the arduino core should be relatively straightforward... I just need to know which mbed-os to use.
It would be nice if there were a formal way to identify the mbed-os release. This could be as simple as a changelog with a git repo url + commit id. Or maybe a submodule?
I am currently writing an application that uses the USB HID library, and certain keys are being interpreted as if it is a UK keyboard instead of a US keyboard (0x40 is " instead of @). I have looked through code and not found anything that could be used to fix it (I have tried changing my vendor and product code to a microsoft keyboard but that did not change it). Any help would be appreciated!
Using Arduino: 1.8.10 (tar file unpacked into personal bin
directory)
Arduino nRF528x (Mbed OS) 1.1.2
on Ubuntu 18.04 x64
I get compilation errors when compiling the canonical Blink example. Blink compiles fine on Windows 10 with the same BSP and Arduino versions. After the first failure I removed .arduino15
and reinstalled the BSP to make sure everything was clean, and the errors still occur.
Arduino: 1.8.10 (Linux), Board: "Arduino Nano 33 BLE"
/home/halbert/bin/arduino-1.8.10/arduino-builder -dump-prefs -logger=machine -hardware /home/halbert/bin/arduino-1.8.10/hardware -hardware /home/halbert/.arduino15/packages -tools /home/halbert/bin/arduino-1.8.10/tools-builder -tools /home/halbert/bin/arduino-1.8.10/hardware/tools/avr -tools /home/halbert/.arduino15/packages -built-in-libraries /home/halbert/bin/arduino-1.8.10/libraries -libraries /home/halbert/Arduino/libraries -fqbn=arduino:mbed:nano33ble -ide-version=10810 -build-path /tmp/arduino_build_565364 -warnings=none -build-cache /tmp/arduino_cache_113244 -prefs=build.warn_data_percentage=75 -prefs=runtime.tools.arm-none-eabi-gcc.path=/home/halbert/.arduino15/packages/arduino/tools/arm-none-eabi-gcc/7-2017q4 -prefs=runtime.tools.arm-none-eabi-gcc-7-2017q4.path=/home/halbert/.arduino15/packages/arduino/tools/arm-none-eabi-gcc/7-2017q4 -prefs=runtime.tools.bossac.path=/home/halbert/.arduino15/packages/arduino/tools/bossac/1.9.1-arduino1 -prefs=runtime.tools.bossac-1.9.1-arduino1.path=/home/halbert/.arduino15/packages/arduino/tools/bossac/1.9.1-arduino1 -prefs=runtime.tools.openocd.path=/home/halbert/.arduino15/packages/arduino/tools/openocd/0.10.0-arduino9 -prefs=runtime.tools.openocd-0.10.0-arduino9.path=/home/halbert/.arduino15/packages/arduino/tools/openocd/0.10.0-arduino9 -verbose /home/halbert/Arduino/Blink/Blink.ino
/home/halbert/bin/arduino-1.8.10/arduino-builder -compile -logger=machine -hardware /home/halbert/bin/arduino-1.8.10/hardware -hardware /home/halbert/.arduino15/packages -tools /home/halbert/bin/arduino-1.8.10/tools-builder -tools /home/halbert/bin/arduino-1.8.10/hardware/tools/avr -tools /home/halbert/.arduino15/packages -built-in-libraries /home/halbert/bin/arduino-1.8.10/libraries -libraries /home/halbert/Arduino/libraries -fqbn=arduino:mbed:nano33ble -ide-version=10810 -build-path /tmp/arduino_build_565364 -warnings=none -build-cache /tmp/arduino_cache_113244 -prefs=build.warn_data_percentage=75 -prefs=runtime.tools.arm-none-eabi-gcc.path=/home/halbert/.arduino15/packages/arduino/tools/arm-none-eabi-gcc/7-2017q4 -prefs=runtime.tools.arm-none-eabi-gcc-7-2017q4.path=/home/halbert/.arduino15/packages/arduino/tools/arm-none-eabi-gcc/7-2017q4 -prefs=runtime.tools.bossac.path=/home/halbert/.arduino15/packages/arduino/tools/bossac/1.9.1-arduino1 -prefs=runtime.tools.bossac-1.9.1-arduino1.path=/home/halbert/.arduino15/packages/arduino/tools/bossac/1.9.1-arduino1 -prefs=runtime.tools.openocd.path=/home/halbert/.arduino15/packages/arduino/tools/openocd/0.10.0-arduino9 -prefs=runtime.tools.openocd-0.10.0-arduino9.path=/home/halbert/.arduino15/packages/arduino/tools/openocd/0.10.0-arduino9 -verbose /home/halbert/Arduino/Blink/Blink.ino
Using board 'nano33ble' from platform in folder: /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2
Using core 'arduino' from platform in folder: /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2
Detecting libraries used...
/home/halbert/.arduino15/packages/arduino/tools/arm-none-eabi-gcc/7-2017q4/bin/arm-none-eabi-g++ -c -I. -w -g -Os -nostdlib @/home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/variants/ARDUINO_NANO33BLE/defines.txt @/home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/variants/ARDUINO_NANO33BLE/cxxflags.txt -DARDUINO_ARCH_NRF52840 -mcpu=cortex-m4 -w -x c++ -E -CC -DARDUINO=10810 -DARDUINO_ARDUINO_NANO33BLE -DARDUINO_ARCH_MBED -I/home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino -I/home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/variants/ARDUINO_NANO33BLE -I/home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/api/deprecated -iprefix/home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino @/home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/variants/ARDUINO_NANO33BLE/includes.txt /tmp/arduino_build_565364/sketch/Blink.ino.cpp -o /dev/null
Generating function prototypes...
/home/halbert/.arduino15/packages/arduino/tools/arm-none-eabi-gcc/7-2017q4/bin/arm-none-eabi-g++ -c -I. -w -g -Os -nostdlib @/home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/variants/ARDUINO_NANO33BLE/defines.txt @/home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/variants/ARDUINO_NANO33BLE/cxxflags.txt -DARDUINO_ARCH_NRF52840 -mcpu=cortex-m4 -w -x c++ -E -CC -DARDUINO=10810 -DARDUINO_ARDUINO_NANO33BLE -DARDUINO_ARCH_MBED -I/home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino -I/home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/variants/ARDUINO_NANO33BLE -I/home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/api/deprecated -iprefix/home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino @/home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/variants/ARDUINO_NANO33BLE/includes.txt /tmp/arduino_build_565364/sketch/Blink.ino.cpp -o /tmp/arduino_build_565364/preproc/ctags_target_for_gcc_minus_e.cpp
/home/halbert/bin/arduino-1.8.10/tools-builder/ctags/5.8-arduino11/ctags -u --language-force=c++ -f - --c++-kinds=svpf --fields=KSTtzns --line-directives /tmp/arduino_build_565364/preproc/ctags_target_for_gcc_minus_e.cpp
Compiling sketch...
/home/halbert/.arduino15/packages/arduino/tools/arm-none-eabi-gcc/7-2017q4/bin/arm-none-eabi-g++ -c -I. -w -g -Os -nostdlib @/home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/variants/ARDUINO_NANO33BLE/defines.txt @/home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/variants/ARDUINO_NANO33BLE/cxxflags.txt -DARDUINO_ARCH_NRF52840 -MMD -mcpu=cortex-m4 -DARDUINO=10810 -DARDUINO_ARDUINO_NANO33BLE -DARDUINO_ARCH_MBED -I/home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino -I/home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/variants/ARDUINO_NANO33BLE -I/home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/api/deprecated -iprefix/home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino @/home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/variants/ARDUINO_NANO33BLE/includes.txt /tmp/arduino_build_565364/sketch/Blink.ino.cpp -o /tmp/arduino_build_565364/sketch/Blink.ino.cpp.o
In file included from /home/halbert/.arduino15/packages/arduino/tools/arm-none-eabi-gcc/7-2017q4/arm-none-eabi/include/c++/7.2.1/functional:53:0,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/platform/cxxsupport/mstd_type_traits:1205,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/platform/mbed_atomic.h:884,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/features/netsocket/InternetSocket.h:28,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/features/netsocket/UDPSocket.h:23,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/features/netsocket/nsapi.h:40,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/mbed.h:27,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/Arduino.h:32,
from /tmp/arduino_build_565364/sketch/Blink.ino.cpp:1:
./new:1:40: error: redefinition of 'const uint8_t hid_report_descriptor [195]'
const uint8_t hid_report_descriptor[195] = {
^
In file included from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/platform/Callback.h:22:0,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/rtos/Thread.h:29,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/rtos/rtos.h:28,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/mbed.h:23,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/Arduino.h:32,
from /tmp/arduino_build_565364/sketch/Blink.ino.cpp:1:
./new:1:15: note: 'const uint8_t hid_report_descriptor [195]' previously defined here
const uint8_t hid_report_descriptor[195] = {
^~~~~~~~~~~~~~~~~~~~~
In file included from /home/halbert/.arduino15/packages/arduino/tools/arm-none-eabi-gcc/7-2017q4/arm-none-eabi/include/c++/7.2.1/bits/exception_ptr.h:40:0,
from /home/halbert/.arduino15/packages/arduino/tools/arm-none-eabi-gcc/7-2017q4/arm-none-eabi/include/c++/7.2.1/exception:142,
from /home/halbert/.arduino15/packages/arduino/tools/arm-none-eabi-gcc/7-2017q4/arm-none-eabi/include/c++/7.2.1/stdexcept:38,
from /home/halbert/.arduino15/packages/arduino/tools/arm-none-eabi-gcc/7-2017q4/arm-none-eabi/include/c++/7.2.1/array:39,
from /home/halbert/.arduino15/packages/arduino/tools/arm-none-eabi-gcc/7-2017q4/arm-none-eabi/include/c++/7.2.1/tuple:39,
from /home/halbert/.arduino15/packages/arduino/tools/arm-none-eabi-gcc/7-2017q4/arm-none-eabi/include/c++/7.2.1/functional:54,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/platform/cxxsupport/mstd_type_traits:1205,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/platform/mbed_atomic.h:884,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/features/netsocket/InternetSocket.h:28,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/features/netsocket/UDPSocket.h:23,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/features/netsocket/nsapi.h:40,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/mbed.h:27,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/Arduino.h:32,
from /tmp/arduino_build_565364/sketch/Blink.ino.cpp:1:
./new:1:40: error: redefinition of 'const uint8_t hid_report_descriptor [195]'
const uint8_t hid_report_descriptor[195] = {
^
In file included from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/platform/Callback.h:22:0,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/rtos/Thread.h:29,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/rtos/rtos.h:28,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/mbed.h:23,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/Arduino.h:32,
from /tmp/arduino_build_565364/sketch/Blink.ino.cpp:1:
./new:1:15: note: 'const uint8_t hid_report_descriptor [195]' previously defined here
const uint8_t hid_report_descriptor[195] = {
^~~~~~~~~~~~~~~~~~~~~
In file included from /home/halbert/.arduino15/packages/arduino/tools/arm-none-eabi-gcc/7-2017q4/arm-none-eabi/include/c++/7.2.1/ext/new_allocator.h:33:0,
from /home/halbert/.arduino15/packages/arduino/tools/arm-none-eabi-gcc/7-2017q4/arm-none-eabi/include/c++/7.2.1/arm-none-eabi/thumb/v7e-m/fpv4-sp/softfp/bits/c++allocator.h:33,
from /home/halbert/.arduino15/packages/arduino/tools/arm-none-eabi-gcc/7-2017q4/arm-none-eabi/include/c++/7.2.1/bits/allocator.h:46,
from /home/halbert/.arduino15/packages/arduino/tools/arm-none-eabi-gcc/7-2017q4/arm-none-eabi/include/c++/7.2.1/string:41,
from /home/halbert/.arduino15/packages/arduino/tools/arm-none-eabi-gcc/7-2017q4/arm-none-eabi/include/c++/7.2.1/stdexcept:39,
from /home/halbert/.arduino15/packages/arduino/tools/arm-none-eabi-gcc/7-2017q4/arm-none-eabi/include/c++/7.2.1/array:39,
from /home/halbert/.arduino15/packages/arduino/tools/arm-none-eabi-gcc/7-2017q4/arm-none-eabi/include/c++/7.2.1/tuple:39,
from /home/halbert/.arduino15/packages/arduino/tools/arm-none-eabi-gcc/7-2017q4/arm-none-eabi/include/c++/7.2.1/functional:54,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/platform/cxxsupport/mstd_type_traits:1205,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/platform/mbed_atomic.h:884,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/features/netsocket/InternetSocket.h:28,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/features/netsocket/UDPSocket.h:23,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/features/netsocket/nsapi.h:40,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/mbed.h:27,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/Arduino.h:32,
from /tmp/arduino_build_565364/sketch/Blink.ino.cpp:1:
./new:1:40: error: redefinition of 'const uint8_t hid_report_descriptor [195]'
const uint8_t hid_report_descriptor[195] = {
^
In file included from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/platform/Callback.h:22:0,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/rtos/Thread.h:29,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/rtos/rtos.h:28,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/mbed.h:23,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/Arduino.h:32,
from /tmp/arduino_build_565364/sketch/Blink.ino.cpp:1:
./new:1:15: note: 'const uint8_t hid_report_descriptor [195]' previously defined here
const uint8_t hid_report_descriptor[195] = {
^~~~~~~~~~~~~~~~~~~~~
In file included from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/platform/SingletonPtr.h:30:0,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/features/netsocket/SocketStats.h:20,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/features/netsocket/InternetSocket.h:30,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/features/netsocket/UDPSocket.h:23,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/features/netsocket/nsapi.h:40,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/mbed.h:27,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/Arduino.h:32,
from /tmp/arduino_build_565364/sketch/Blink.ino.cpp:1:
./new:1:40: error: redefinition of 'const uint8_t hid_report_descriptor [195]'
const uint8_t hid_report_descriptor[195] = {
^
In file included from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/platform/Callback.h:22:0,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/rtos/Thread.h:29,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/rtos/rtos.h:28,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/mbed.h:23,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/Arduino.h:32,
from /tmp/arduino_build_565364/sketch/Blink.ino.cpp:1:
./new:1:15: note: 'const uint8_t hid_report_descriptor [195]' previously defined here
const uint8_t hid_report_descriptor[195] = {
^~~~~~~~~~~~~~~~~~~~~
In file included from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/events/EventQueue.h:25:0,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/events/mbed_events.h:21,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/mbed.h:32,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/Arduino.h:32,
from /tmp/arduino_build_565364/sketch/Blink.ino.cpp:1:
./new:1:40: error: redefinition of 'const uint8_t hid_report_descriptor [195]'
const uint8_t hid_report_descriptor[195] = {
^
In file included from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/platform/Callback.h:22:0,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/rtos/Thread.h:29,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/rtos/rtos.h:28,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/mbed.h:23,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/Arduino.h:32,
from /tmp/arduino_build_565364/sketch/Blink.ino.cpp:1:
./new:1:15: note: 'const uint8_t hid_report_descriptor [195]' previously defined here
const uint8_t hid_report_descriptor[195] = {
^~~~~~~~~~~~~~~~~~~~~
In file included from /home/halbert/.arduino15/packages/arduino/tools/arm-none-eabi-gcc/7-2017q4/arm-none-eabi/include/c++/7.2.1/bits/stl_construct.h:59:0,
from /home/halbert/.arduino15/packages/arduino/tools/arm-none-eabi-gcc/7-2017q4/arm-none-eabi/include/c++/7.2.1/bits/stl_tempbuf.h:60,
from /home/halbert/.arduino15/packages/arduino/tools/arm-none-eabi-gcc/7-2017q4/arm-none-eabi/include/c++/7.2.1/bits/stl_algo.h:62,
from /home/halbert/.arduino15/packages/arduino/tools/arm-none-eabi-gcc/7-2017q4/arm-none-eabi/include/c++/7.2.1/algorithm:62,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/drivers/FlashIAP.h:31,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/mbed.h:75,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/Arduino.h:32,
from /tmp/arduino_build_565364/sketch/Blink.ino.cpp:1:
./new:1:40: error: redefinition of 'const uint8_t hid_report_descriptor [195]'
const uint8_t hid_report_descriptor[195] = {
^
In file included from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/platform/Callback.h:22:0,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/rtos/Thread.h:29,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/rtos/rtos.h:28,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/mbed.h:23,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/Arduino.h:32,
from /tmp/arduino_build_565364/sketch/Blink.ino.cpp:1:
./new:1:15: note: 'const uint8_t hid_report_descriptor [195]' previously defined here
const uint8_t hid_report_descriptor[195] = {
^~~~~~~~~~~~~~~~~~~~~
In file included from /home/halbert/.arduino15/packages/arduino/tools/arm-none-eabi-gcc/7-2017q4/arm-none-eabi/include/c++/7.2.1/bits/stl_algo.h:62:0,
from /home/halbert/.arduino15/packages/arduino/tools/arm-none-eabi-gcc/7-2017q4/arm-none-eabi/include/c++/7.2.1/algorithm:62,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/drivers/FlashIAP.h:31,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/mbed.h:75,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/Arduino.h:32,
from /tmp/arduino_build_565364/sketch/Blink.ino.cpp:1:
/home/halbert/.arduino15/packages/arduino/tools/arm-none-eabi-gcc/7-2017q4/arm-none-eabi/include/c++/7.2.1/bits/stl_tempbuf.h: In function 'std::pair<_Tp*, int> std::get_temporary_buffer(std::ptrdiff_t)':
/home/halbert/.arduino15/packages/arduino/tools/arm-none-eabi-gcc/7-2017q4/arm-none-eabi/include/c++/7.2.1/bits/stl_tempbuf.h:95:13: error: 'nothrow' is not a member of 'std'
std::nothrow));
^~~~~~~
/home/halbert/.arduino15/packages/arduino/tools/arm-none-eabi-gcc/7-2017q4/arm-none-eabi/include/c++/7.2.1/bits/stl_tempbuf.h: In function 'void std::return_temporary_buffer(_Tp*)':
/home/halbert/.arduino15/packages/arduino/tools/arm-none-eabi-gcc/7-2017q4/arm-none-eabi/include/c++/7.2.1/bits/stl_tempbuf.h:113:35: error: 'nothrow' is not a member of 'std'
{ ::operator delete(__p, std::nothrow); }
^~~~~~~
In file included from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/rtos/Thread.h:29:0,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/rtos/rtos.h:28,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/mbed.h:23,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/Arduino.h:32,
from /tmp/arduino_build_565364/sketch/Blink.ino.cpp:1:
/home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/platform/Callback.h: In instantiation of 'mbed::Callback<R(ArgTs ...)>& mbed::Callback<R(ArgTs ...)>::operator=(const mbed::Callback<R(ArgTs ...)>&) [with R = void; ArgTs = {}]':
/home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/USB/PluggableUSBSerial.h:174:47: required from here
/home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/platform/Callback.h:562:13: error: no matching function for call to 'operator new(sizetype, mbed::Callback<void()>*)'
new (this) Callback(that);
^~~~~~~~~~~~~~~~~~~~~~~~~
<built-in>: note: candidate: void* operator new(unsigned int)
<built-in>: note: candidate expects 1 argument, 2 provided
/home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/platform/Callback.h: In instantiation of 'void mbed::Callback<R(ArgTs ...)>::generate(const Mbed_F&) [with Mbed_F = void (*)(); R = void; ArgTs = {}]':
/home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/platform/Callback.h:89:21: required from 'mbed::Callback<R(ArgTs ...)>::Callback(R (*)(ArgTs ...)) [with R = void; ArgTs = {}]'
/home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/rtos/Thread.h:103:5: required from here
/home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/platform/Callback.h:647:9: error: no matching function for call to 'operator new(sizetype, mbed::Callback<void()>*)'
new (this) F(f);
^~~~~~~~~~~~~~~
<built-in>: note: candidate: void* operator new(unsigned int)
<built-in>: note: candidate expects 1 argument, 2 provided
In file included from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/features/netsocket/SocketStats.h:20:0,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/features/netsocket/InternetSocket.h:30,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/features/netsocket/UDPSocket.h:23,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/features/netsocket/nsapi.h:40,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/mbed.h:27,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/Arduino.h:32,
from /tmp/arduino_build_565364/sketch/Blink.ino.cpp:1:
/home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/platform/SingletonPtr.h: In instantiation of 'T* SingletonPtr<T>::get() const [with T = rtos::Mutex]':
/home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/platform/SingletonPtr.h:150:19: required from 'T* SingletonPtr<T>::operator->() const [with T = rtos::Mutex]'
/home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/drivers/AnalogIn.h:117:15: required from here
/home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/platform/SingletonPtr.h:132:21: error: no matching function for call to 'operator new(sizetype, char [36])'
p = new (_data) T();
^~~~~~~~~~~~~~~
<built-in>: note: candidate: void* operator new(unsigned int)
<built-in>: note: candidate expects 1 argument, 2 provided
In file included from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/rtos/Thread.h:29:0,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/rtos/rtos.h:28,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/mbed.h:23,
from /home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/Arduino.h:32,
from /tmp/arduino_build_565364/sketch/Blink.ino.cpp:1:
/home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/platform/Callback.h: In instantiation of 'static void mbed::Callback<R(ArgTs ...)>::function_move(void*, const void*) [with Mbed_F = void (*)(); R = void; ArgTs = {}]':
/home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/platform/Callback.h:638:26: required from 'void mbed::Callback<R(ArgTs ...)>::generate(const Mbed_F&) [with Mbed_F = void (*)(); R = void; ArgTs = {}]'
/home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/platform/Callback.h:89:21: required from 'mbed::Callback<R(ArgTs ...)>::Callback(R (*)(ArgTs ...)) [with R = void; ArgTs = {}]'
/home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/rtos/Thread.h:103:5: required from here
/home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/platform/Callback.h:661:9: error: no matching function for call to 'operator new(sizetype, void*&)'
new (d) F(*(F *)p);
^~~~~~~~~~~~~~~~~~
<built-in>: note: candidate: void* operator new(unsigned int)
<built-in>: note: candidate expects 1 argument, 2 provided
/home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/platform/Callback.h: In instantiation of 'void mbed::Callback<R(ArgTs ...)>::generate(const Mbed_F&) [with Mbed_F = mbed::Callback<void()>::function_context<void (*)(void*), void>; R = void; ArgTs = {}]':
/home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/platform/Callback.h:152:17: required from 'mbed::Callback<R(ArgTs ...)>::Callback(R (*)(T*, ArgTs ...), U*) [with T = void; U = void; R = void; ArgTs = {}]'
/home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/platform/Callback.h:783:12: required from 'mbed::Callback<R(ArgTs ...)> mbed::callback(R (*)(T*, ArgTs ...), U*) [with T = void; U = void; R = void; ArgTs = {}]'
/home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/rtos/Thread.h:253:68: required from here
/home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/platform/Callback.h:647:9: error: no matching function for call to 'operator new(sizetype, mbed::Callback<void()>*)'
new (this) F(f);
^~~~~~~~~~~~~~~
<built-in>: note: candidate: void* operator new(unsigned int)
<built-in>: note: candidate expects 1 argument, 2 provided
/home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/platform/Callback.h: In instantiation of 'static void mbed::Callback<R(ArgTs ...)>::function_move(void*, const void*) [with Mbed_F = mbed::Callback<void()>::function_context<void (*)(void*), void>; R = void; ArgTs = {}]':
/home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/platform/Callback.h:638:26: required from 'void mbed::Callback<R(ArgTs ...)>::generate(const Mbed_F&) [with Mbed_F = mbed::Callback<void()>::function_context<void (*)(void*), void>; R = void; ArgTs = {}]'
/home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/platform/Callback.h:152:17: required from 'mbed::Callback<R(ArgTs ...)>::Callback(R (*)(T*, ArgTs ...), U*) [with T = void; U = void; R = void; ArgTs = {}]'
/home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/platform/Callback.h:783:12: required from 'mbed::Callback<R(ArgTs ...)> mbed::callback(R (*)(T*, ArgTs ...), U*) [with T = void; U = void; R = void; ArgTs = {}]'
/home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/rtos/Thread.h:253:68: required from here
/home/halbert/.arduino15/packages/arduino/hardware/mbed/1.1.2/cores/arduino/mbed/platform/Callback.h:661:9: error: no matching function for call to 'operator new(sizetype, void*&)'
new (d) F(*(F *)p);
^~~~~~~~~~~~~~~~~~
<built-in>: note: candidate: void* operator new(unsigned int)
<built-in>: note: candidate expects 1 argument, 2 provided
exit status 1
Error compiling for board Arduino Nano 33 BLE.
Comparing the Wire library with SAMD:
https://github.com/arduino/ArduinoCore-nRF528x-mbedos/blob/master/libraries/Wire/Wire.h#L48
virtual size_t write(uint8_t* data, int len);
to
size_t write(const uint8_t * data, size_t quantity);
https://github.com/arduino/ArduinoCore-samd/blob/master/libraries/Wire/Wire.h
Given the lack of EEPROM memory in the NRF52840 SoC, it would be advisable to implement a library for save/write files within the flash memory of the microcontroller. Would it be possible to use the libraries already developed for the Adafruit Feather Express nRF52840 board?
Thank you!
We have tested blink on Nano 33 BLE Sense in two different computers with same results ... we cannot compile and get the following output:
Arduino: 1.8.11 (Windows Store 1.8.28.0) (Windows 10), Board: "Arduino Nano 33 BLE"
C:\Users\xyz\AppData\Local\Temp\arduino_build_866518/core\core.a(Serial.cpp.o): In function `operator()':
C:\Users\xyz\OneDrive\Documents\ArduinoData\packages\arduino\hardware\mbed\1.1.4\cores\arduino/Serial.cpp:91: undefined reference to `yield'
C:\Users\xyz\AppData\Local\Temp\arduino_build_866518/core\core.a(Serial.cpp.o): In function `arduino::UART::write(unsigned char const*, unsigned int)':
C:\Users\xyz\OneDrive\Documents\ArduinoData\packages\arduino\hardware\mbed\1.1.4\cores\arduino/Serial.cpp:86: undefined reference to `yield'
C:\Users\xyz\AppData\Local\Temp\arduino_build_866518/core\core.a(USBSerial.cpp.o): In function `waitForPortClose()':
C:\Users\xyz\OneDrive\Documents\ArduinoData\packages\arduino\hardware\mbed\1.1.4\cores\arduino\USB/USBSerial.cpp:26: undefined reference to `millis'
C:\Users\xyz\OneDrive\Documents\ArduinoData\packages\arduino\hardware\mbed\1.1.4\cores\arduino\USB/USBSerial.cpp:30: undefined reference to `delay'
C:\Users\xyz\OneDrive\Documents\ArduinoData\packages\arduino\hardware\mbed\1.1.4\cores\arduino\USB/USBSerial.cpp:28: undefined reference to `millis'
C:\Users\xyz\OneDrive\Documents\ArduinoData\packages\arduino\hardware\mbed\1.1.4\variants\ARDUINO_NANO33BLE/libs/libmbed.a(mbed_boot_gcc_arm.o): In function `__wrap_main':
/tmp/mbed-os-program/./mbed-os/rtos/source/TARGET_CORTEX/TOOLCHAIN_GCC_ARM/mbed_boot_gcc_arm.c:77: undefined reference to `main'
collect2.exe: error: ld returned 1 exit status
exit status 1
Error compiling for board Arduino Nano 33 BLE.
Raspberry Pi 4 running Raspbian buster.
Linux rpi44gb 4.19.75-v7l+ #1270 SMP Tue Sep 24 18:51:41 BST 2019 armv7l GNU/Linux
Arduino: 1.8.10 (Linux), Board: "Arduino Nano 33 BLE"
/home/pi/arduino-1.8.10/arduino-builder -dump-prefs -logger=machine -hardware /home/pi/arduino-1.8.10/hardware -hardware /home/pi/.arduino15/packages -tools /home/pi/arduino-1.8.10/tools-builder -tools /home/pi/arduino-1.8.10/hardware/tools/avr -tools /home/pi/.arduino15/packages -built-in-libraries /home/pi/arduino-1.8.10/libraries -libraries /home/pi/Arduino/libraries -fqbn=arduino:mbed:nano33ble -vid-pid=0000_0000 -ide-version=10810 -build-path /tmp/arduino_build_113679 -warnings=none -build-cache /tmp/arduino_cache_994791 -prefs=build.warn_data_percentage=75 -prefs=runtime.tools.bossac.path=/home/pi/.arduino15/packages/arduino/tools/bossac/1.9.1-arduino1 -prefs=runtime.tools.bossac-1.9.1-arduino1.path=/home/pi/.arduino15/packages/arduino/tools/bossac/1.9.1-arduino1 -prefs=runtime.tools.arm-none-eabi-gcc.path=/home/pi/.arduino15/packages/arduino/tools/arm-none-eabi-gcc/7-2017q4 -prefs=runtime.tools.arm-none-eabi-gcc-7-2017q4.path=/home/pi/.arduino15/packages/arduino/tools/arm-none-eabi-gcc/7-2017q4 -prefs=runtime.tools.openocd.path=/home/pi/.arduino15/packages/arduino/tools/openocd/0.10.0-arduino9 -prefs=runtime.tools.openocd-0.10.0-arduino9.path=/home/pi/.arduino15/packages/arduino/tools/openocd/0.10.0-arduino9 -verbose /home/pi/Arduino/blink/blink.ino
/home/pi/arduino-1.8.10/arduino-builder -compile -logger=machine -hardware /home/pi/arduino-1.8.10/hardware -hardware /home/pi/.arduino15/packages -tools /home/pi/arduino-1.8.10/tools-builder -tools /home/pi/arduino-1.8.10/hardware/tools/avr -tools /home/pi/.arduino15/packages -built-in-libraries /home/pi/arduino-1.8.10/libraries -libraries /home/pi/Arduino/libraries -fqbn=arduino:mbed:nano33ble -vid-pid=0000_0000 -ide-version=10810 -build-path /tmp/arduino_build_113679 -warnings=none -build-cache /tmp/arduino_cache_994791 -prefs=build.warn_data_percentage=75 -prefs=runtime.tools.bossac.path=/home/pi/.arduino15/packages/arduino/tools/bossac/1.9.1-arduino1 -prefs=runtime.tools.bossac-1.9.1-arduino1.path=/home/pi/.arduino15/packages/arduino/tools/bossac/1.9.1-arduino1 -prefs=runtime.tools.arm-none-eabi-gcc.path=/home/pi/.arduino15/packages/arduino/tools/arm-none-eabi-gcc/7-2017q4 -prefs=runtime.tools.arm-none-eabi-gcc-7-2017q4.path=/home/pi/.arduino15/packages/arduino/tools/arm-none-eabi-gcc/7-2017q4 -prefs=runtime.tools.openocd.path=/home/pi/.arduino15/packages/arduino/tools/openocd/0.10.0-arduino9 -prefs=runtime.tools.openocd-0.10.0-arduino9.path=/home/pi/.arduino15/packages/arduino/tools/openocd/0.10.0-arduino9 -verbose /home/pi/Arduino/blink/blink.ino
Using board 'nano33ble' from platform in folder: /home/pi/.arduino15/packages/arduino/hardware/mbed/1.1.3
Using core 'arduino' from platform in folder: /home/pi/.arduino15/packages/arduino/hardware/mbed/1.1.3
Detecting libraries used...
/home/pi/.arduino15/packages/arduino/tools/arm-none-eabi-gcc/7-2017q4/bin/arm-none-eabi-g++ -c -w -g -Os -nostdlib @/home/pi/.arduino15/packages/arduino/hardware/mbed/1.1.3/variants/ARDUINO_NANO33BLE/defines.txt @/home/pi/.arduino15/packages/arduino/hardware/mbed/1.1.3/variants/ARDUINO_NANO33BLE/cxxflags.txt -DARDUINO_ARCH_NRF52840 -mcpu=cortex-m4 -w -x c++ -E -CC -DARDUINO=10810 -DARDUINO_ARDUINO_NANO33BLE -DARDUINO_ARCH_MBED -I/home/pi/.arduino15/packages/arduino/hardware/mbed/1.1.3/cores/arduino -I/home/pi/.arduino15/packages/arduino/hardware/mbed/1.1.3/variants/ARDUINO_NANO33BLE -I/home/pi/.arduino15/packages/arduino/hardware/mbed/1.1.3/cores/arduino/api/deprecated -iprefix/home/pi/.arduino15/packages/arduino/hardware/mbed/1.1.3/cores/arduino @/home/pi/.arduino15/packages/arduino/hardware/mbed/1.1.3/variants/ARDUINO_NANO33BLE/includes.txt /tmp/arduino_build_113679/sketch/blink.ino.cpp -o /dev/null
Error while detecting libraries included by /tmp/arduino_build_113679/sketch/blink.ino.cpp
Generating function prototypes...
/home/pi/.arduino15/packages/arduino/tools/arm-none-eabi-gcc/7-2017q4/bin/arm-none-eabi-g++ -c -w -g -Os -nostdlib @/home/pi/.arduino15/packages/arduino/hardware/mbed/1.1.3/variants/ARDUINO_NANO33BLE/defines.txt @/home/pi/.arduino15/packages/arduino/hardware/mbed/1.1.3/variants/ARDUINO_NANO33BLE/cxxflags.txt -DARDUINO_ARCH_NRF52840 -mcpu=cortex-m4 -w -x c++ -E -CC -DARDUINO=10810 -DARDUINO_ARDUINO_NANO33BLE -DARDUINO_ARCH_MBED -I/home/pi/.arduino15/packages/arduino/hardware/mbed/1.1.3/cores/arduino -I/home/pi/.arduino15/packages/arduino/hardware/mbed/1.1.3/variants/ARDUINO_NANO33BLE -I/home/pi/.arduino15/packages/arduino/hardware/mbed/1.1.3/cores/arduino/api/deprecated -iprefix/home/pi/.arduino15/packages/arduino/hardware/mbed/1.1.3/cores/arduino @/home/pi/.arduino15/packages/arduino/hardware/mbed/1.1.3/variants/ARDUINO_NANO33BLE/includes.txt /tmp/arduino_build_113679/sketch/blink.ino.cpp -o /tmp/arduino_build_113679/preproc/ctags_target_for_gcc_minus_e.cpp
arm-none-eabi-g++: error: unrecognized command line option '-std=gnu++14'
exit status 1
Error compiling for board Arduino Nano 33 BLE.
NOTE: This is a question rather than an issue. I posted it on the forum, but got no replies, so I'm re-posting here! ;)
I am playing with the new Nano 33 BLE boards and I was very surprised when I read about these boards being built on top of mBed OS!
Now I would like to connect them to an SX127x radio module (like the RFM95) to be able to send/receive stuff over LoRaWAN (TTN), but I'm not entirely sure where to start on this.
It looks like the loramac feature is part of the core, but I am not really sure where and how to load the SX127x radio library (or if it's already part of mbedOS somehow).
If there's any examples on how to get this to work, it would be greaaaaatly appreciated!!
Hi everyone,
I would like to have more than 3 concurrent BLE connections with the Arduino Nano 33 BLE. As far as i understand i have to adjust the DM_CONN_MAX in cfg_stack.h.
Unfortunately, that doesn't work, do you have any tips on what I'm doing wrong?
Thanks and kind regards!
Does this mean there is a problem with the pull-up resistors for I2C pins? Or it's simply to avoid having it pullup all the time?
Hi,
I am using the BQ25896 library with Arduino and it works well with AVRs, but it isn't working with my BLE. This is a log:
In file included from C:\Users\Giorgio\AppData\Local\Temp\arduino_modified_sketch_145569\read_properties.ino:3:0:
C:\Users\Giorgio\AppData\Local\Temp\arduino_build_584731\sketch\BQ25896.h: In instantiation of 'EmbeddedDevices::BQ25896<CELL>::BQ25896(TwoWire&) [with int CELL = 1; TwoWire = arduino::MbedI2C]':
C:\Users\Giorgio\AppData\Local\Temp\arduino_modified_sketch_145569\read_properties.ino:5:31: required from here
C:\Users\Giorgio\AppData\Local\Temp\arduino_build_584731\sketch\BQ25896.h:258:42: error: no matching function for call to 'arduino::MbedI2C::MbedI2C()'
BQ25896(TwoWire& w) : wire(&w){};
^
I think that problem is similar in issue#27 but I don't understand on how to fix the library
Can someone help me?
I am trying to create a second Hardware UART Serial Port on my Arduino NANO33 BLE, but I keep getting the error: no matching function for call to 'arduino::UART::UART(PinName&, PinName&, PinName, PinName)'
I followed your instructions at #38
but to no avail. I am attaching the code I am using as well.
#include "Arduino.h"
#include "wiring_private.h"
#include "HardwareSerial.h"
#include <Serial.h>
void setup() {
UART mySerial(digitalPinToPinName(4), digitalPinToPinName(3), NC, NC);
}
...
When I move the UART outside the setup code, I get the same thing. Please help.
Hello, I'm working on a project using this board, is it possible to have the source code of the bootloader? Is it a Bossa bootloader, right? I would like to implement a DFU mode like the Nordic bootloader.
Thank you very much!
I was using a sketch that depended on pulseIn
, it seems the core declares it but doesn't contain an implementation, so a linker error happened during the compile:
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.