Skip to content

Commit

Permalink
Merge pull request #97 from kintel/uno-wifi
Browse files Browse the repository at this point in the history
Add support for float formatting on Arduino UNO Wifi Rev. 2
  • Loading branch information
brentru authored Nov 13, 2019
2 parents aea932d + fddf6d2 commit 23985c6
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion library.properties
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
name=Adafruit IO Arduino
version=3.2.2
version=3.2.3
author=Adafruit
maintainer=Adafruit <[email protected]>
sentence=Arduino library to access Adafruit IO.
Expand Down
6 changes: 3 additions & 3 deletions src/AdafruitIO_Data.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -180,7 +180,7 @@ void AdafruitIO_Data::setValue(float value, double lat, double lon, double ele,
{
memset(_value, 0, AIO_DATA_LENGTH);

#if defined(ARDUINO_ARCH_AVR)
#if defined(ARDUINO_ARCH_AVR) || defined(ARDUINO_ARCH_MEGAAVR)
// Use avrlibc dtostre function on AVR platforms.
dtostre(value, _value, precision, 0);
#elif defined(ESP8266)
Expand All @@ -199,7 +199,7 @@ void AdafruitIO_Data::setValue(double value, double lat, double lon, double ele,
{
memset(_value, 0, AIO_DATA_LENGTH);

#if defined(ARDUINO_ARCH_AVR)
#if defined(ARDUINO_ARCH_AVR) || defined(ARDUINO_ARCH_MEGAAVR)
// Use avrlibc dtostre function on AVR platforms.
dtostre(value, _value, precision, 0);
#elif defined(ESP8266)
Expand Down Expand Up @@ -429,7 +429,7 @@ char* AdafruitIO_Data::charFromDouble(double d, int precision)
{
memset(_double_buffer, 0, sizeof(_double_buffer));

#if defined(ARDUINO_ARCH_AVR)
#if defined(ARDUINO_ARCH_AVR) || defined(ARDUINO_ARCH_MEGAAVR)
// Use avrlibc dtostre function on AVR platforms.
dtostre(d, _double_buffer, 10, 0);
#elif defined(ESP8266)
Expand Down

0 comments on commit 23985c6

Please sign in to comment.