Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Pressure #23

Closed
wants to merge 6 commits into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
28 changes: 28 additions & 0 deletions Pressure/Pressure.ino
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
#include <Adafruit_LPS35HW.h>

Adafruit_LPS35HW lps35hw = Adafruit_LPS35HW();

void setup() {
Serial.begin(115200);

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[cpplint] reported by reviewdog 🐶
Line ends in whitespace. Consider deleting these extra spaces. [whitespace/end_of_line] [4]

if (!lps35hw.begin_I2C()) {
//if (!lps35hw.begin_SPI(LPS_CS)) {
//if (!lps35hw.begin_SPI(LPS_CS, LPS_SCK, LPS_MISO, LPS_MOSI)) {
Serial.println("Couldn't find LPS35HW chip");
while (1);

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[cpplint] reported by reviewdog 🐶
Empty loop bodies should use {} or continue [whitespace/empty_loop_body] [5]

}
Serial.println("Found LPS35HW chip");
}

void loop() {
Serial.print("Temperature: ");
Serial.print(lps35hw.readTemperature());
Serial.println(" C");

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[cpplint] reported by reviewdog 🐶
Line ends in whitespace. Consider deleting these extra spaces. [whitespace/end_of_line] [4]

Serial.print("Pressure: ");
Serial.print(lps35hw.readPressure());
Serial.println(" hPa");

Serial.println();
delay(1000);
}
Loading