MS5803-14BA Pressure Sensor Hookup Guide

Contributors: CaseyTheRobot
Favorited Favorite 6

Example Sketches

Running the Example Sketch

The library you just installed includes an example sketch that show basic operation of the MS5803. This are designed to be a starting point for writing your own code.

After you install the library, run the Arduino IDE, and open the following menu item: File / Examples / SFE_MS5803_14BA / SFE_MS5803_14BA_I2C_Demo.

Opening Example Code from the Arduino IDE Menu

When the example opens, upload it to your Arduino (remember to select the correct board type and serial port), and open the Serial Monitor to 9600 baud. You should see some diagnostic information (if it can't find the device, double check your hardware connections) followed by measurement readings.

Example Output in the Serial Monitor

Writing Your Own Sketches

The comments and code in the example sketch should get you started when writing your own sketches. In many cases you should be able to copy and paste the example code into your own sketch.