[{"id":"2de7c650.bbb06a","type":"tab","label":"Flow 2","disabled":false,"info":""},{"id":"3979472e.7741f8","type":"buffer-parser","z":"2de7c650.bbb06a","name":"Bulid Tags","data":"payload.data","dataType":"msg","specification":"spec","specificationType":"ui","items":[{"type":"byte","name":"lat","offset":6,"length":3,"offsetbit":0,"scale":1,"mask":""},{"type":"byte","name":"lon","offset":9,"length":3,"offsetbit":0,"scale":1,"mask":""}],"swap1":"","swap2":"","swap3":"","swap1Type":"swap","swap2Type":"swap","swap3Type":"swap","msgProperty":"payload.data","msgPropertyType":"","resultType":"keyvalue","resultTypeType":"output","multipleResult":false,"setTopic":true,"outputs":1,"x":550,"y":160,"wires":[["c896a4e7.89d428"]]},{"id":"c896a4e7.89d428","type":"function","z":"2de7c650.bbb06a","name":"","func":"var lat = (msg.payload.data.lat[0] << 24) + (msg.payload.data.lat[1] << 16) + (msg.payload.data.lat[2] << 8) \nvar lon = (msg.payload.data.lon[0] << 24) + (msg.payload.data.lon[1] << 16) + (msg.payload.data.lon[2] << 8) \n\nif (lat > 0x7FFFFFFF) { \n lat -= 0x100000000;\n}\n\nif (lon > 0x7FFFFFFF) {\n lon -= 0x100000000;\n}\n\nlat /= 10000000; \nlon /= 10000000;\n\nmsg.payload.lat = lat ;\nmsg.payload.lon = lon ;\nmsg.payload.icon = \"https://mocashforyou.com/wp-content/uploads/2018/11/truck-small.jpg\"; //set icon\nmsg.payload.marker = \"GPS\"; //set marker\n\n//cleanup things you don't want to see at the map tooltip\ndelete msg.payload.data\ndelete msg.payload.applicationID\ndelete msg.payload.applicationName\ndelete msg.payload.rxInfo\ndelete msg.payload.txInfo\n\n\n//return msg.payload; WRONG - always return msg!\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","x":720,"y":120,"wires":[["bdd8e498.b12638","96380880.f08848","8437d300.6cd4f"]]},{"id":"bdd8e498.b12638","type":"debug","z":"2de7c650.bbb06a","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":830,"y":220,"wires":[]},{"id":"d6a89147.f72ed","type":"mqtt in","z":"2de7c650.bbb06a","name":"","topic":"bachloo.rahul@gmail.com/test","qos":"0","datatype":"json","broker":"82468b32.d000d8","x":160,"y":320,"wires":[["3dbda357.6f26fc"]]},{"id":"d392d8.46d16d28","type":"base64","z":"2de7c650.bbb06a","name":"","action":"","property":"payload.data","x":560,"y":80,"wires":[["3979472e.7741f8"]]},{"id":"96380880.f08848","type":"worldmap","z":"2de7c650.bbb06a","name":"","lat":"28.3917824","lon":"76.9599744","zoom":"10","layer":"OSM","cluster":"","maxage":"","usermenu":"show","layers":"show","panit":"true","panlock":"false","zoomlock":"false","hiderightclick":"false","coords":"none","showgrid":"false","path":"/worldmap","x":800,"y":340,"wires":[]},{"id":"3dbda357.6f26fc","type":"switch","z":"2de7c650.bbb06a","name":"","property":"payload.devEUI","propertyType":"msg","rules":[{"t":"eq","v":"20635f01d1000004","vt":"str"},{"t":"eq","v":"20635f01d1000002","vt":"str"}],"checkall":"true","repair":false,"outputs":2,"x":110,"y":140,"wires":[["5245ff6c.311c5"],["da399ee3.9e885"]]},{"id":"da399ee3.9e885","type":"change","z":"2de7c650.bbb06a","name":"msg.payload.name apple","rules":[{"t":"set","p":"payload.name","pt":"msg","to":"apple","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":290,"y":180,"wires":[["d392d8.46d16d28"]]},{"id":"5245ff6c.311c5","type":"change","z":"2de7c650.bbb06a","name":"msg.payload.name pear","rules":[{"t":"set","p":"payload.name","pt":"msg","to":"pear","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":310,"y":100,"wires":[["d392d8.46d16d28"]]},{"id":"fd7801b0.509af","type":"inject","z":"2de7c650.bbb06a","name":"deveui 004","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"{\"applicationID\":\"1\",\"applicationName\":\"cloud\",\"data\":\"A0hIggANEOxCLd8jBOVh8g==\",\"devEUI\":\"20635f01d1000004\",\"deviceName\":\"abeeway tracker2\",\"fCnt\":594,\"fPort\":18,\"rxInfo\":[{\"altitude\":0,\"latitude\":0,\"loRaSNR\":8.5,\"longitude\":0,\"mac\":\"24e124fffef0a78e\",\"name\":\"24e124fffef0a78e\",\"rssi\":-47,\"time\":\"2020-11-17T11:58:23.441765Z\"}],\"time\":\"2020-11-17T11:58:23.441765Z\",\"txInfo\":{\"adr\":true,\"codeRate\":\"4/5\",\"dataRate\":{\"bandwidth\":125,\"modulation\":\"LORA\",\"spreadFactor\":7},\"frequency\":865402500}}","payloadType":"json","x":100,"y":40,"wires":[["3dbda357.6f26fc"]]},{"id":"6b728c9.4be3d74","type":"inject","z":"2de7c650.bbb06a","name":"deveui 002","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"{\"applicationID\":\"1\",\"applicationName\":\"cloud\",\"data\":\"A0hThwAJEOxGLd8jBsdI2w==\",\"devEUI\":\"20635f01d1000002\",\"deviceName\":\"abeeway tracker\",\"fCnt\":195,\"fPort\":18,\"rxInfo\":[{\"altitude\":0,\"latitude\":0,\"loRaSNR\":8.5,\"longitude\":0,\"mac\":\"24e124fffef0a78e\",\"name\":\"24e124fffef0a78e\",\"rssi\":-78,\"time\":\"2020-11-17T11:56:39.509754Z\"}],\"time\":\"2020-11-17T11:56:39.509754Z\",\"txInfo\":{\"adr\":true,\"codeRate\":\"4/5\",\"dataRate\":{\"bandwidth\":125,\"modulation\":\"LORA\",\"spreadFactor\":7},\"frequency\":865402500}}","payloadType":"json","x":120,"y":260,"wires":[["3dbda357.6f26fc"]]},{"id":"8437d300.6cd4f","type":"worldmap-tracks","z":"2de7c650.bbb06a","name":"","depth":20,"layer":"combined","x":650,"y":320,"wires":[["96380880.f08848"]]},{"id":"82468b32.d000d8","type":"mqtt-broker","name":"","broker":"maqiatto.com","port":"1883","clientid":"","usetls":false,"compatmode":false,"keepalive":"60","cleansession":true,"birthTopic":"","birthQos":"0","birthPayload":"","closeTopic":"","closeQos":"0","closePayload":"","willTopic":"","willQos":"0","willPayload":""}]
Hi,
I am guessing you have just updated the buffer parser node? (this information would be useful for people to help - context is king)
I think the buffer parser node update might not be gracefully handling the upgrade of any existing flows.
To prove my theory (and fix your flow) could you try changing the scale value (in all the buffer parser items) to 0 and deploying the changes (you can change them back to what they were afterwards)
Let me know if that works (or not) so I can release a fix.
Updated to V3.1.3 now in flows library to handle old flows better when user upgrades from earlier version.
if you dont want to (or cant) upgrade to latest version, the fix for your current installed version is
- open the EVERY buffer parser node in your flows
- click "done" (no need to change anything)
- deploy
upgrade to latest version.
OR
change the type to UINT8 then set scale to 0 or 1 on both items in the list, press DONE, press deploy.
This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.