Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Is anyone using this? #1

Open
cikasfm opened this issue Dec 29, 2019 · 1 comment
Open

Is anyone using this? #1

cikasfm opened this issue Dec 29, 2019 · 1 comment

Comments

@cikasfm
Copy link

cikasfm commented Dec 29, 2019

Hi @AnthonyV44 / authors,

I'm trying to use the ClientJS library for the RVR.

First of all - I'm trying to understand a proper set-up using Raspberry Pi. I've got the wires connected, RPi software installed & all preconditions met.

  1. The server must be running on the RPi - done. Found the swagger API - tested, seems to be working fine, driving, LED changing color works OK.

  2. The client SDK is really just a JS API for using the exposed web-services. Having that said - the client could use just about any language that supports http requests.

Anyways, a few questions:

  • should the client be running on the same machine as the server? Why are they separate, then?
  • what are the cons & pros of running them on the same vs different machines?

I'm familiar with NodeJS & server-client architecture, but the ClientJS lib is confusing.

Why are the examples written in JS embedded in HTML? Is the intention to trigger the script by opening the HTML in the browser?
If yes - the HTML needs to be opened inside the machine running the server, meaning I have to be connected using smth like a VNC to the same raspberry, in parallel to SSH where I'm running the server, which is very confusing.

and the final, but most important question of the day:
Where do I find the ../../client-library/index.js dependency? Which is used in the examples, e.g. api-and-shell

@messyfresh
Copy link

After cloning the repo and running npm install, you can type "webpack" to compile the clientsdk into an index.js file that is located in the dist directory. I was able to update the file path in the html files under getting-started to point to "../../dist/index.js" and the scripts started working as intended.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants