Its been a while since I have asked a question here. I still have many Basic Stamp projects and they are working well.
I just added a device to one of my projects that is a current sensor. In my application, the sensor reads zero current as 128. To get it to display something usable, I would just subtract 128 to get zero.
I have 16 Analog to Digital converters reading 0-5 VDC. They come in as NemoString(XX). The 100/100 is a place holder for calibrating the 0 - 256 to give me a usable number.
My line of code is:
NemoString(09) = NemoString(09) * 100/100 ' BAmps - Calibrate Here
I would like to add the following:
NemoString(09) = (NemoString(09) - 128) * 100/50 MIN 0 ' BAmps - Calibrate Here
There is a warning about using MIN 0 in the Syntax manual. Will I have a problem here?
I just would like my current reading to start at zero. I can tweek 100/50 to make any further calibration adjustments. I just don't want a little drift to roll over (under roll) my zero.