Absolutely Colin. Thank you for your reply. Sorry I was not more clear. Basically I want to send Via MQTT a Json Object similar to this {"WrmClr": 72.00}
Doing my best I could only get the 72.00 from the Node Red Dashboard as a string like {"WrmClr": "72.00"}.
The issue is the device I am sending that Json Object to does not accept it as a string. So basically what I think i need is a float object in Json with a precision on it.
When using the Node Red Dashboard it works fine with .25 increments as there would be a value like {"WrmClr": 72.25}. The problem is ONLY when the Dashboard is set to a whole number like 72. There is no decimal and I'm guessing it is not a float, so the receiving controller does not accept that value.
If we can figure out how to make it {"WrmClr": 72.0} and {"WrmClr": 73.0} etc. I would be in business!!
In the attached flow I tried converting to string and converting back, to no avail. I hope there is a way to accomplish this.
[{"id":"946e02f4.047b7","type":"tab","label":"Flow 1","disabled":false,"info":""},{"id":"1102ae7c.d77af2","type":"function","z":"946e02f4.047b7","name":"WrmClr","func":"v = msg.payload;\nmsg.payload = {\"WrmClr\": v};\nreturn msg;","outputs":1,"noerr":0,"x":786,"y":261,"wires":[["97b3b1e.4493d5"]]},{"id":"83840a54.b965c8","type":"ui_numeric","z":"946e02f4.047b7","name":"","label":"Warmer Cooler Setpoint","tooltip":"","group":"929435b0.ae4148","order":6,"width":4,"height":1,"wrap":false,"passthru":true,"topic":"","format":"{{value.toFixed(2)}}","min":"-2.0","max":"2.0","step":"0.25","x":570,"y":260,"wires":[["1102ae7c.d77af2"]]},{"id":"458752e.b8d84ac","type":"ui_numeric","z":"946e02f4.047b7","name":"","label":"OccHeatSP","tooltip":"","group":"929435b0.ae4148","order":7,"width":4,"height":1,"wrap":false,"passthru":true,"topic":"","format":"{{msg.payload}}","min":"60","max":"80","step":"0.25","x":530,"y":400,"wires":[["97f481d0.103fe"]]},{"id":"97b3b1e.4493d5","type":"debug","z":"946e02f4.047b7","name":"MQTT PUB","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","x":1010,"y":280,"wires":[]},{"id":"795b98e9.7844f8","type":"inject","z":"946e02f4.047b7","name":"","topic":"","payload":"79.500","payloadType":"str","repeat":"","crontab":"","once":false,"onceDelay":0.1,"x":270,"y":320,"wires":[["97f481d0.103fe"]]},{"id":"97f481d0.103fe","type":"function","z":"946e02f4.047b7","name":"ZNTSP","func":"i = msg.payload;\nv = i.toFixed(2);\n//var pointNum = parseFloat(v);\nmsg.payload = {\"ZNTSP\": v};\nreturn msg;","outputs":1,"noerr":0,"x":780,"y":320,"wires":[["97b3b1e.4493d5"]]},{"id":"929435b0.ae4148","type":"ui_group","z":"","name":"EasyIO FS","tab":"64f79c7b.6d08a4","order":1,"disp":true,"width":8,"collapse":false},{"id":"64f79c7b.6d08a4","type":"ui_tab","z":"","name":"Brett Home","icon":"dashboard","order":1,"disabled":false,"hidden":false}]