MQTT client to test the ENC28J60-EMAC on NUCLEO-L152RE

Dependencies:   ENC28J60-EMAC

MQTT/MQTTEthernet.h

Committer:
jack1930
Date:
2021-08-20
Revision:
6:c123d9b8e6f4
Parent:
0:238f0d0c0ba3

File content as of revision 6:c123d9b8e6f4:


#if !defined(MQTTETHERNET_H)
#define MQTTETHERNET_H

#include "MQTTmbed.h"
#include "EthernetInterface.h"
#include "MQTTSocket.h"

class MQTTEthernet : public MQTTSocket
{
public:    
    MQTTEthernet() : MQTTSocket(&eth)
    {
        eth.connect();
    }
    
    EthernetInterface& getEth()
    {
        return eth;
    }
    
private:

    EthernetInterface eth;
    
};


#endif