That's really cool! Could you do a video to share to show how it works?
You will probably always have to do some scaling and offsetting when pitch tracking this way, since it depends on the specifics of your output. Are you using a DC coupled audio interface?
If you start with a scalar of 1 and then pick two points some easy distance apart, e.g. 1, 2 or 3 octaves, then you can work out the scalar as the wanted (target) value divided by the actual (measured) value.
For the offset, output your 'base' value (e.g. 440Hz or zero or whatever). The offset, ie the value to subtract, is the difference between measured and target values.