Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [paho-dev] MQTT C client on MCU

Hi Jerome,

the Arduino "client" is a packaging of the Embedded C++ client here:

http://git.eclipse.org/c/paho/org.eclipse.paho.mqtt.embedded-c.git/tree/MQTTClient/src

This client uses two classes which must have a platform specific implementation for it to work.  This allows it to be independent of operating system.  The classes are:

1) a timer
2) a network interface

Examples for both of these for Linux are here: http://git.eclipse.org/c/paho/org.eclipse.paho.mqtt.embedded-c.git/tree/MQTTClient/src/linux/linux.cpp

Some more information is here: http://modelbasedtesting.co.uk/?p=131

For Nuttx you might be able to use the Linux interface classes.  For those platforms that really can't use C++, there is a C version of the same code here:  http://git.eclipse.org/c/paho/org.eclipse.paho.mqtt.embedded-c.git/tree/MQTTClient-C.  I think the C++ version is easier to use, just because it's C++.

I'm also interested in contributions from any porting anyone has done.  Having ports for lots of operating systems in Paho would be great.

Ian


On 10/23/2014 10:55 PM, jerome moliere wrote:
Hi all,
I am very interested in the MQTT Arduino C client ,
I'd like to use it in a very close context , on a Cortex M3 MCU on NuttX.
Do you know if someone succeeded in such compilation ?
I've seen while grepping the code that there's a dependency with the Arduino standard header . Is it a huge work to switch to plain POSIX calls ?
The C++ code should be easy to migrate to standard plain C...

Thanks for any pointer or clue ...
Kind regards
Jerome

--
J.MOLIERE - Mentor/J


_______________________________________________
paho-dev mailing list
paho-dev@xxxxxxxxxxx
To change your delivery options, retrieve your password, or unsubscribe from this list, visit
https://dev.eclipse.org/mailman/listinfo/paho-dev

-- 
Ian Craggs                          
icraggs@xxxxxxxxxx                 IBM United Kingdom
Paho Project Lead; Committer on Mosquitto


Back to the top