Nick Koumaris
Published © GPL3+

Add Email Notifications to Any Robotic Vacuum Cleaning Robot

Dear friends, welcome to another tutorial! This is Nick and today we are going modify this Roomba robotic vacuum cleaner.

IntermediateFull instructions provided2 hours361
Add Email Notifications to Any Robotic Vacuum Cleaning Robot

Things used in this project

Hardware components

Wemos D1 Mini
Everything ESP Wemos D1 Mini
×1

Software apps and online services

Arduino IDE
Arduino IDE
Bluehost Web Server

Hand tools and fabrication machines

Soldering iron (generic)
Soldering iron (generic)
Hot glue gun (generic)
Hot glue gun (generic)

Story

Read more

Custom parts and enclosures

Thingiverse

https://www.thingiverse.com/thing:1786517

Code

Code snippet #1

Plain text
connectToWifi();Serial.println("Connected");  if(programState==1)
  {
   if(RoombaIsAtHome())
   {
       programState = 2;
   }
  }
}

Code snippet #2

Plain text
checkIfRoombaIsAtHome(); switch(programState)
 {
  case 2: blinkSlowly();break;
  case 3: turnLedOn();secondsAway++;break;
  case 4: turnLedOff();break;  default:break;
 }

Code snippet #3

Plain text
void sendEmail(String seconds){
  if (client.connect(servername, 80)) {  //starts client connection, checks for connection
    Serial.println("connected");
    client.println("GET /send_email.php?seconds="+seconds+" HTTP/1.1"); //Send data
    client.println("Host: educ8s.com");
    client.println("Connection: close");  //close 1.1 persistent connection  
    client.println(); //end of get request
  } 
  else {
    Serial.println("connection failed"); //error message if no client connect
    Serial.println();
  } while(client.connected() && !client.available()) delay(1); //waits for data
  while (client.connected() || client.available()) { //connected or data available
    char c = client.read(); //gets byte from ethernet buffer
      result = result+c;
    }  client.stop(); //stop client
  Serial.println(result);
  
}

Credits

Nick Koumaris

Nick Koumaris

10 projects • 104 followers
My name is Nick Koumaris and I am a software engineer from Sparta, Greece. I love building projects and share them with the world!
Contact

Comments