Browse Source

Fix DEBUG_XXXX_SUPPORT compile checks

fastled
Xose Pérez 7 years ago
parent
commit
8421154791
2 changed files with 6 additions and 6 deletions
  1. +5
    -5
      code/espurna/debug.ino
  2. +1
    -1
      code/espurna/mqtt.ino

+ 5
- 5
code/espurna/debug.ino View File

@ -9,7 +9,7 @@ Copyright (C) 2016-2017 by Xose Pérez <xose dot perez at gmail dot com>
#include <stdio.h>
#include <stdarg.h>
#ifdef DEBUG_UDP_SUPPORT
#if DEBUG_UDP_SUPPORT
#include <WiFiUdp.h>
WiFiUDP udpDebug;
#endif
@ -23,14 +23,14 @@ void debugSend(const char * format, ...) {
int len = ets_vsnprintf(buffer, DEBUG_MESSAGE_MAX_LENGTH, format, args);
va_end(args);
#ifdef DEBUG_SERIAL_SUPPORT
#if DEBUG_SERIAL_SUPPORT
DEBUG_PORT.printf(buffer);
if (len > DEBUG_MESSAGE_MAX_LENGTH) {
DEBUG_PORT.printf(" (...)\n");
}
#endif
#ifdef DEBUG_UDP_SUPPORT
#if DEBUG_UDP_SUPPORT
udpDebug.beginPacket(DEBUG_UDP_IP, DEBUG_UDP_PORT);
udpDebug.write(buffer);
if (len > DEBUG_MESSAGE_MAX_LENGTH) {
@ -54,14 +54,14 @@ void debugSend_P(PGM_P format, ...) {
int len = ets_vsnprintf(buffer, DEBUG_MESSAGE_MAX_LENGTH, f, args);
va_end(args);
#ifdef DEBUG_SERIAL_SUPPORT
#if DEBUG_SERIAL_SUPPORT
DEBUG_PORT.printf(buffer);
if (len > DEBUG_MESSAGE_MAX_LENGTH) {
DEBUG_PORT.printf(" (...)\n");
}
#endif
#ifdef DEBUG_UDP_SUPPORT
#if DEBUG_UDP_SUPPORT
udpDebug.beginPacket(DEBUG_UDP_IP, DEBUG_UDP_PORT);
udpDebug.write(buffer);
if (len > DEBUG_MESSAGE_MAX_LENGTH) {


+ 1
- 1
code/espurna/mqtt.ino View File

@ -461,7 +461,7 @@ void mqttConfigure() {
}
#ifdef MDNS_SUPPORT
#if MDNS_SUPPORT
boolean mqttDiscover() {
int count = MDNS.queryService("mqtt", "tcp");


Loading…
Cancel
Save