Closed Zeke420 closed 3 years ago
I didn't try this with the raspberry pi yet.
But you can try the following:
npm install express
npm install hexapod-kinematics-library
npm install johnny-five
...
npm install socket.io-client
and so on and so forth for all these packages:
"express": "^4.17.1",
"hexapod-kinematics-library": "0.0.5",
"johnny-five": "^2.0.0",
"plotly.js-gl3d-dist-min": "^1.54.7",
"react": "^16.13.1",
"react-dom": "^16.13.1",
"react-icons": "^3.10.0",
"react-plotly.js": "^2.4.0",
"react-router-dom": "^5.2.0",
"react-scripts": "3.4.4",
"socket.io": "^3.0.5",
"socket.io-client": "^3.0.5"
You can also try checking out what other people have tried when npm install fails with too many symbolic links
try npm run dev:client or npm run build:client
On Wed, Jan 13, 2021 at 8:50 PM Zeke420 notifications@github.com wrote:
Downgraded Node version seems that it installed all good but now script: prod:client seems to missing.
pi@raspberrypi:~/Desktop/hexapod-irl $ npm run prod:client npm ERR! missing script: prod:client
npm ERR! A complete log of this run can be found in: npm ERR! /home/pi/.npm/_logs/2021-01-13T12_46_20_132Z-debug.log
— You are receiving this because you commented.
Reply to this email directly, view it on GitHub https://github.com/mithi/hexapod-irl/issues/3#issuecomment-759427919, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAMX2FONJ432BBUWVKH3OTLSZWJIJANCNFSM4V6JVYMA .
Getting npm ERR! code 127. Tried different your commands that you listed. will try npm install again,
i dont know why react scripts was not installed when you ran npm install. (it’s listed in the dependencies)
try installing react scripts first with
npm install react-scripts
On Thu, Jan 14, 2021 at 6:27 AM Zeke420 notifications@github.com wrote:
Getting npm ERR! code 127. Tried different your commands that you listed. [image: Error127] https://user-images.githubusercontent.com/34158929/104517742-448c5100-55ff-11eb-9561-cd904c044bf3.PNG
— You are receiving this because you commented.
Reply to this email directly, view it on GitHub https://github.com/mithi/hexapod-irl/issues/3#issuecomment-759778163, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAMX2FIJ7DFATPU36FQ6DNLSZYM55ANCNFSM4V6JVYMA .
After fixing npm issues managed to start building it with small exception had to create a .env file in the root directory of the project and add this line SKIP_PREFLIGHT_CHECK=true inside the file. But ran into another issue. I'm using raspberry pi zero and by the looks it is struggling because of lack of RAM? But at the same time if you managed to run it on way slower computer I'm thinking there should be a work around.
Hi Zeke,
If the Raspberry Pi Zero is struggling, and you're planning to open the browser app on a different computer anyway, you can try the following instead...
On the faster computer where you plan to open the browser app
do npm install && npm prod:client
Then on the Raspberry Pi Zero run ``` $ npm install express johnny-five socket.io http://socket.io $ npm run run:server ``` since those are the only three packages required to run the server needs, if i'm not mistaken.
Don't forget to edit ***SOCKET_SERVER_URL
and **SOCKET_CLIENT_URLS*
of the file
https://github.com/mithi/hexapod-irl/blob/dev/src/_VAR_CONFIG.js
appropriately.
If you insist on running the client app on the Raspberry Pi Zero the following links might help you solve this! https://blog.asayer.io/javascript-heap-out-of-memory-error https://stackoverflow.com/questions/42730801/how-do-i-tune-node-js-memory-usage-for-raspberry-pi
Hope that helps!
On Sat, Jan 16, 2021 at 8:59 AM Zeke420 notifications@github.com wrote:
[image: Capture] https://user-images.githubusercontent.com/34158929/104792162-26148a00-57a6-11eb-89c9-94fe4928f3c2.PNG After fixing npm issues managed to start building it with small exception had to create a .env file in the root directory of the project and add this line SKIP_PREFLIGHT_CHECK=true inside the file. But ran into another issue. I'm using raspberry pi zero and by the looks it is struggling because of lack of RAM? But at the same time if you managed to run it on way slower computer I'm thinking there should be a work around.
— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/mithi/hexapod-irl/issues/3#issuecomment-761279169, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAMX2FPJBY7QQ36RNZBJXK3S2DQHNANCNFSM4V6JVYMA .
Hi Zeke,
If the Raspberry Pi Zero is struggling, and you're planning to open the browser app on a different computer anyway, you can try the following instead...
On the faster computer where you plan to open the browser app
do npm install && npm prod:client
Then on the Raspberry Pi Zero run
$ npm install express johnny-five socket.io
$ npm run run:server
since those are the only three packages required to run the server needs, if i'm not mistaken.
Don't forget to edit SOCKET_SERVER_URL
and SOCKET_CLIENT_URLS
of the file
https://github.com/mithi/hexapod-irl/blob/dev/src/_VAR_CONFIG.js
appropriately.
If you insist on running the client app on the Raspberry Pi Zero the following links might help you solve this! https://blog.asayer.io/javascript-heap-out-of-memory-error https://stackoverflow.com/questions/42730801/how-do-i-tune-node-js-memory-usage-for-raspberry-pi
Hope that helps!
ok I'm trying to run the server on my PC. I did all npm installs and got it running but when I do npm run run:server on pi it can't find device. pi@raspberrypi:~/Desktop/hexapod-irl $ npm run run:server
hexapod@0.1.0 run:server node ./src/_ROBOT_SERVER.js
listening on *:4001
1610928992791 Board Looking for connected device
1610928998554 Board No connected device found
In VAR_CONFIG.js on raspberry pi I changed SOCKET_SERVER_URL with the url I got when i ran a server on my PC and updated SOCKET_CLIENT_URLS or I'm missing something else?
do you mean you are running the server on your your raspberry pi (ie you
ran npm run run:server
) and the react app (ie you ran npm prod:client
on your pc? do you have an arduino connected to your raspberry pi?
if the board is still not being detected
try specifying the actual port, check out the example here of how to specify port http://johnny-five.io/api/boards/
check how you can get the name of your port https://www.raspberrypi.org/forums/viewtopic.php?t=217209
On Mon, Jan 18, 2021 at 3:08 PM Mithi Sevilla mithi.sevilla@gmail.com wrote:
do you mean you are running the server on your your raspberry pi (ie you ran
npm run run:server
) and the react app (ie you rannpm prod:client
on your pc? do you have an arduino connected to your raspberry pi?try making an led work first by following the instructions here: http://johnny-five.io/examples/raspi-io/
once you manage to get the above script work
edit
src/_ROBOT_SERVER.js
remove line 23 and after line 4, addlet Raspi = require("raspi-io").RaspiIO; let board = Board({ io: new Raspi() });
hope that helps
On Mon, Jan 18, 2021 at 8:29 AM Zeke420 notifications@github.com wrote:
ok I'm trying to run the server on my PC. I did all npm installs and got it running but when I do npm run run:server on pi it can't find device. pi@raspberrypi:~/Desktop/hexapod-irl $ npm run run:server
hexapod@0.1.0 run:server node ./src/_ROBOT_SERVER.js
listening on *:4001 1610928992791 Board Looking for connected device 1610928998554 Board No connected device found
In VAR_CONFIG.js on raspberry pi I changed SOCKET_SERVER_URL with the url I got when i ran a server on my PC and updated SOCKET_CLIENT_URLS or I'm missing something else?
— You are receiving this because you commented.
Reply to this email directly, view it on GitHub https://github.com/mithi/hexapod-irl/issues/3#issuecomment-761909107, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAMX2FOLAZXBUV7TJ4TGPS3S2N6FLANCNFSM4V6JVYMA .
Well, I thought that I could get away only using raspberry pie and my personal PC to control it. On my PC ran npm install && npm prod:client and on raspberry pi npm run run:server. I also modified VAR_CONFIG.js on RP. You ask if I have an arduino connected to RP well no I'm only using RP. Is that even possible :D. I'm studying computer design and had a 3d modeling project where i decided to make a hexapod I have bare minimum in programming or robotics :(
okay, what are you going to use to drive the servos? are you using pca9685?
On Wed, Jan 20, 2021 at 2:22 AM Zeke420 notifications@github.com wrote:
Well, I thought that I could get away only using raspberry pie and my personal PC to control it. On my PC ran npm install && npm prod:client and on raspberry pi npm run run:server. I also modified VAR_CONFIG.js on RP. You ask if I have an arduino connected to RP well no I'm only using RP. Is that even possible :D. I'm studying computer design and had a 3d modeling project where i decided to make a hexapod I have bare minimum in programming or robotics :(
— You are receiving this because you commented.
Reply to this email directly, view it on GitHub https://github.com/mithi/hexapod-irl/issues/3#issuecomment-763031818, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAMX2FPE2MUZHMTBAVVFA43S2XEWNANCNFSM4V6JVYMA .
2xPCA9685 0x40 and other is 0x41
2xPCA9685 0x40 and other is 0x41
I haven't tried it myself, but technically it should be possible (as discussed here: https://github.com/rwaldron/johnny-five/issues/1560 ) by using this repository: https://github.com/nebrius/raspi-io
Would it be better to adopt a hexy code to a custom shell than trying this one?
Would it be better to adopt a hexy code to a custom shell than trying this one?
You could try that, but be aware that repo is no longer maintained (it's archived)
or you could try to make it work with https://github.com/nebrius/raspi-io | rwaldron/johnny-five#1560
Another alternative is to buy a cheap arduino chinese clone which is usually priced around 5 - 10 usd.
I also have a AT mega328 UNO will this work? I can't find it on Johnny-Five supported board list Well I connected PCA9685 to it and uploaded StandardFirmataPlus to Arduino and getting this error. Arduino connected to COM4. It seems like it is trying COM1 at first and fails and does not proceed to the next one.
I also have a AT mega328 UNO will this work? I can't find it on Johnny-Five supported board list
It's literally the first board in this list http://johnny-five.io/platform-support/#arduino-uno
Well I connected PCA9685 to it and uploaded StandardFirmataPlus to Arduino and getting this error. Arduino connected to COM4. It seems like it is trying COM1 at first and fails and does not proceed to the next one.
Example of how to specify the ports http://johnny-five.io/examples/board-with-port/ Also there is a message on your screenshot that says See: https://github.com/rwaldron/johnny-five/wiki/Getting-Started#troubleshooting
Hexapod will only move to its starting position when I start(npm run run:server) and won't respond to anything after that(changing angle in the web app). I'm not getting any errors.
Hexapod will only move to its starting position when I start(npm run run:server) and won't respond to anything after that(changing angle in the web app). I'm not getting any errors.
Make sure your urls https://github.com/mithi/hexapod-irl/blob/dev/src/_VAR_CONFIG.js on BOTH your PC and raspberry pi are correct
If you're not getting lag: {SOME NUMBER}
like here
https://github.com/mithi/hexapod-irl/blob/bb44eaf1a79e567a8bc193d5a12ccbeaf7c91042/src/_ROBOT_SERVER.js#L74-L75
Then your server is not communicating with your client
Note: I will be closing this issue, since this is not an npm error
anymore
Hi, I tried running it on raspberry pi zero and getting this npm error that i can't find the way to fix. Is this on my side or that's smth else?
npm ERR! code ELOOP npm ERR! syscall open npm ERR! path /home/pi/Desktop/hexapod-irl/node_modules/react-native-web/npm-shrinkwrap.json npm ERR! errno -40 npm ERR! ELOOP: too many symbolic links encountered, open '/home/pi/Desktop/hexapod-irl/node_modules/react-native-web/npm-shrinkwrap.json'
npm ERR! A complete log of this run can be found in: npm ERR! /home/pi/.npm/_logs/2021-01-11T22_41_42_087Z-debug.log