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

Update "Boot on Startup" manual for beginners #5

Closed
TimBoWi opened this issue Jun 7, 2022 · 3 comments
Closed

Update "Boot on Startup" manual for beginners #5

TimBoWi opened this issue Jun 7, 2022 · 3 comments

Comments

@TimBoWi
Copy link

TimBoWi commented Jun 7, 2022

Hey Mitchese you can Add this to your Description for "Starting at boot".
Step by Step for Beginners. I think a lot of people who use your SHM Faker are quite new and maybe need some help.

First login onto your Venus to create the rc.local.

Use nano /data/rc.local to create the necessary file.
Data is used because if you update your VenusOS, all other entrys will be deleted (as far as i know).

After you created the rc.local you have to tell the script, what it should to.

!#/bin/bash

sleep 15
setsid /data/home/root/shm-et340 > /dev/null 2>/dev/null &

image

Depending on your hadware setup you can change the seconds of the "sleep command".
If your Systems is slow, you may have to increase the time (RaPi 4 2GB works fine with 15 seconds)
Important: If you renamed shm-et340 you have to change the line accordingly.
Save the Lines with ctrl+x and hit enter.

Now Check if the right permissions are set correctly with the following command.
ls -l /data/rc.local

It should look like this.
image

If permissions are missing use chmod to set them accordingly
chmod u+x /data/rc.local

Now you are done, enter reboot and shm-et340 will start a few seconds after the boot is completed.

@fishpepper
Copy link

fishpepper commented Jun 9, 2022

I would recommend running shm-et340 in a loop. My code crashed to some unknown reason after 20 days.

Save a file shm-et340-loop.sh in ~:

#!/bin/bash
LOG=/var/log/shm-et340

while true
do
  echo -ne "RESTART " >> $LOG
  date >> $LOG
  /data/home/root/shm-et340  2>&1 | tail -20 >> $LOG
  sleep 1
done

(don't forget to chmod +x shm-et340-loop.sh)

And then call shm-et340-loop.sh in the rc.local.

The last lines of debug info and reboot timestamps are stored in /var/log/shm-et340

@christian1980nrw
Copy link
Contributor

christian1980nrw commented Jan 7, 2023

I published an easy installation script with https://github.com/mitchese/shm-et340/pull/10/files .
@fishpepper If there is a network problem, the driver will crash. I solved this problem too.

@mitchese mitchese closed this as completed Apr 3, 2024
@mitchese
Copy link
Owner

mitchese commented Apr 3, 2024

I've updated the readme and included the install.sh which should take care of this

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

4 participants