![]() |
LightHub
v4.0.0
Smarthome controller firmware
|
#include "utils.h"#include "options.h"#include "stdarg.h"#include <Wire.h>#include "main.h"#include "item.h"#include <PubSubClient.h>#include <HardwareSerial.h>Classes | |
| struct | serial_st |
Macros | |
| #define | ARDBUFFER 16 |
| #define | serialModesNum sizeof(serialModes_P)/sizeof(serial_st) |
Functions | |
| void | PrintBytes (uint8_t *addr, uint8_t count, bool newline) |
| void | SetBytes (uint8_t *addr, uint8_t count, char *out) |
| byte | HEX2DEC (char i) |
| void | SetAddr (char *out, uint8_t *addr) |
| int | getInt (char **chan) |
| itemCmd | getNumber (char **chan) |
| void | parseBytes (const char *str, char separator, byte *bytes, int maxBytes, int base) |
| void | printFloatValueToStr (float value, char *valstr) |
| int | log (const char *str,...) |
| __attribute__ ((section(".ramfunc"))) void ReadUniqueID(uint32_t *pdwUniqueID) | |
| int | _inet_aton (const char *aIPAddrString, IPAddress &aResult) |
| char * | _inet_ntoa_r (IPAddress addr, char *buf, int buflen) |
| String | toString (const IPAddress &address) |
| void | printIPAddress (IPAddress ipAddress) |
| char * | setTopic (char *buf, int8_t buflen, topicType tt, const char *suffix) |
| void | printUlongValueToStr (char *valstr, unsigned long value) |
| void | scan_i2c_bus () |
| bool | isTimeOver (uint32_t timestamp, uint32_t currTime, uint32_t time, uint32_t modulo) |
| bool | executeCommand (aJsonObject *cmd, int8_t toggle) |
| bool | executeCommand (aJsonObject *cmd, int8_t toggle, itemCmd _itemCmd, aJsonObject *defaultItem, aJsonObject *defaultEmit) |
| itemCmd | mapInt (int32_t arg, aJsonObject *map) |
| unsigned long | millisNZ (uint8_t shift) |
| serialParamType | str2SerialParam (char *str) |
Variables | |
| int8_t | configLocked |
| int8_t | ethernetIdleCount |
| PubSubClient | mqttClient |
| const char outTopic[] | PROGMEM = OUTTOPIC |
| char * | deviceName |
| aJsonObject * | topics |
| const char | HEXSTR [] = "0123456789ABCDEF" |
| #define ARDBUFFER 16 |
| #define serialModesNum sizeof(serialModes_P)/sizeof(serial_st) |
| __attribute__ | ( | (section(".ramfunc")) | ) |
| int _inet_aton | ( | const char * | aIPAddrString, |
| IPAddress & | aResult | ||
| ) |
| char* _inet_ntoa_r | ( | IPAddress | addr, |
| char * | buf, | ||
| int | buflen | ||
| ) |
Same as ipaddr_ntoa, but reentrant since a user-supplied buffer is used.
| addr | ip address in network order to convert |
| buf | target buffer where the string is stored |
| buflen | length of buf |
| bool executeCommand | ( | aJsonObject * | cmd, |
| int8_t | toggle | ||
| ) |
| bool executeCommand | ( | aJsonObject * | cmd, |
| int8_t | toggle, | ||
| itemCmd | _itemCmd, | ||
| aJsonObject * | defaultItem, | ||
| aJsonObject * | defaultEmit | ||
| ) |
| int getInt | ( | char ** | chan | ) |
| itemCmd getNumber | ( | char ** | chan | ) |
| byte HEX2DEC | ( | char | i | ) |
| bool isTimeOver | ( | uint32_t | timestamp, |
| uint32_t | currTime, | ||
| uint32_t | time, | ||
| uint32_t | modulo | ||
| ) |
| int log | ( | const char * | str, |
| ... | |||
| ) |
| itemCmd mapInt | ( | int32_t | arg, |
| aJsonObject * | map | ||
| ) |
| unsigned long millisNZ | ( | uint8_t | shift | ) |
| void parseBytes | ( | const char * | str, |
| char | separator, | ||
| byte * | bytes, | ||
| int | maxBytes, | ||
| int | base | ||
| ) |
| void PrintBytes | ( | uint8_t * | addr, |
| uint8_t | count, | ||
| bool | newline | ||
| ) |
| void printFloatValueToStr | ( | float | value, |
| char * | valstr | ||
| ) |
| void printIPAddress | ( | IPAddress | ipAddress | ) |
| void printUlongValueToStr | ( | char * | valstr, |
| unsigned long | value | ||
| ) |
| void scan_i2c_bus | ( | ) |
| void SetAddr | ( | char * | out, |
| uint8_t * | addr | ||
| ) |
| void SetBytes | ( | uint8_t * | addr, |
| uint8_t | count, | ||
| char * | out | ||
| ) |
| char* setTopic | ( | char * | buf, |
| int8_t | buflen, | ||
| topicType | tt, | ||
| const char * | suffix | ||
| ) |
| serialParamType str2SerialParam | ( | char * | str | ) |
| String toString | ( | const IPAddress & | address | ) |
|
extern |
|
extern |
|
extern |
| const char HEXSTR[] = "0123456789ABCDEF" |
|
extern |
|
extern |