Skip to content

Commit 5e9a308

Browse files
authored
Update comments.
1 parent 5806b9f commit 5e9a308

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

examples/CommunitySubmitted/HC-SR04/HC-SR04.ino

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -50,16 +50,16 @@ void loop() {
5050
// This function is called at intervals to send HC-SR04 sensor data to Cayenne.
5151
CAYENNE_OUT(DISTANCE_VIRTUAL_CHANNEL)
5252
{
53-
digitalWrite(TRIGGER_PIN, LOW);// Clears the trigger Pin
53+
digitalWrite(TRIGGER_PIN, LOW); // Clears the trigger pin
5454
delayMicroseconds(2);
5555

56-
digitalWrite(TRIGGER_PIN, HIGH); // Sets the trigger Pin on HIGH state for 10 micro seconds
56+
digitalWrite(TRIGGER_PIN, HIGH); // Sets the trigger pin on HIGH state for 10 micro seconds
5757
delayMicroseconds(10);
5858
digitalWrite(TRIGGER_PIN, LOW);
5959

60-
duration = pulseIn(ECHO_PIN, HIGH);// Reads the echo Pin, returns the sound wave travel time in microseconds
60+
duration = pulseIn(ECHO_PIN, HIGH); // Reads the echo pin, returns the sound wave travel time in microseconds
6161

62-
distance = duration * 0.034 / 2; // Calculating the distance.
62+
distance = duration * 0.034 / 2; // Calculating the distance.
6363

6464
// Send the distance value to Cayenne on proximity widget in centimeter.
6565
Cayenne.virtualWrite(DISTANCE_VIRTUAL_CHANNEL, distance, "prox", "cm");

0 commit comments

Comments
 (0)