If i try this
WiFiClient client;
if (client.connect(server, 80)) {
client.print(“GET /emoncms/input/post.json?”);
if (node > 0) {
client.print(“node=”);
client.print(node);
}
client.print("&json={");
client.print(“InputVoltage1:”);
client.print(10.00);
client.print(“BatteryVoltage1:”);
client.print(11.00);
No data on the localhost
emoncms.log
2021-02-07 12:23:46.560|ERROR|input_controller.php|{“success”: false, “message”: “Format error, json value is not numeric”} for User: 1
The error message is telling you what is wrong. It says the value is not a number. What it means is, it cannot see a number where it thinks there should be a number. Look very carefully at what you are really sending - not what you want to send.
What you are sending is node=1&json={InputVoltage1:10.00BatteryVoltage1:11.00
Now can you see what is wrong? What should there be around the names and to separate the values?
Look at the Input API Help in your emonCMS to see what the JSON format should be - or even, look at the error message itself!