element14 Community
element14 Community
    Register Log In
  • Site
  • Search
  • Log In Register
  • About Us
  • Community Hub
    Community Hub
    • What's New on element14
    • Feedback and Support
    • Benefits of Membership
    • Personal Blogs
    • Members Area
    • Achievement Levels
  • Learn
    Learn
    • Ask an Expert
    • eBooks
    • element14 presents
    • Learning Center
    • Tech Spotlight
    • STEM Academy
    • Webinars, Training and Events
    • Learning Groups
  • Technologies
    Technologies
    • 3D Printing
    • FPGA
    • Industrial Automation
    • Internet of Things
    • Power & Energy
    • Sensors
    • Technology Groups
  • Challenges & Projects
    Challenges & Projects
    • Design Challenges
    • element14 presents Projects
    • Project14
    • Arduino Projects
    • Raspberry Pi Projects
    • Project Groups
  • Products
    Products
    • Arduino
    • Avnet Boards Community
    • Dev Tools
    • Manufacturers
    • Multicomp Pro
    • Product Groups
    • Raspberry Pi
    • RoadTests & Reviews
  • Store
    Store
    • Visit Your Store
    • Choose another store...
      • Europe
      •  Austria (German)
      •  Belgium (Dutch, French)
      •  Bulgaria (Bulgarian)
      •  Czech Republic (Czech)
      •  Denmark (Danish)
      •  Estonia (Estonian)
      •  Finland (Finnish)
      •  France (French)
      •  Germany (German)
      •  Hungary (Hungarian)
      •  Ireland
      •  Israel
      •  Italy (Italian)
      •  Latvia (Latvian)
      •  
      •  Lithuania (Lithuanian)
      •  Netherlands (Dutch)
      •  Norway (Norwegian)
      •  Poland (Polish)
      •  Portugal (Portuguese)
      •  Romania (Romanian)
      •  Russia (Russian)
      •  Slovakia (Slovak)
      •  Slovenia (Slovenian)
      •  Spain (Spanish)
      •  Sweden (Swedish)
      •  Switzerland(German, French)
      •  Turkey (Turkish)
      •  United Kingdom
      • Asia Pacific
      •  Australia
      •  China
      •  Hong Kong
      •  India
      •  Korea (Korean)
      •  Malaysia
      •  New Zealand
      •  Philippines
      •  Singapore
      •  Taiwan
      •  Thailand (Thai)
      • Americas
      •  Brazil (Portuguese)
      •  Canada
      •  Mexico (Spanish)
      •  United States
      Can't find the country/region you're looking for? Visit our export site or find a local distributor.
  • Translate
  • Profile
  • Settings
Experimenting with Waterproof Connectors
  • Challenges & Projects
  • Design Challenges
  • Experimenting with Waterproof Connectors
  • More
  • Cancel
Experimenting with Waterproof Connectors
Blog Experimenting with Waterproof Connectors #6 Running the RovingEye
  • Blog
  • Forum
  • Documents
  • Files
  • Members
  • Mentions
  • Sub-Groups
  • Tags
  • More
  • Cancel
  • New
Join Experimenting with Waterproof Connectors to participate - click to join for free!
  • Share
  • More
  • Cancel
Group Actions
  • Group RSS
  • More
  • Cancel
Engagement
  • Author Author: fyaocn
  • Date Created: 6 Jun 2023 9:04 AM Date Created
  • Views 362 views
  • Likes 7 likes
  • Comments 0 comments
Related
Recommended

Experimenting with Waterproof Connectors #6 Running the RovingEye

fyaocn
fyaocn
6 Jun 2023

RovingEye Show

Table of Contents

  • 1 The Idea of Roving Eye
  • 2 Waterproof Connectors define how robust the eye is.
  • 3 OpenVINO and Objective Detection
  • 4 Roving the Eye
  • 5 The Waterproof  USB Camera and Upgrade
  • 6 Running the Roving Eye
  • 7 Summary

1 The Idea of Roving Eye

There are various cases, in which continuously unmanned surveilling is necessary in remote or desolate places.

image

Equipped one water proof  camera on moving platform can build one roving eye, helping people a lot.

With Latta panda SBC well protected in waterproof enclosure and high-quality waterproof connectors, this project can provide affordable solution and quick out-of-box deployment. Just as roving eye can do.

image

2 Waterproof Connectors define how robust the eye is.

Waterproof connectors are well designed, need proper attentions when assembling  parts. As small as on spring-washer or rubber ring altogether play important roles, and can not be ignored. The Experimenting with Waterproof Connectors #5 Waterproof test on Connectors - element14 Community show the result.

image

Here are outside connectors to connected with USB camera and Ethernet cable.

image

With wires plugged

image

USB connector inside

image

Four wire of RJ45 is used as two Motor control cord, inside part,

image

and outside connecting, with one ethernet cable connecting two RJ-45 connectors

imageimage

3 OpenVINO and Object Detection

OpenVINO is very good in this project and play object detection very quick, as

 Experimenting with Waterproof Connectors #3 OpenVINO in LettaPanda - element14 Community  and

Experimenting with Waterproof Connectors #4 Hybrid Coding with Arduino, Visual C# and Python for LettaPanda - element14 Community 

shows.

image

Start the python loop and detect object in video in No.0 camera port,

run_object_detection(source=0, flip=True, use_popup=False)

if __name__ == '__main__':    
    # Initialize OpenVINO Runtime.
    ie_core = ov.Core()
    model = ie_core.read_model(model=converted_model_path)
    compiled_model = ie_core.compile_model(model=model, device_name="CPU")
    input_layer = compiled_model.input(0)
    output_layer = compiled_model.output(0)
    height, width = list(input_layer.shape)[1:3]
    input_layer.any_name, output_layer.any_name

    run_object_detection(source=0, flip=True, use_popup=False)
    print("End of Roving script.")

At the same time , download standard firmata in Arduino Lenado Core,

void loop()
{
  byte pin, analogPin;
  checkDigitalInputs();
  while (Firmata.available())
    Firmata.processInput();
  currentMillis = millis();
  if (currentMillis - previousMillis > samplingInterval) {
    previousMillis += samplingInterval;
    /* ANALOGREAD - do all analogReads() at the configured sampling interval */
    for (pin = 0; pin < TOTAL_PINS; pin++) {
      if (IS_PIN_ANALOG(pin) && Firmata.getPinMode(pin) == PIN_MODE_ANALOG) {
        analogPin = PIN_TO_ANALOG(pin);
        if (analogInputsToReport & (1 << analogPin)) {
          Firmata.sendAnalog(analogPin, analogRead(analogPin));
        }
      }
    }
    // report i2c data for all device with read continuous mode enabled
    if (queryIndex > -1) {
      for (byte i = 0; i < queryIndex + 1; i++) {
        readAndReportData(query[i].addr, query[i].reg, query[i].bytes, query[i].stopTX);
      }
    }
  }

#ifdef FIRMATA_SERIAL_FEATURE

Then control the arduino core pins by arduino c# library .

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Threading;
using LattePanda.Firmata;
namespace rovingEye
{
    class Program
    {
        static void Main(string[] args)
        {
            string motormode;
            int motorduraion =200;
            Arduino arduino = new Arduino();
            arduino.pinMode(4, Arduino.OUTPUT);//Set the digital pin 4 as output   
            arduino.pinMode(5, Arduino.OUTPUT);//Set the digital pin 5 as output 
            arduino.pinMode(6, Arduino.OUTPUT);//Set the digital pin 6 as output 
            arduino.pinMode(7, Arduino.OUTPUT);//Set the digital pin 7 as output 
            //Console.WriteLine("Hello, rovingEye.");
            if (args.Length > 0)
            {

                motormode = args[0];
                if (motormode is "up") {
                    Console.WriteLine($"Direction={motormode}");
                    arduino.digitalWrite(4, Arduino.LOW);//set the LED off  
                    arduino.digitalWrite(5, Arduino.HIGH);//set the LED off    
                    Thread.Sleep(motorduraion);
                } else if (motormode is "down")
                {
                    Console.WriteLine($"Direction={motormode}");
                    arduino.digitalWrite(5, Arduino.LOW);//set the LED off  
                    arduino.digitalWrite(4, Arduino.HIGH);//set the LED off     
                    Thread.Sleep(motorduraion);
                }
                else if (motormode is "left")
                {
                    Console.WriteLine($"Direction={motormode}");
                    arduino.digitalWrite(6, Arduino.LOW);//set the LED off  
                    arduino.digitalWrite(7, Arduino.HIGH);//set the LED off    
                    Thread.Sleep(motorduraion);
                }
                else if (motormode is "right")
                {
                    Console.WriteLine($"Direction={motormode}");
                    arduino.digitalWrite(7, Arduino.LOW);//set the LED off  
                    arduino.digitalWrite(6, Arduino.HIGH);//set the LED off   
                    Thread.Sleep(motorduraion);
                }
                else
                {
                    Console.WriteLine($"Direction= No operaion.");
                }
                // Reset the motor to still for new command,
                arduino.digitalWrite(4, Arduino.LOW);//set the LED off  
                arduino.digitalWrite(5, Arduino.LOW);//set the LED off  
                arduino.digitalWrite(6, Arduino.LOW);//set the LED off  
                arduino.digitalWrite(7, Arduino.LOW);//set the LED off  
                Thread.Sleep(200);

            }
            return;
        }
    }
}

4 Roving the Eye

The waterproof enclosure with Waterproof enclosure can be fixed on crawler-type platform to moving around. The view under the platform.

image

Wiring parts inside and power the LatterPanda SBC

image

All parts included in waterproof enclosure, screw tight and fixed on the platform.

image

5 The Waterproof  USB Camera and Upgrade

I have used this waterproof camera in sewage cleaning, it works fine. But the resolution is not so good.

image

Upgrade the USB camera if better one can be found. The 720p logitech USB camera is good in quliy, but can not fit for outdoor purpose.

image

In this project, the first camera is used. 

image

Upgraded project can use two cameras together for better view range. 

6 Summary

This project shows how waterproof connectors be used and the importance of the waterproof function. 

  • Sign in to reply
element14 Community

element14 is the first online community specifically for engineers. Connect with your peers and get expert answers to your questions.

  • Members
  • Learn
  • Technologies
  • Challenges & Projects
  • Products
  • Store
  • About Us
  • Feedback & Support
  • FAQs
  • Terms of Use
  • Privacy Policy
  • Legal and Copyright Notices
  • Sitemap
  • Cookies

An Avnet Company © 2025 Premier Farnell Limited. All Rights Reserved.

Premier Farnell Ltd, registered in England and Wales (no 00876412), registered office: Farnell House, Forge Lane, Leeds LS12 2NE.

ICP 备案号 10220084.

Follow element14

  • X
  • Facebook
  • linkedin
  • YouTube