From 4c40c538af66570cc4a5a0f0b956afa98f9876db Mon Sep 17 00:00:00 2001 From: HampusM Date: Tue, 17 May 2022 14:00:39 +0200 Subject: feat(minion): respond with JSON --- minion/src/gymnasiearbete.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/minion/src/gymnasiearbete.cpp b/minion/src/gymnasiearbete.cpp index 401722c..d4cdaee 100644 --- a/minion/src/gymnasiearbete.cpp +++ b/minion/src/gymnasiearbete.cpp @@ -143,7 +143,9 @@ void loop() snprintf( response_data, RESPONSE_DATA_MAX_LENGTH, - "%u", + "{ %s: { %s: %u } }", + R"("data")", + R"("temperature")", temperature_sensor.temperature() ); -- cgit v1.2.3-18-g5258