ARMmbed

Trying to install Mbed client on Raspberry Pi but getting following errors

I am getting following error while I run ‘yotta build’ command. I am trying to install mbed client on Raspberry Pi. I am following this tutorial mbed client linux example

Error:

info: generate for target: x86-linux-native 1.0.0 at /home/pi/mbed-client-linux-example/yotta_targets/x86-linux-native
– The C compiler identification is GNU 4.6.3
– The CXX compiler identification is GNU 4.6.3
– Check for working C compiler using: Ninja
– Check for working C compiler using: Ninja – broken
CMake Error at /usr/local/share/cmake-3.2/Modules/CMakeTestCCompiler.cmake:61 (message):
The C compiler “/usr/bin/cc” is not able to compile a simple test program.

It fails with the following output:

Change Dir: /home/pi/mbed-client-linux-example/build/x86-linux-native/CMakeFiles/CMakeTmp

Run Build Command:"/usr/bin/ninja" “cmTryCompileExec1896237997”

/usr/bin/ninja: 1: /usr/bin/ninja: Syntax error: “)” unexpected

CMake will not be able to correctly generate this project.
Call Stack (most recent call first):
CMakeLists.txt:65 (project)

– Configuring incomplete, errors occurred!
See also “/home/pi/mbed-client-linux-example/build/x86-linux- native/CMakeFiles/CMakeOutput.log”.
See also “/home/pi/mbed-client-linux-example/build/x86-linux-native/CMakeFiles/CMakeError.log”.
error: command [‘cmake’, ‘-D’, ‘CMAKE_BUILD_TYPE=RelWithDebInfo’, ‘-G’, ‘Ninja’, ‘.’

mbed is not designed for microprocessor board like Raspberry pi, which runs linux…mbed is designed for use with microcontroller board like Arduino, which has like at least 10 times lower performance and 1000 time lower memory than raspberry pi.
I don’t think you can run mbed on raspberry pi and I don’t recommend you to use it neither. I mean Linux itself has already a better solution.

While the code you compile won’t itself run on a raspberry pi, it should theoretically be possible to use a raspberry pi to develop code to run on a supported mbed board (you can find the list of supported boards here: https://www.mbed.com/en/development/hardware/boards/)

Someone else was trying to do this here: Yotta on raspberry pi 2, I’m not sure how far they got.

Hope that’s somewhat helpful!

There currently is not a port for minar that runs on Linux, therefore the mbed HAL abstraction does not run on linux. That said you can build code using yotta to run on linux. See this example here where instead of mbed HAL calls it uses Linux system calls to build the mbed client on RasPi : http://blog.mbed.com/post/137562162237/mbed-client-communication-with-mbed-device

It is probably just a matter of time untill someone ports minar to linux, so stay tuned! Alternatively we accept patches!