Raspberry Pi configuration camera

Raspberry Pi configuration camera1. Experiment preparation2. Experimental wiring3. Open the Raspberry Pi hard serial port (this step is not required for Raspberry Pi 5)4. Experimental steps and experimental results5. Analysis of wifi configuration source code

1. Experiment preparation

2. Experimental wiring

as the picture shows image-2024022200001 image-2024022200002

3. Open the Raspberry Pi hard serial port (this step is not required for Raspberry Pi 5)

  1. First perform the following operations to map the serial port Enter sudo raspi-config in the terminal
  2. image-2022120500008
  3. image-2022120500009
  4. image-2022120500010
  5. image-2022120500011
  6. Set the hardware serial port to GPIO serial port and edit /boot/config.txt with root permissions That is, the command is:

After opening the file, add two lines at the end dtoverlay=miniuart-bt force_turbo=1 image-2022120500013 Save: Ctrl+O, exit Ctrl+X.

  1. After saving and exiting, restart the Raspberry Pi. You can see that the serial ports have been swapped. image-2022120500012 Reference link: https://blog.iyatt.com/?p=1817

4. Experimental steps and experimental results

  1. Open a new Raspberry Pi terminal and send the source code of this experiment to the Raspberry Pi.
  2. Execute the following instructions
  1. If it is opened successfully, the following results will appear image-2024022200003 This information is related to configuring the camera wifi mode, reading version information and other related operations.
  2. If the AP+STA mode is turned on, then the IP addresses of the AP+STA will have the correct IP address (this source code is in this mode) image-2024022200004 If only one mode is enabled, then sta_ip:null or ap_ip:null When sta_ip:null occurs, you need to check whether the connected wifi name and password are correct. If correct, whether only the AP mode is turned on and the STA mode is not turned on.
  3. Transparent data transmission based on IP connection
  1. View camera footage

5. Analysis of wifi configuration source code