This commit is contained in:
NikolajDanger
2022-09-05 13:31:54 +02:00
parent 6dc1439039
commit 48db731e61
17 changed files with 1004 additions and 0 deletions

View File

@ -0,0 +1,38 @@
/*
Arlo-Troubleshoot-Arduino-DHB-10-Communication
Insert web address for instructions here.
You'll re ready for the next step when the Arduino Terminal displays:
fwver = 10
hwver = 1
*/
#include <ArloRobot.h> // Include Arlo library
#include <SoftwareSerial.h> // Include SoftwareSerial library
ArloRobot Arlo; // Declare Arlo object
SoftwareSerial ArloSerial(12, 13); // Declare SoftwareSerial object
// DHB-10 -> I/O 12, DHB-10 <- I/O 13
void setup() // Setup function
{
tone(4, 3000, 2000); // Piezospeaker beep
Serial.begin(9600); // Start terminal serial port
ArloSerial.begin(19200); // Start DHB-10 serial communication
Arlo.begin(ArloSerial); // Pass to Arlo object
int fwver = Arlo.readFirmwareVer(); // Check DHB-10 firmware
Serial.print("fwver = "); // Display firmware version
Serial.println(fwver, DEC);
Serial.println(Arlo.lastExchange);
int hwver = Arlo.readHardwareVer(); // Check DHB-10 hardware
Serial.print("hwver = "); // Display hardware version
Serial.println(hwver, DEC);
Serial.println(Arlo.lastExchange);
}
void loop() {} // Nothing for main loop