Incoming JS transformation on mqtt channel

Make another temporary channel and Item to inspect the raw payload as a String, to confirm topic and payload are received as you expect.

When writing JS transforms, bear in mind parameter and result are both passed as strings. You may need to parse an input string to number before doing maths.
Parsing the string result to something suitable for the channel is the binding’s job.