new here and to node-red.
I've got a sense hat for my Pi 3b+ and want to add a simple minus operation to the temperature sensor on the hat as kind of a correction factor. Basically (temperature - 5) = CorrectedTemp.
Not sure how to put the code into the function node.
This is how the function node looks like now:
var o = msg.payload
msg.payload = o.temperature