aboutsummaryrefslogtreecommitdiff
path: root/libraries/Wire/examples/SFRRanger_reader
diff options
context:
space:
mode:
authorDave Madison <dmadison@users.noreply.github.com>2022-02-22 02:32:00 -0500
committerGitHub <noreply@github.com>2022-02-22 02:32:00 -0500
commitd52b6ea456dd145025659359847e3ba8b58b5a27 (patch)
tree7c106c4e741e47ef5dd9f4f45529fd6a6010a896 /libraries/Wire/examples/SFRRanger_reader
parentf47a97522dc28c16c432422e3085035de69cfaf6 (diff)
parent6f5881438af5b416fe83b0721a51215b9833498c (diff)
Merge pull request #14 from dmadison/upstream-1.8.4
Merge upstream tag '1.8.4'
Diffstat (limited to 'libraries/Wire/examples/SFRRanger_reader')
-rw-r--r--libraries/Wire/examples/SFRRanger_reader/SFRRanger_reader.ino8
1 files changed, 4 insertions, 4 deletions
diff --git a/libraries/Wire/examples/SFRRanger_reader/SFRRanger_reader.ino b/libraries/Wire/examples/SFRRanger_reader/SFRRanger_reader.ino
index 4d0a68f..aeb1a9c 100644
--- a/libraries/Wire/examples/SFRRanger_reader/SFRRanger_reader.ino
+++ b/libraries/Wire/examples/SFRRanger_reader/SFRRanger_reader.ino
@@ -3,7 +3,7 @@
// and James Tichenor <http://www.jamestichenor.net>
// Demonstrates use of the Wire library reading data from the
-// Devantech Utrasonic Rangers SFR08 and SFR10
+// Devantech Ultrasonic Rangers SFR08 and SFR10
// Created 29 April 2006
@@ -13,8 +13,8 @@
#include <Wire.h>
void setup() {
- Wire.begin(); // join i2c bus (address optional for master)
- Serial.begin(9600); // start serial communication at 9600bps
+ Wire.begin(); // join I2C bus (address optional for master)
+ Serial.begin(9600); // start serial communication at 9600 bps
}
int reading = 0;
@@ -23,7 +23,7 @@ void loop() {
// step 1: instruct sensor to read echoes
Wire.beginTransmission(112); // transmit to device #112 (0x70)
// the address specified in the datasheet is 224 (0xE0)
- // but i2c adressing uses the high 7 bits so it's 112
+ // but I2C addressing uses the high 7 bits so it's 112
Wire.write(byte(0x00)); // sets register pointer to the command register (0x00)
Wire.write(byte(0x50)); // command sensor to measure in "inches" (0x50)
// use 0x51 for centimeters