Erroneous temperature Inkbird Smart Thermometer IBS-TH2

Hello,

My IBS-TH2 is posting temperatures in the thousands (F) when temperature falls below ~ 20 degrees F. However, the app is indicating the correct temperature. This is a repeatable issue where I can duplicate the results. Screenshots to help.

Hello,

This has been corrected 8h ago on the dev branch :slightly_smiling_face:

Haā€¦ fixed before askedā€¦

Thank you for this project and your work on it.

1 Like

Would you mind posting an ESP32dev binary for the dev branch? I always have difficulties with Arduino IDE. Itā€™s throwing me a missing decoder.h error when trying to compile the code.

You need to add this library to your library folder GitHub - theengs/decoder: Efficient, portable and lightweight library for Internet of Things messages decoding.

Okā€¦ Iā€™m past the library issue. Now I have this error.

exit status 1
ā€˜StaticJsonDocumentā€™ does not name a type

Iā€™m sorry for these issues, my experience level isnā€™t sufficient to resolve this on my own.

No problem, here is the list of libraries that you need to have:

ArduinoJson@6.18.3

PubSubClient@2.8

I still get the same error below. Iā€™ve tried 2 different PCs and refreshing all the libararies, inlcuded the Decoder and Arduino-Log.

And here is this library list I have loaded.

LoRa
LowPower_LowPowerLab
NewRemoteSwitch
NimBLE-Arduino
OneWire
PubSubClient
rc-switch
RFM69
SmartRC-CC1101-Driver-Lib
SparkFun_BME280
SparkFun_HTU21D_Humidity_and_Temperature_Sensor_Breakout
SparkFun_SHTC3_Humidity_and_Temperature_Sensor_Library
SPIFlash
WeatherStationDataRx
WifiManager
Adafruit_AHTX0
Adafruit_BusIO
Adafruit_TSL2561
Adafruit_Unified_Sensor
arduino_36664
Arduino-INA226
ArduinoJson
Arduino-Log-master
DallasTemperature
decoder-development
DHT_sensor_library
FastLED
Infrared
IRremoteESP8266

Error

Arduino: 1.8.16 (Windows 10), Board: "ESP32 Dev Module, Disabled, Minimal SPIFFS (1.9MB APP with OTA/190KB SPIFFS), 240MHz (WiFi/BT), QIO, 80MHz, 4MB (32Mb), 921600, None"


main:58:1: error: 'StaticJsonDocument' does not name a type

 StaticJsonDocument<JSON_MSG_BUFFER> modulesBuffer;

 ^

main:59:21: error: 'modulesBuffer' was not declared in this scope

 JsonArray modules = modulesBuffer.to<JsonArray>();

                     ^

main:59:47: error: expected primary-expression before '>' token

 JsonArray modules = modulesBuffer.to<JsonArray>();

                                               ^

main:59:49: error: expected primary-expression before ')' token

 JsonArray modules = modulesBuffer.to<JsonArray>();

                                                 ^

C:\Users\JA\Documents\Arduino\RFM_MQTT_GW_25.4_dev\main\main.ino: In function 'void pub(const char*, ArduinoJson::JsonObject&)':

main:312:35: error: 'serializeJson' was not declared in this scope

   serializeJson(data, dataAsString);

                                   ^

C:\Users\JA\Documents\Arduino\RFM_MQTT_GW_25.4_dev\main\main.ino: In function 'void pub_custom_topic(const char*, ArduinoJson::JsonObject&, boolean)':

main:380:29: error: 'serializeJson' was not declared in this scope

   serializeJson(data, buffer);

                             ^

C:\Users\JA\Documents\Arduino\RFM_MQTT_GW_25.4_dev\main\main.ino: In function 'void setup()':

main:824:55: error: 'measureJson' was not declared in this scope

   serializeJson(modules, jsonChar, measureJson(modules) + 1);

                                                       ^

main:824:60: error: 'serializeJson' was not declared in this scope

   serializeJson(modules, jsonChar, measureJson(modules) + 1);

                                                            ^

C:\Users\JA\Documents\Arduino\RFM_MQTT_GW_25.4_dev\main\main.ino: In function 'void saveMqttConfig()':

main:1047:3: error: 'DynamicJsonDocument' was not declared in this scope

   DynamicJsonDocument json(512 + ota_server_cert.length() + mqtt_cert.length());

   ^

main:1048:3: error: 'json' was not declared in this scope

   json["mqtt_server"] = mqtt_server;

   ^

main:1064:35: error: 'serializeJsonPretty' was not declared in this scope

   serializeJsonPretty(json, Serial);

                                   ^

main:1065:33: error: 'serializeJson' was not declared in this scope

   serializeJson(json, configFile);

                                 ^

C:\Users\JA\Documents\Arduino\RFM_MQTT_GW_25.4_dev\main\main.ino: In function 'void setup_wifimanager(bool)':

main:1096:7: error: 'DynamicJsonDocument' was not declared in this scope

       DynamicJsonDocument json(configFile.size() * 2);

       ^

main:1097:36: error: 'json' was not declared in this scope

       auto error = deserializeJson(json, configFile);

                                    ^

main:1097:52: error: 'deserializeJson' was not declared in this scope

       auto error = deserializeJson(json, configFile);

                                                    ^

main:1101:39: error: 'serializeJsonPretty' was not declared in this scope

       serializeJsonPretty(json, Serial);

                                       ^

main:1115:55: error: expected primary-expression before 'bool'

           mqtt_secure = json["mqtt_broker_secure"].as<bool>();

                                                       ^

main:1117:51: error: expected primary-expression before 'const'

           mqtt_cert = json["mqtt_broker_cert"].as<const char*>();

                                                   ^

main:1119:59: error: expected primary-expression before '>' token

           mqtt_ss_index = json["mqtt_ss_index"].as<uint8_t>();

                                                           ^

main:1119:61: error: expected primary-expression before ')' token

           mqtt_ss_index = json["mqtt_ss_index"].as<uint8_t>();

                                                             ^

main:1123:56: error: expected primary-expression before 'const'

           ota_server_cert = json["ota_server_cert"].as<const char*>();

                                                        ^

C:\Users\JA\Documents\Arduino\RFM_MQTT_GW_25.4_dev\main\main.ino: In function 'void stateMeasures()':

main:1524:3: error: 'StaticJsonDocument' was not declared in this scope

   StaticJsonDocument<JSON_MSG_BUFFER> jsonBuffer;

   ^

main:1524:39: error: 'jsonBuffer' was not declared in this scope

   StaticJsonDocument<JSON_MSG_BUFFER> jsonBuffer;

                                       ^

main:1525:48: error: expected primary-expression before '>' token

   JsonObject SYSdata = jsonBuffer.to<JsonObject>();

                                                ^

main:1525:50: error: expected primary-expression before ')' token

   JsonObject SYSdata = jsonBuffer.to<JsonObject>();

                                                  ^

C:\Users\JA\Documents\Arduino\RFM_MQTT_GW_25.4_dev\main\main.ino: In function 'void receivingMQTT(char*, char*)':

main:1657:3: error: 'StaticJsonDocument' was not declared in this scope

   StaticJsonDocument<JSON_MSG_BUFFER> jsonBuffer;

   ^

main:1657:39: error: 'jsonBuffer' was not declared in this scope

   StaticJsonDocument<JSON_MSG_BUFFER> jsonBuffer;

                                       ^

main:1658:49: error: expected primary-expression before '>' token

   JsonObject jsondata = jsonBuffer.to<JsonObject>();

                                                 ^

main:1658:51: error: expected primary-expression before ')' token

   JsonObject jsondata = jsonBuffer.to<JsonObject>();

                                                   ^

main:1659:56: error: 'deserializeJson' was not declared in this scope

   auto error = deserializeJson(jsonBuffer, datacallback);

                                                        ^

main:1674:17: error: 'class ArduinoJson::JsonObject' has no member named 'isNull'

   if (!jsondata.isNull()) { // json object ok -> json decoding

                 ^

main:1677:35: error: 'serializeJson' was not declared in this scope

     serializeJson(jsondata, buffer);

                                   ^

C:\Users\JA\Documents\Arduino\RFM_MQTT_GW_25.4_dev\main\ZgatewayBLEConnect.ino: In member function 'virtual bool zBLEConnect::processActions(std::vector<BLEAction>&)':

ZgatewayBLEConnect:83:48: error: use of deleted function 'ArduinoJson::JsonObject::JsonObject(const ArduinoJson::JsonObject&)'

         JsonObject BLEresult = getBTJsonObject();

                                                ^

In file included from C:\Users\JA\Documents\Arduino\libraries\ArduinoJson\src/ArduinoJson.hpp:11:0,

                 from C:\Users\JA\Documents\Arduino\libraries\ArduinoJson\src/ArduinoJson.h:9,

                 from C:\Users\JA\Documents\Arduino\RFM_MQTT_GW_25.4_dev\main\main.ino:52:

C:\Users\JA\Documents\Arduino\libraries\ArduinoJson\src/ArduinoJson/JsonObject.hpp:40:7: note: 'ArduinoJson::JsonObject::JsonObject(const ArduinoJson::JsonObject&)' is implicitly deleted because the default definition would be ill-formed:

 class JsonObject : public Internals::JsonPrintable<JsonObject>,

       ^

In file included from c:\users\JA\documents\arduino\libraries\arduinojson\src\arduinojson\jsonbuffer.hpp:11:0,

                 from C:\Users\JA\Documents\Arduino\libraries\ArduinoJson\src/ArduinoJson/Deserialization/JsonParser.hpp:7,

                 from C:\Users\JA\Documents\Arduino\libraries\ArduinoJson\src/ArduinoJson/JsonBufferBase.hpp:7,

                 from C:\Users\JA\Documents\Arduino\libraries\ArduinoJson\src/ArduinoJson/DynamicJsonBuffer.hpp:7,

                 from C:\Users\JA\Documents\Arduino\libraries\ArduinoJson\src/ArduinoJson.hpp:9,

                 from C:\Users\JA\Documents\Arduino\libraries\ArduinoJson\src/ArduinoJson.h:9,

                 from C:\Users\JA\Documents\Arduino\RFM_MQTT_GW_25.4_dev\main\main.ino:52:

C:\Users\JA\Documents\Arduino\libraries\ArduinoJson\src/ArduinoJson/Data/NonCopyable.hpp:17:3: error: 'ArduinoJson::Internals::NonCopyable::NonCopyable(const ArduinoJson::Internals::NonCopyable&)' is private

   NonCopyable(const NonCopyable&);

   ^

In file included from C:\Users\JA\Documents\Arduino\libraries\ArduinoJson\src/ArduinoJson.hpp:11:0,

                 from C:\Users\JA\Documents\Arduino\libraries\ArduinoJson\src/ArduinoJson.h:9,

                 from C:\Users\JA\Documents\Arduino\RFM_MQTT_GW_25.4_dev\main\main.ino:52:

C:\Users\JA\Documents\Arduino\libraries\ArduinoJson\src/ArduinoJson/JsonObject.hpp:40:7: error: within this context

 class JsonObject : public Internals::JsonPrintable<JsonObject>,

       ^

C:\Users\JA\Documents\Arduino\RFM_MQTT_GW_25.4_dev\main\ZgatewayBLEConnect.ino: In member function 'void LYWSD03MMC_connect::notifyCB(NimBLERemoteCharacteristic*, uint8_t*, size_t, bool)':

ZgatewayBLEConnect:140:44: error: use of deleted function 'ArduinoJson::JsonObject::JsonObject(const ArduinoJson::JsonObject&)'

       JsonObject BLEdata = getBTJsonObject();

                                            ^

In file included from C:\Users\JA\Documents\Arduino\RFM_MQTT_GW_25.4_dev\main\ZgatewayBT.ino:56:0:

C:\Users\JA\Documents\Arduino\libraries\decoder-development\src/decoder.h: At global scope:

decoder.h:40:22: error: 'JsonDocument' has not been declared

   int getTheengModel(JsonDocument& doc, const char* model_id);

                      ^

ZgatewayBT:108:3: error: 'StaticJsonDocument' does not name a type

   StaticJsonDocument<JSON_MSG_BUFFER> buffer;

   ^

C:\Users\JA\Documents\Arduino\RFM_MQTT_GW_25.4_dev\main\ZgatewayBT.ino: In member function 'ArduinoJson::JsonObject& JsonBundle::createObject(const char*, bool)':

ZgatewayBT:113:5: error: 'buffer' was not declared in this scope

     buffer.clear();

     ^

ZgatewayBT:115:34: error: expected primary-expression before '>' token

     object = buffer.to<JsonObject>();

                                  ^

ZgatewayBT:115:36: error: expected primary-expression before ')' token

     object = buffer.to<JsonObject>();

                                    ^

ZgatewayBT:118:48: error: 'deserializeJson' was not declared in this scope

       auto error = deserializeJson(buffer, json);

                                                ^

C:\Users\JA\Documents\Arduino\RFM_MQTT_GW_25.4_dev\main\ZgatewayBT.ino: At global scope:

ZgatewayBT:135:41: error: use of deleted function 'JsonBundle::JsonBundle()'

 JsonBundle jsonBTBufferQueue[BTQueueSize];

                                         ^

C:\Users\JA\Documents\Arduino\RFM_MQTT_GW_25.4_dev\main\ZgatewayBT.ino:106:7: note: 'JsonBundle::JsonBundle()' is implicitly deleted because the default definition would be ill-formed:

 class JsonBundle {

       ^

ZgatewayBT:106:7: error: no matching function for call to 'ArduinoJson::JsonObject::JsonObject()'

In file included from C:\Users\JA\Documents\Arduino\libraries\ArduinoJson\src/ArduinoJson.hpp:11:0,

                 from C:\Users\JA\Documents\Arduino\libraries\ArduinoJson\src/ArduinoJson.h:9,

                 from C:\Users\JA\Documents\Arduino\RFM_MQTT_GW_25.4_dev\main\main.ino:52:

C:\Users\JA\Documents\Arduino\libraries\ArduinoJson\src/ArduinoJson/JsonObject.hpp:49:12: note: candidate: ArduinoJson::JsonObject::JsonObject(ArduinoJson::JsonBuffer*)

   explicit JsonObject(JsonBuffer* buffer) throw()

            ^

C:\Users\JA\Documents\Arduino\libraries\ArduinoJson\src/ArduinoJson/JsonObject.hpp:49:12: note:   candidate expects 1 argument, 0 provided

Multiple libraries were found for "WiFi.h"

 Used: C:\Users\JA\AppData\Local\Arduino15\packages\esp32\hardware\esp32\1.0.5\libraries\WiFi

 Not used: C:\Program Files (x86)\Arduino\libraries\WiFi

exit status 1

'StaticJsonDocument' does not name a type

Hi,

A beta is in production, should be ready in 1h there:

FYI. No action needed.
IBS-TH2 properly reporting Fahrenheit with OpenMQTTGateway v0.9.9beta

1 Like