libMule - Microcontroller-Universal Library (that is Extendable) (mirror of https://gitlab.com/timkoi/libmule, pull-requests should be sent to GitLab, not GitHub)
libMule - Microcontroller-universal Library (that is Extendable)
libMule (or just Mule for short) is a C++ library that allows you to
create applications that will work on any microcontroller (LEGO
Mindstorms EV3 or Raspberry Pi, for example). It is similar to Qt in
some ways... except Qt is for cross-platform GUI apps and Mule is
for embedded microcontroller apps.
====== Supported platforms ======
Currently, only these platforms are supported:
- Raspberry Pi
- LEGO EV3 (Mindstorms)
- Mule Microcontroller Simulator
- Arduino Uno, Leonardo and Mega 2580
- Any Linux GPIO-capable microcontroller
Support for more platforms will be added in future releases.
See also src/platformsupport/SUPPORTED_TOOLCHAINS to get more info about
tested and officially supported toolchains
====== Building Mule ======
WARNING!!! Mule does not work on Windows unless you use MSYS2.
To build Mule for your device, you'll need:
- GNU bash and GNU make
- A toolchain for your target device with a C++ cross-compiler and ar
utility
Navigate to the source code directory of libMule and create a build
directory:
# mkdir builddir
# cd builddir
Then, run ../configure:
# ../configure -prefix=<path to the directory where libMule will be installed> -platform=<your platform name*> \
-platformcc=<path to the C cross-compiler> -platformcxx=<path to the C++ cross-compiler> \
-platformar=<path to the ar utility that produces static libraries for the TARGET device>
After configure generates a Makefile, run make:
# make
# su -c "make install"
That's it!
* Platform names for each supported device: "legoev3" for LEGO EV3,
"pigpio_rpi" for Raspberry Pi, "dummy" for the dummy platform, "microcontrollersim"
for Mule Microcontroller Simulator
Documentation and API reference are available at https://gitlab.com/timkoi/libmule/wikis/home