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

How to run jcdriver in the background at boot? #67

Closed
tidann opened this issue Jun 16, 2020 · 2 comments
Closed

How to run jcdriver in the background at boot? #67

tidann opened this issue Jun 16, 2020 · 2 comments

Comments

@tidann
Copy link

tidann commented Jun 16, 2020

I am trying to start jcdriver in background during the boot of my raspberry pi 3 on raspbian/retropie.
I tried /etc/init.d but the process stops automatically, same problem when I create a service with systemctl.
I am a beginner in Linux command line, can someone help me ?

@maxerbox
Copy link

dup #60

@tidann
Copy link
Author

tidann commented Jun 18, 2020

This issue is closed thanks to @maxerbox . Here is my specific jcdriver.service file:

[Unit]
Description=Joycon driver
After=network.target

[Service]
ExecStart=sudo /home/pi/go/bin/jcdriver
WorkingDirectory=/home/pi
StandardInput=tty-force
TTYVHangup=yes
TTYPath=/dev/tty20
TTYReset=yes
StandardOutput=inherit
StandardError=inherit
Restart=always
User=pi

[Install]
WantedBy=multi-user.target

These 4 lines solved the problem:

StandardInput=tty-force
TTYVHangup=yes
TTYPath=/dev/tty20
TTYReset=yes

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