Issue compiling for mbed & rtos


I’ve updated an older installation of platformio core from v3.3.1 to v3.4.1 but I’m now unable to compile my project.

I had issues with the rtos library but found the documentation on adding the build flags for that. Still not able to compile.

Currently I think I’m having a problem compiling the rtos library because I’m using the Mutex class which is giving me an error in the compiler output:

C:\Users\Bobby\.platformio\packages\framework-mbed/rtos/Mutex.h: In member function 'rtos::Mutex& rtos::Mutex::operator=(const rtos::Mu
C:\Users\Bobby\.platformio\packages\framework-mbed/rtos/Mutex.h:43:7: error: 'mbed::NonCopyable<T>& mbed::NonCopyable<T>::operator=(con
st mbed::NonCopyable<T>&) [with T = rtos::Mutex]' is private within this context
class Mutex : private mbed::NonCopyable<Mutex> {

I then have missing .o files that cause problems.

My platformio.ini for reference:

platform = ststm32
board = nucleo_f103rb
framework = mbed
lib_ignore = mbed-dsp
lib_deps = 

On a related note, the ststm32 platform lists the toolchain as
Requirements: >=1.40803.0,<1.40805.0
but when I run
pio run
it insists on installing toolchain-gccarmnoneeabi @ >=1.60301.0
Could this be related?

I do not use RTOS, so I don’t know about that. I did have the issue with the version and was able to ‘solve’ it, see here

See Mbed — PlatformIO latest documentation

If you need to use specific version of mbed, see Redirecting...

Here is a history: Releases · platformio/platform-ststm32 · GitHub

So, your config should look like:

platform = ststm32@3.3.0
board = nucleo_f103rb