rhysmorgan134 / react-carplay

MIT License
382 stars 58 forks source link

change binded keys and some options in config file #16

Closed ky3mu4 closed 8 months ago

ky3mu4 commented 1 year ago

Hi, I want to use joystick to navigate, so I need to change Up key to work as Up, hot like Home (and so I need to add a home key as well) So is it possible to make it if I use a AppImage file? Or how can I compile it using sources? what software do I need for that?

rhysmorgan134 commented 1 year ago

Bindings are here:

https://github.com/rhysmorgan134/react-carplay/blob/7dacb6cae6bf655fe2262d79965850053f7d5502/electron/bindings.json#L1-L14

they would need editing, then the package rebuilt using

npm run build-package

In the next release I will make them rebindable via the gui

ky3mu4 commented 1 year ago

something going wrong. looks like it need some dependencies. what should I need to install?

pi@raspberrypi:~/react-carplay $ npm run build-package

carplay@1.0.3 build-package npm run build && npm run build-electron && npm run package

carplay@1.0.3 build react-scripts build

sh: 1: react-scripts: not found npm ERR! code 127 npm ERR! path /home/pi/react-carplay npm ERR! command failed npm ERR! command sh -c react-scripts build

npm ERR! A complete log of this run can be found in: npm ERR! /home/pi/.npm/_logs/2022-07-24T12_17_27_086Z-debug.log npm ERR! code 127 npm ERR! path /home/pi/react-carplay npm ERR! command failed npm ERR! command sh -c npm run build && npm run build-electron && npm run package

npm ERR! A complete log of this run can be found in: npm ERR! /home/pi/.npm/_logs/2022-07-24T12_17_27_224Z-debug.log

rhysmorgan134 commented 1 year ago

Did you run npm install first?

ky3mu4 commented 1 year ago

I just make : sudo apt-get install nodejs sudo apt-get install npm then I change path to project dir and make command you send earlier. really noob in nodes.

but one more question. you have this code in dongleHolder.js: this._keys = { invalid: 0, //'invalid', siri: 5, //'Siri Button', mic: 7, //'Car Microphone', left: 100, //'Button Left', right: 101, //'Button Right', frame: 12, selectDown: 104, //'Button Select Down', selectUp: 105, //'Button Select Up', back: 106, //'Button Back', down: 114, //'Button Down', home: 200, //'Button Home', play: 201, //'Button Play', pause: 202, //'Button Pause', next: 204, //'Button Next Track', prev: 205, //'Button Prev Track', wifiEn: 1000, wifiPair: 1012, wifiConnect: 1002 }

    is it mean, that I need to add some warnings in this file too? where can I find codes for other keys? 
    should I download this files in node_modules dir?
ky3mu4 commented 1 year ago

I make Install, and for now it says:

25 error code ELIFECYCLE 26 error errno 1 27 error carplay@1.0.3 build-package: npm run build && npm run build-electron && npm run package 27 error Exit status 1 28 error Failed at the carplay@1.0.3 build-package script. 28 error This is probably not a problem with npm. There is likely additional logging output above.

rhysmorgan134 commented 8 months ago

https://github.com/rhysmorgan134/react-carplay/releases/tag/v4.0.0-beta.4 key bindings are now configurable via settings