dtostrf for other SAMD boards

Changed preprocessor directive to create the dtostrf function whenever
it is not defined in order to support more SAMD boards (including
MKR1000) without adding more board defines to the ifdef.
This commit is contained in:
Anne Hitchcock 2016-05-29 08:39:09 -07:00
parent e21fe8b3b6
commit e015dbbcda

View File

@ -21,7 +21,7 @@
// SOFTWARE.
#include "Adafruit_MQTT.h"
#ifdef ARDUINO_SAMD_ZERO
#ifndef dtostrf
static char *dtostrf (double val, signed char width, unsigned char prec, char *sout) {
char fmt[20];
sprintf(fmt, "%%%d.%df", width, prec);