Added MQTT client, better speaker handling, fixed bug in FTP server, ...
This commit is contained in:
@ -3,6 +3,7 @@
|
||||
#include <Arduino.h>
|
||||
#include "config.h"
|
||||
#include "player.h"
|
||||
#include "mqtt_client.h"
|
||||
#include <MFRC522.h>
|
||||
#include <MCP23S17/MCP23S17.h>
|
||||
|
||||
@ -10,6 +11,7 @@ class Controller {
|
||||
private:
|
||||
MFRC522* _rfid;
|
||||
MCP* _mcp;
|
||||
MQTTClient* _mqtt_client;
|
||||
bool _rfid_enabled = true;
|
||||
void _check_rfid();
|
||||
void _check_serial();
|
||||
@ -25,8 +27,10 @@ private:
|
||||
void _execute_command_help();
|
||||
unsigned long _button_last_pressed_at[NUM_BUTTONS];
|
||||
bool _check_button(uint8_t btn);
|
||||
unsigned long _last_mqtt_report_at = 0;
|
||||
void _send_mqtt_report();
|
||||
public:
|
||||
Controller(Player* p, MCP* m);
|
||||
String rfid_uid() { return String(_last_rfid_card_uid, HEX); }
|
||||
Controller(Player* p, MCP* m, MQTTClient* mqtt);
|
||||
String get_status_json();
|
||||
void loop();
|
||||
};
|
||||
|
Reference in New Issue
Block a user