https://github.com/Ildaron/Laser_control Skip to content Sign up * Why GitHub? Features - + Mobile - + Actions - + Codespaces - + Packages - + Security - + Code review - + Issues - + Integrations - + GitHub Sponsors - + Customer stories- * Team * Enterprise * Explore + Explore GitHub - Learn and contribute + Topics - + Collections - + Trending - + Learning Lab - + Open source guides - Connect with others + The ReadME Project - + Events - + Community forum - + GitHub Education - + GitHub Stars program - * Marketplace * Pricing Plans - + Compare plans - + Contact Sales - + Education - [ ] * # In this repository All GitHub | Jump to | * No suggested jump to results * # In this repository All GitHub | Jump to | * # In this user All GitHub | Jump to | * # In this repository All GitHub | Jump to | Sign in Sign up {{ message }} Ildaron / Laser_control Public * Notifications * Star 282 * Fork 7 Laser for control mosquito, weed and pest GPL-3.0 License 282 stars 7 forks Star Notifications * Code * Issues 1 * Pull requests 0 * Discussions * Actions * Projects 0 * Wiki * Security * Insights More * Code * Issues * Pull requests * Discussions * Actions * Projects * Wiki * Security * Insights master Switch branches/tags [ ] Branches Tags Could not load branches Nothing to show {{ refName }} default View all branches Could not load tags Nothing to show {{ refName }} default View all tags 1 branch 0 tags Code Latest commit @Ildaron Ildaron Create ReadMe.txt ... 803fc46 Oct 8, 2021 Create ReadMe.txt 803fc46 Git stats * 195 commits Files Permalink Failed to load latest commit information. Type Name Latest commit message Commit time 1.Motor_driver/1.1_electrical_scheme Add files via upload Dec 23, 2020 2.Jetson_code/2.1_mirror_control Add files via upload Jan 8, 2021 3.YoloV4 Update 3.2_yolov4tiny_from_colab.py Oct 8, 2021 4.Jetson_camera Create Readme.txt Jan 22, 2021 5.My_project Update ReadMe.txt Aug 6, 2021 6.Yours_Idea Create ReadMe.txt Oct 8, 2021 7.Darknet Update ReadMe.txt Oct 7, 2021 Supplementary files Add files via upload Aug 2, 2021 README.md Update README.md Aug 22, 2021 license.txt Create license.txt Jul 31, 2021 View code [ ] Laser device for neutralizing - mosquitoes, weeds and pests (in progress) A warning!! Don't use the power laser! How It Works General information Dimensions Galvanometer setting Determining the coordinates of an object X,Y - coordinate Z-coordinate Determining the angle of galvanometer mirror angle of galvanometer mirror theory angle of galvanometer mirror practice Demonstrations Publication and Citation Contacts README.md Laser device for neutralizing - mosquitoes, weeds and pests (in progress) Tweet Hardware demonstrations Hardware demonstrations Here I will post information for creating a laser device. alt tag * A warning!! * How It Works * General information * Dimensions * Galvanometer setting * Determining the coordinates of an object * Demonstrations * Publication and Citation * Contacts A warning!! Don't use the power laser! The main limiting factor in the development of this technology is the danger of the laser may damage the eyes. The laser can enter a blood vessel and clog it, it can get into a blind spot where nerves from all over the eye go to the brain, you can burn out a line of "pixels" And then the damaged retina can begin to flake off, and this is the path to complete and irreversible loss of vision. This is dangerous because a person may not notice at the beginning of damage from a laser hit: there are no pain receptors there, the brain completes objects in damaged areas (remapping of dead pixels), and only when the damaged area becomes large enough person starts to notice that some objects not visible. We can develop additional security systems, such as human detection, audio sensors, etc. But in any case, we are not able to make the installation 100% safe, since even a laser can be reflected and damage the eye of a person who is not in the field of view of the device and at a distant distance. Therefore, this technology should not be used at home. My strong recommendation - don't use the power laser! I recommend making a device that will track an object using a safe laser pointer. How It Works To detect x,y coordinates initially we used Haar cascades in RaspberryPI after that yolov4-tiny in Jetson nano. For Y coordinates - stereo vision. Calculation necessary value for the angle of mirrors. RaspberryPI/JetsonNano by SPI sends a command for galvanometer via DAC mcp4922. Electrical scheme (here). From mcp4922 bibolar analog signal go to amplifair. Finally, we have -12 and + 12 V for control positions of the mirrors. General information The principle of operation alt tag Single board computer to processes the digital signal from the camera and determines positioning to the object, and transmits the digital signal to the analog display - 3, where digital-to-analog converts the signal to the range of 0-5V. Using a board with an operational amplifier, we get a bipolar voltage - plus and minus 5 V, from which the boards with the motor driver for the galvanometer are powered - 4, from where the signal goes to galvanometers -7. The galvanometer uses mirrors to change the direction of the laser - 6. The system is powered by the power supply - 5. Cameras 2 determine the distance to the object. The camera detects mosquito and transmits data to the galvanometer, which sets the mirrors in the correct position, and then the laser turns on. Dimensions alt tag 1 - PI cameras, 2 - galvanometer, 3 - Jetson nano, 4 - adjusting the position to the object, 5 - laser device, 6 - power supply, 7 - galvanometer driver boards, 8 - analog conversion boards Galvanometer setting In practice, the maximum deflection angle of the mirrors is set at the factory, but before use, it is necessary to check, for example, according to the documentation, our galvanometer had a step width of 30, but as it turned out we have only 20 alt tag Maximum and minimum positions of galvanometer mirrors: a - lower position - 350 for x mirror; b - upper position - 550 for x mirror; c - lower position - 00 for y mirror; d - upper position - 250 for y mirror; Determining the coordinates of an object X,Y - coordinate alt tag Z-coordinate We created GUI, source here. At the expense of computer vision, the position of the object in the X, Y plane is determined - based on which its ROI area is taken. Then we use stereo vision to compile a depth map and for a given ROI with the NumPy library tool - np.average we calculated the average value for the pixels of this area, which will allow us to calculate the distance to the object. alt tag Determining the angle of galvanometer mirror angle of galvanometer mirror theory The laser beam obeys all the optical laws of physics, therefore, depending on the design of the galvanometer, the required angle of inclination of the mirror - a, can be calculated through the geometrical formulas. In our case, through the tangent of the angle a, where it is equal to the ratio of the opposing side - X(Y) (position calculated by deep learning) to the adjacent side - Z (calculated by stereo vision). alt tag angle of galvanometer mirror practice alt tag Demonstrations In this video - a laser (the red point) tries to catch a yellow LED. It is an adjusting process but in fact, instead, a yellow LED can be a mosquito, and instead, the red laser can be a powerful laser. Hardware demonstrations Publication and Citation * Ildar, R. (2021). Machine vision for low-cost remote control of mosquitoes by power laser. Journal of Real-Time Image Processing availabe here * Rakhmatulin I, Andreasen C. (2020). A Concept of a Compact and Inexpensive Device for Controlling Weeds with Laser Beams. Agronomy availabe here Contacts For any questions write to me by mail - ildar.o2010@yandex.ru About Laser for control mosquito, weed and pest Topics raspberry-pi opencv deep-learning laser triangulation mosquito machine-vision darknet galvanometer darknet-yolo kill-mosquito Resources Readme License GPL-3.0 License Releases No releases published Packages 0 No packages published Languages * Python 100.0% * (c) 2021 GitHub, Inc. * Terms * Privacy * Security * Status * Docs * Contact GitHub * Pricing * API * Training * Blog * About You can't perform that action at this time. You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session.