Closed fusi0nfire closed 9 years ago
Hey @fusi0nfire,
This repository has no user interface. Did you mean to post this issue to the GoProControllerUI repo? Assuming you are talking about GoProControllerUI, I imagine the Angular app is looking for the API in the wrong location. You have to set the api_root
value in app/app.js. This step is currently missing from the documentation. Thanks for pointing it out!
By the way, the API itself is built on the Django REST Framework which also includes a browsable interface that you can use without GoProControllerUI. If you go to /api
from a web browser, you should also be able to add and remove cameras from there.
Let me know if that works for you!
Hey Josh,
Thank you for working with me on this. I did indeed post this in the wrong spot.
Should app.value('api_root', 'X') look like '/home/darin/GoProController' or "http://localhost/api'
I currently have '/home/darin/GoProController'. When I go to http://localhost/api I can add a camera it seems, but the main webpage still has a disconnected icon at the top of the webpage. The add camera control still id not work. What am I missing to get the camera UI connected to the api?
This is an HTTP API, so the value should be something like http://localhost/api
.
That did not work either. Is their a debugging trick or log I can dump that would be more descriptive?
Hmmm. Is http://localhost/api
indeed the location of your API? If it is using some other port besides 80, you'd need to specify that too. (Like http://localhost:8000/api
for example.)
You should be able to open your browser's console to see what the actual error message is. If you are using Chrome, click Menu >> More Tools >> Developer Tools.
FYI, the GoProControllerUI documentation has been updated to include a note about setting api_root
. Thanks agian.
Here is the message from the console.
GET http://jvillbrandt-ubuntu/api/cameras net::ERR_NAME_NOT_RESOLVEDangular.js:8013
looks like there is still a reference but I'm having trouble locating it
Alright, that means api_root
hasn't actually been changed yet...
Did you rebuild the website after setting the value? Open GoProControllerUI/app/app.js, edit
api_root, and then re-build with
npm startor
npm run-script build`.
Is http://localhost/api
actually the location of your API?
Are you trying to run GoProController through Apache or through the development Python server? Are you trying to access from the same machine that you are running GoProController on or a different machine?
I am trying to access the UI from the local machine.
I can verify that the API sees the gopro and goproctrl can control the gopro from the command line. I just can't figure out why the UI won't talk to the API. Both were downloaded and installed to my /home/"user"/ folder.
I'm using the apache setup described in the Production setup.
http://localhost/api when entered into a browser will take me to the API where i did add a camera.
Could I send zip files that would be diagnostic? Node version? Is there a graceful way to start over?
Given this information, setting line 28 in app/app.js to app.value('api_root', 'http://localhost/api');
should be the correct address if you only care about using the UI from that machine.
Do you have the latest commits from the master branch on both GoProController and GoProControllerUI? Otherwise, I'm not sure what else I can do to help you with this. Everything else works for me and I am reasonably confident that I have all of my bases covered here.
I changed the app.value('api_root', 'http://localhost/api'); to the machine nmae and all functioned well.
When I click add camera nothing happens. I cannot figure out how to add my gopros to this UI/API. Everything seems to be working otherwise. The webpage/UI appears just like the screenshot and I did not encounter any issues or warnings during the install.