munet MuSerial Class
The MuSerial class connects two muwerk MCUs via a serial connection. The serial connection automatically fowards all pub/sub messages (that are not blocked by exception lists) between the two nodes.
A main application could be to connect a non-networked MCU to a networked MCU to allow forwarding and receiving MQTT messages on MCUs without network connection via a serial link.
A system of two muwerk MCUs connected via MuSerial act to the outside world as if they were one system. Hardware (mupplets) can be addressed the same way, regardless if they are on node1 or node2.
Sample MuSerial node (without network acces)
#define __ESP__ 1
#include "scheduler.h"
#include "muserial.h"
ustd::Scheduler sched;
void setup() {
muserial.begin(&sched);
}
munet MuSerial Class
Definition: muserial.h:76
Sample MuSerial node (with network access)
#include "scheduler.h"
#include "muserial.h"
#include "net.h"
#include "mqtt.h"
#include "ota.h"
ustd::Scheduler sched(10, 16, 32);
void setup() {
net.begin(&sched);
}
munet MQTT Gateway Class
Definition: mqtt.h:79
void begin(Scheduler *_pSched, String _mqttServer="", uint16_t _mqttServerPort=1883, bool _mqttRetained=false, String _clientName="${hostname}", String _domainToken="mu", String _outDomainToken="omu", String _mqttUsername="", String _mqttPassword="", String _willTopic="", String _willMessage="")
Definition: mqtt.h:134
munet, the muwerk network class for WiFi and NTP
Definition: net.h:72
munet OTA Class
Definition: ota.h:57
void begin(Scheduler *_pSched)
Definition: ota.h:76
For a complete example, see: muwerk SerialBridge example