Wombat Environmental Node 1.0
An environmental node for SDI-12 and digital sensors.
Loading...
Searching...
No Matches
uplinks.cpp File Reference
#include <SPIFFS.h>
#include "globals.h"
#include "DeviceConfig.h"
#include "uplinks.h"
#include "mqtt_stack.h"
#include "Utils.h"
Include dependency graph for uplinks.cpp:

Macros

#define TAG   "uplinks"
 

Enumerations

enum  mqtt_status_t { MQTT_UNINITIALISED , MQTT_LOGIN_OK , MQTT_LOGIN_FAILED }
 

Functions

static String topic ("wombat")
 
static bool process_file (const String &filename)
 
void send_messages (void)
 

Variables

static volatile mqtt_status_t mqtt_status = MQTT_UNINITIALISED
 
static char msg_buf [4096+1]
 

Macro Definition Documentation

◆ TAG

#define TAG   "uplinks"

Enumeration Type Documentation

◆ mqtt_status_t

Enumerator
MQTT_UNINITIALISED 
MQTT_LOGIN_OK 
MQTT_LOGIN_FAILED 

Function Documentation

◆ process_file()

static bool process_file ( const String &  filename)
static

Sends the given file via MQTT.

Parameters
filenamethe file to send, including the leading '/' required by SPIFFS.
Returns
true if the message was sent ok, otherwise false.

◆ send_messages()

void send_messages ( void  )

◆ topic()

static String topic ( "wombat"  )
static

Variable Documentation

◆ mqtt_status

volatile mqtt_status_t mqtt_status = MQTT_UNINITIALISED
static

◆ msg_buf

char msg_buf[4096+1]
static