Difference between revisions of "OpenCV4"
Jump to navigation
Jump to search
Line 1: | Line 1: | ||
− | == | + | === Overview === |
+ | This is a tutorial on how to use the python chess engine and stockfish engine | ||
+ | |||
+ | === Materials/Prerequisites === | ||
+ | Raspberry pi | ||
+ | |||
+ | === Process === | ||
+ | ==== Install OpenCV==== | ||
Follow these [https://www.pyimagesearch.com/2018/09/26/install-opencv-4-on-your-raspberry-pi/ instructions] to install OpenCV onto your Raspberry Pi using the terminal. | Follow these [https://www.pyimagesearch.com/2018/09/26/install-opencv-4-on-your-raspberry-pi/ instructions] to install OpenCV onto your Raspberry Pi using the terminal. | ||
Line 7: | Line 14: | ||
After you have successfully installed OpenCV, you will be able to use <code>import cv2</code>. If you do it on the terminal, you want to put in these code <code>source ~/.profile</code> and then <code>workon cv</code>. | After you have successfully installed OpenCV, you will be able to use <code>import cv2</code>. If you do it on the terminal, you want to put in these code <code>source ~/.profile</code> and then <code>workon cv</code>. | ||
− | ==Step 2: Capturing image== | + | ====Step 2: Capturing image==== |
Following these step to [https://www.dexterindustries.com/howto/installing-the-raspberry-pi-camera/ set up your camera]. | Following these step to [https://www.dexterindustries.com/howto/installing-the-raspberry-pi-camera/ set up your camera]. | ||
Line 26: | Line 33: | ||
*Another way to enable your camera is: go to the terminal → type in <code>sudo raspi-config</code> → select <code>Enable Camera</code> → press Enter → select <code>Finish</code> → reboot and log back on to the Raspberry Pi. | *Another way to enable your camera is: go to the terminal → type in <code>sudo raspi-config</code> → select <code>Enable Camera</code> → press Enter → select <code>Finish</code> → reboot and log back on to the Raspberry Pi. | ||
− | |||
− | |||
− | |||
− | |||
− | |||
[[Category:HowTos]] | [[Category:HowTos]] | ||
[[Category:Raspberry_Pi]] | [[Category:Raspberry_Pi]] |
Revision as of 19:15, 6 December 2018
Contents
Overview
This is a tutorial on how to use the python chess engine and stockfish engine
Materials/Prerequisites
Raspberry pi
Process
Install OpenCV
Follow these instructions to install OpenCV onto your Raspberry Pi using the terminal.
Important note: don't do make-j4
. It may freeze so it best to just do make
or make-j1
.
After you have successfully installed OpenCV, you will be able to use import cv2
. If you do it on the terminal, you want to put in these code source ~/.profile
and then workon cv
.
Step 2: Capturing image
Following these step to set up your camera.
Note: Ignoring GoPiGo installation.
In order to capture image, follow these instruction
Note:
- Use
sleep
(measured in seconds) to create a delay between the preview:time.sleep(seconds)
- Another way to enable your camera is: go to the terminal → type in
sudo raspi-config
→ selectEnable Camera
→ press Enter → selectFinish
→ reboot and log back on to the Raspberry Pi.