top of page
Search
Writer's pictureZhenduo Zhang

Week 3 Work Progress

Updated: Mar 5, 2020

1. Hardware Part

After collecting the 4tronix Initio robot kit, Robohat controller as well as a ultrasonic sensor, three of our group members started to set up the mobile robot. Attach the wheels on the robot and connect Raspberry Pi with Robohat controller so that Raspberry Pi can control the wheels via Robohat. It is crucial that the wires connecting servos with Robothat have to be exactly placed otherwise the wheels cannot receive electronic signals. The specific connection information is shown in figure 1.

Figure 1: Robohat Controller Pin Connection Information

Furthermore, a set of batteries was installed on the robot to act as a power supply for wheels. The integrate structure of our mobile robot can be seen below.

Figure 2: 4tronix Initio Robot with Sensor and Camera

 

2. Software Part

Last lab day, we encountered the obstruction caused by the brightness of the Raspberry Pi camera. We looked up this problem online and figured out a way to solve this via just 2 lines of code. The relevant information can be checked out on this webpage: https://projects.raspberrypi.org/en/projects/getting-started-with-picamera/7


camera.brightness = 75 
camera.contrast=100

Note: 75 and 100 should be constants dependant on your camera type and environment. Overall, all necessary code for OCR part can be observed as below:



cameara = piCamera()
camera.start_preview()
camera.brightness = 75
camera.contrast=100
sleep(2)
img = camera.capture('path')
camera.stop_preview()
imageRecognition =
pytesseract.image_to_string(img.open('path'),config='--psm 6')

22 views0 comments

Recent Posts

See All

Week 1 Work Progress

1.Hardware part: Three students in our group are responsible for setting up Raspberry Pi components in accordance with the official...

Comments


bottom of page