Quick Object Recognition in Motion Using Raspberry Pi and Camera

To not miss my updates, remember to check the public account in the upper right corner and set it as a star, take down the star and send it to me.

Quick Object Recognition in Motion Using Raspberry Pi and Camera
Quick Object Recognition in Motion Using Raspberry Pi and Camera

Recognition -> Tracking -> Distance Measurement -> 3D Display, real-time tracking of QR codes can be achieved using Raspberry Pi and a camera:

Quick Object Recognition in Motion Using Raspberry Pi and Camera
There are board card benefits at the end of the text

The project demonstrated in the video comes from Nanjing University of Posts and Telecommunications, Yan Yuheng, Liang Yiqiu, Zhou Zihan, and won the National First Prize in the 2020 National College Student Electronic Design Competition Information Technology Frontier Invitational Competition. Below are their shared design ideas, problems encountered, and solutions, which are very effective for QR code recognition projects.

The RZ/A2M MPU from Renesas can accelerate the QR code recognition process through the DRP unit.DRP is a dynamically reconfigurable processor technology that can dynamically change the configuration of its processing circuit from one clock cycle to the next.The DRP unit integrated within the MPU can implement rich image processing methods, with fast image processing speeds, thus enabling the creation of a real-time processing system for QR codes containing text and spatial information, used for complex spatial positioning and target tracking, achieving applications such as augmented reality and virtual reality.

The process of project implementation is shown in the figure below:
Quick Object Recognition in Motion Using Raspberry Pi and Camera
The development board in the above image is the core of the project, the RZ/A2M MPU development platform, based on the Cortex-A9 core, providing an additional 64MB SDRAM, which is sufficient to deploy Linux as the operating system. Additionally, the built-in Ethernet controller of the MPU provides a perfect communication network interface for the system.

Quick Object Recognition in Motion Using Raspberry Pi and Camera

The system captures special QR codes pasted on objects through the camera, and after real-time image processing accelerated by the DRP, obtains the text information of the QR code and the spatial positioning information containing distance and angle, displaying it graphically on the monitor, and outputs the calculated and fused data through the Ethernet interface.During the display, another computer is connected via a local area network, and the recognized object’s motion state information is displayed by rendering a 3D model.

Quick Object Recognition in Motion Using Raspberry Pi and Camera

The most challenging part of this project is image processing, which requires the use of image processing algorithms such as Gaussian blur, threshold segmentation, connected domain search, and polygon fitting to recognize the QR codes in the images captured by the camera, and utilize DRP to accelerate image processing.After that, the recognized QR code is decoded to obtain its identity information.Finally, the two-dimensional coordinates obtained from processing are converted to calculate its spatial coordinates, posture, and other three-dimensional information.

Quick Object Recognition in Motion Using Raspberry Pi and Camera

During the competition, I would also like to share the problems encountered and the solutions:
Initially, we used ordinary QR codes which, although capable of expressing a lot of information, had too dense black and white stripes, making them unrecognizable from a distance and unable to achieve good positioning effects.Later, we chose the Apirltag, which is specifically optimized for camera calibration and robot vision as the recognition target, sacrificing some information volume to achieve a recognition distance of over two meters at the same resolution.

Quick Object Recognition in Motion Using Raspberry Pi and Camera

If the object rotates at a large angle and the QR code is occluded, it cannot be recognized anymore, which is a major flaw of this positioning scheme. We thought of a good way to solve this problem, which is to paste multiple QR codes on different surfaces of the object to ensure that QR codes can be recognized from any angle, and automatically calculate the relative positional relationship of multiple QR codes through the system to output fused data, solving the occlusion problem of QR codes and achieving full-angle recognition.
The QR codes used in this system are sparser than ordinary QR codes to be recognized from a greater distance. It supports the recognition of multiple objects and also supports multiple QR codes pasted on a single object, solving the occlusion problem of QR codes and achieving full-angle recognition.
Simply pasting paper QR codes can achieve spatial positioning and express identity information. Such a low-cost positioning solution can be widely applied in industrial production, logistics transportation, film special effects, exhibitions, education, and other fields.Over the past few years, QR codes have greatly changed people’s lives, and we hope they can play a role in more scenarios.

Quick Object Recognition in Motion Using Raspberry Pi and Camera

After being invited by Darwin, in addition to producing the above video, considering that Renesas’s development board is difficult to purchase, we also used OpenCV and AprilTag on Raspberry Pi to recreate the core part of this project, and provided teaching explanations along with the engineering source code, welcome everyone to discuss and exchange!
The aforementioned engineering source code can be obtained by scanning the QR code below to follow Dejie Electronics:
Quick Object Recognition in Motion Using Raspberry Pi and Camera
Quick Object Recognition in Motion Using Raspberry Pi and Camera

Darwin and the globally renowned component distributor Digi-Key launched the Back2School Series Season 2, showcasing 14 projects worth remembering during university to help new and old students quickly return to campus. This content is the seventh project of the Back2School Series Season 2.

Three major benefits of Back2School, here come the board cards:

Benefit 1: Invite FriendsNew followersof Dejie Electronics’ WeChat public account, receive corresponding benefits based on the number of invitations

Quick Object Recognition in Motion Using Raspberry Pi and Camera

Note: Invitations must use the QR code above

Invite 50+: Receive a600+ RMB STM32L496 Discovery board
Invite 30+: Receive a265 RMB Wio Terminal board
Invite 10+: Receive aDarwin customized umbrella one
Activity Notice: Activity deadline: October 25, board cards are limited, first come first served. Before participating in this activity, be sure to add Nijie WeChat: 459888529. (If you don’t contact Nijie, the board cards may be gone~)
Redemption method:Please send the WeChat nicknames of the invited friends to Nijie for review, and the rewards will be issued after approval.
Quick Object Recognition in Motion Using Raspberry Pi and Camera
Benefit 2: The first offline exchange meeting of 2020 between Dejie and Darwin is about to start
November 7 (Saturday) at 1:30 PM, at JinGang Sci-Tech Park Phase II, Qixia District, Nanjing, Darwin’s Nijie Mo and Dejie, along with UP master Azheng, and Nanjing Normal University Huajun Yong will share creative projects and tell you how to create your own project.
Come on, we have prepared a lot of board card benefits, just come!
Quick Object Recognition in Motion Using Raspberry Pi and Camera

Scan the QR code to enter the offline exchange group

Benefit 3:Follow Dejie on WeChat, upload a screenshot to enter the lottery
Gifts worth 265 RMB such as Wio Terminal board, STM32F401 development board, and custom PCB ruler from Dejie and many other gifts await you:Upload a screenshot to draw board cards!
Review of other Back2School projects:
Project 1: Simple transistor + amplifier to receive signals from 1000 kilometers away
Project 2: Hands-on guide to making FPGA electronic piano play the coffin dance
Project 3: STM32 PK Raspberry Pi, giving a new way to the perpetual calendar
Project 4: Classic course design: making a signal amplifier, 3 components are enough (watch on Darwin’s B station)
Project 5: 9 modes automatically switch, with music spectrum “Canton Tower” small waist
Project 6: Tips on tracking/obstacle avoidance/PID algorithm control techniques of the god team and god car
Join the Back2School project season now to get first-hand information:
QQ Group: Search: 1081905597 to join the project exchange group
WeChat Group: Add Nijie or Momo WeChat to be added to the group!
Nijie: 459888529
Momo: 447559848
END
Quick Object Recognition in Motion Using Raspberry Pi and Camera

Recommended Reading:

Project Sharing | Electronic Competition Series | Artificial Intelligence | Postgraduate Entrance Examination
Essential Knowledge Points | Graduation Design | Switch Power Supply | Job Search
We are Nijie Mo, the founder of Darwin, a sister who only talks about technology and not flirting. The Darwin online education platform aims to serve professionals in the electronics industry, providing skill training videos covering popular topics in various subfields, such as embedded systems, FPGA, artificial intelligence, etc., and custom-tailored layered learning content for different groups, such as commonly used knowledge points, disassembly assessments, electronic competitions/intelligent vehicles/postgraduate entrance examinations, etc. Welcome to follow.
Official website: www.darwinlearns.com
B station: Darwin
QQ Group: Group 1: 786258064 (full)
Group 2: 1057755357
Quick Object Recognition in Motion Using Raspberry Pi and Camera

Leave a Comment

Your email address will not be published. Required fields are marked *