Auto Level with "Zero"

I am trying to make a leveling sensor with a high accuracy tilt sensor to both read the position of an object, and then have a voltage out put to control a solid state relay on a motor, or stepper motor. I have found many projects that do just that, but none that have a calibration button. For the purposes needed, I need to be able to level the object with a set of bubbles, tell the arduino board that this position is "zero", or level, and then I need the arduino to keep up and keep that object at level and correct for any changes in angle as a stand alone unit. I am also not sure of which arduino board that will suit these needs the best, but I do have already an x-y tilt sensor that has an voltage output based on its degree of tilt 0-5volts.

If your question is "which Arduino to use?", any 5V Arduino will work.

I suppose the question really is, would I be able to have a standalone unit that has a resetable "zero"? If so, I will certainly need help with coding that after I give it a try.

Is your concern saving the config settings after turning the unit on and off?

If so, you'll want to research the EEPROM memory on the Arduino:

It's quite straightforward to set something and remember it next time the unit is turned on.

Although the memory is a great addition, I am more looking for someway to be able to reset the tilt sensors to a new plane. I work in a precession lab where we do calibration of equipment that we stack a specified weight increment on an object and as this object deflects, we need it to stay level via a leveling machine. Now this is normally done manually with a control box that a person makes adjustments to pitch and roll actuators based off of what a set of bubble levels indicate. Now due to the precision of these calibrations, we have to specify what level is every time because a voltage change could cause the tilt sensors to read differently, or if the tilt sensors were to be dropped, or even if the temperature in the room changed, we would need to be able to account for these on an 15 to 20 minute basis.

So the process that we are looking to do, is use a normal precision bubble level to set up a level plane, then pushing a button on the arduino that would set the arduino to read these tilt sensors as a current level. At this point we would begin to apply our weights to the object and the arduino would read the tilt sensors that would then activate the actuators to make the appropriate adjustments.

A back ground on the other devices in the chain are tilt sensors from Advanced Orientation Systems inc. And to convert the signals from the tilt sensors to an analog voltage, also from Advanced Orientation Systems inc.

An Arduino can read voltages between 0 and 5V, with precision of 1 part in 1024, or in steps of about 5 mV. Is that sufficiently precise for your purposes?

If so, the Arduino could read a 0-5V sensor and apply some sort of correction, but what would you do with the result? There is no way to accurately output a voltage (i.e. a corrected sensor reading), without adding an external digital to analog converter.

The reading of 5mv should be adequate based on the out put of the digital to analog converter. and the switching voltage from the arduino is an on off condition as it will just trigger a solid state relays to control actuators.

Back to which board would be best, I was reading through some spec sheets, and am confused on the analog inputs and out puts. From my reading, there is not an arduino board that has 4 analog voltage outputs, for +/- pitch, and +/-roll.

You will need to add an external DAC to get four analog voltage outputs. Most Arduinos do not have any DAC, but the Due has two DAC channels.