KonradIT / gopro-py-api

Unofficial GoPro API Library for Python - connect to GoPro via WiFi.
MIT License
1.39k stars 211 forks source link

Hero 6 connectivity problems + constants.Status.STATUS.IsBusy #152

Open matejmeglic opened 3 years ago

matejmeglic commented 3 years ago

Hi.

Great repo, amazing support.

I am building a Raspberry Pi + Hero 6 Black setup that would be run through an Autonomous Timelapse Camera System and I stumbled upon a problem.

STEPS-TO-REPRODUCE:

  1. Raspberry Pi is booted
  2. Hero 6 Black is turned on --- The wifi doesn't connect automatically, there is no gopro network that Raspberry could see (is there any solution for this?)
  3. Settings - Connections - Connect App and after 3s, network is visible and automatically connected
  4. I run the simple example https://github.com/KonradIT/gopro-py-api/blob/master/examples/download_pic_in_4s.py
    • the camera gets connected,
    • photo is taken
    • photo saved on the SD card
    • then the script stops for what it seems like a minute, after that I get...

5. Error message: Traceback (most recent call last): File "gopro.py", line 12, in <module> goproCamera.downloadLastMedia(goproCamera.take_photo(1)) File "/home/pi/.local/lib/python3.7/site-packages/goprocam/GoProCamera.py", line 506, in take_photo constants.Status.STATUS.IsBusy)) ValueError: invalid literal for int() with base 10: '' SOLUTION: When the camera idles in step 4, if I go to Settings - Connections - Connect App AGAIN the process would continue.

I tried this in a loop and this needs to be done manually for the first capture in the script, then it runs for the duration of the script. It reconnects without problems even if I stop the script and run it again.

Is there a solution that would skip these manual steps for setting the GoPro Wifi network visible (available for discovery)?

Much appreciated!

PS: this might help with Issue #53 as well?