Hello,
New to linux. Want to be able to have real dash open when pi is booted up. Thanks.
You can configure a GUI program to start automatically on boot in Raspberry Pi OS using one of several methods.
Method 1: LXDE Autostart
If you are using the desktop environment LXDE (Lightweight X11 Desktop Environment), which is used by Raspberry Pi OS, you can put a .desktop file in the autostart directory. Here’s how to do that:
-
Open Terminal.
-
Type this command and hit enter:
nano ~/.config/lxsession/LXDE-pi/autostart -
Add the command to execute your program at the end of this file. It might look like this:
@/usr/bin/realdash -
Save the file and exit nano (Ctrl+X, then Y, then Enter).
-
Reboot to see the changes.
Method 2: systemd
If the first method doesn’t work, or you want a more powerful and flexible solution, you can use systemd, a system and service manager for Linux. Here’s how:
-
Create a new systemd service file:
sudo nano /etc/systemd/system/realdash.service -
Add the following to this file:
[Unit] Description=RealDash [Service] ExecStart=/usr/bin/realdash Restart=always User=pi Environment=DISPLAY=:0 Environment=XAUTHORITY=/home/pi/.Xauthority [Install] WantedBy=multi-user.target -
Save the file and exit nano (Ctrl+X, then Y, then Enter).
-
Enable the service so that it starts on boot:
sudo systemctl enable realdash.service -
Start the service immediately:
sudo systemctl start realdash.service -
Check the status of the service:
sudo systemctl status realdash.service
Remember that GUI applications usually require a display to connect to, which is why we’ve set the DISPLAY environment variable in the systemd service.
These instructions should help you automatically start a GUI application when your Raspberry Pi boots.
Tried both options and was unable to get it to work.
Unfortunately those are the only ways I know of ![]()
Im abble to autostart realdash by the first method, but i cant run it 100% fullscreen, i always have a bar on the top of the screen
running a 1920x720 12.3 inches touchscreen
It could be that you need to add some delay to the startup in order for the windowing system start completely? Maybe here are some Linux gurus that can help more.
how can i do that? im running with lxde autostart
You can use more configurable window manager, for example i3. Then in the configuration (~/.config/i3/config) put following rule:
for_window [title="RealDash"] fullscreen enable
Of Course there is much more you can do with it ![]()
I changed xsession to boot straight into realdash through the pi user. Doing that will keep you from getting back to the desktop. To get around this I created a second user. With that, you can hit esc and it will take you to the login window.
All the details are on Github.
i give it up and i give it to a friend better than me in programation, i will show it soon, the setup will be nice.
want to run it with a TheOneGauge connected on my terminator X max
will be in a 05 wide body mustang with a turbocharged 4V 4.6
Hi, is there any way you could tell me how to make i3 my default terminal after installation and how to remove lxterminal… i tried xterm but didnt work.
I have run the instillation pavkage but dont know what to do after that. The tutorials arectoo vague.
Any help would be very appreciated. Thanks
The ‘standard’ way that i know to do this is by using “update-alternatives”, sth like:
sudo update-alternatives --config x-session-manager
thanks i appreciate the reply.
I still dont understand, is x-session-manager the comand for i3? or i have to know that somehow?
The issue seems to be that the xlogin session is not completed when the service tries to start so it bombs, I added a delay in a bash script then ran at cron bootup seems to be fine on pi 4
sudo nano /home/pi/realdash.sh
(add these lines save exit)
sleep 10
sudo systemctl start realdash
chmod 0777 /home/pi/realdash.sh
add to cronjob after reboot, it will add a 10 sec delay in starting the service
crontab -e
@reboot bash /home/pi/realdash.sh
I also set pi user to not require password for sudo not sure if you need that or not
Hello all, I am new to realdash and raspberry OS, I am trying to get realdash to autostart. I submitted the the lines in terminal, but no autostart on reboot. Here are the options in the AutoStart file
@lxpanel --profile LXDE-pi
@pcmanfm --desktop --profile LXDE-pi
@xscreensaver -no-splash
@bin/realdash
give this a try it worked for me on a pi5
- Create a service file
Open a terminal on your Pi and create a new systemd service:
sudo nano /etc/systemd/system/realdash.service
- Add the following content:
[Unit]
Description=RealDash Autostart
After=network.target graphical.target
[Service]
User=pi
ExecStart=/home/pi/RealDash/RealDash
WorkingDirectory=/home/pi/RealDash
Restart=always
Environment=DISPLAY=:0
Environment=XAUTHORITY=/home/pi/.Xauthority
[Install]
WantedBy=graphical.target
Replace /home/pi/RealDash/RealDash with the actual path to the RealDash binary.
3. Enable the service
sudo systemctl daemon-reexec
sudo systemctl daemon-reload
sudo systemctl enable realdash.service
sudo systemctl start realdash.service
This will start RealDash automatically when the Pi boots into the GUI (desktop environment).
(pi) replace with the log in you set up on the pi
I just went through this the other day and after unsuccessfully trying a few methods, found this Youtube video:
You download a program called botspot/autostar and enter in that what you want to start at boot up. Maybe it’s not the cleanest or most lightweight setup, but it worked flawlessly after multiple other attempts. My Pi starts into Real Dash with it fullscreen and everything works great.
Mclovin1501’s code did not seem to work for my Pi 5, but it is very similar to what AI was giving me. It is just a minute or two after the desktop has loaded before RealDash starts up.
Here was my version from AI (note that my user name was changed from PI to jesusday).
[Unit]
Description=RealDash display
After=can0.service graphical.target
Requires=can0.service
[Service]
User=jesusday
Group=jesusday
Environment=DISPLAY=:0
Environment=XAUTHORITY=/home/jesusday/.Xauthority
WorkingDirectory=/home/jesusday
ExecStart=/usr/bin/realdash
Restart=on-failure
RestartSec=5
TimeoutStartSec=5 #60
[Install]
WantedBy=graphical.target
With that said, I have had better luck with using the following (I did not try the youtube video attached here).
—(This was done using the video here as the idea and AI on how to fill in the gaps)
Raspberry Pi: Add Startup Commands | Run On Boot - YouTube
—Run the below command and copy in the text below (Between the " " not including them (note that my user name was changed from PI to jesusday))
nano /home/jesusday/start_realdash.sh
"
#!/bin/bash
# Number of retries
MAX_RETRIES=5
RETRY_DELAY=5
for ((i=1; i<=MAX_RETRIES; i++)); do
echo "Attempt $i to start RealDash..."
DISPLAY=:0 \
XAUTHORITY=/home/jesusday/.Xauthority \
DBUS_SESSION_BUS_ADDRESS=unix:path=/run/user/1000/bus \
/usr/bin/realdash &
PID=$!
# Wait a bit to see if it crashes immediately
sleep 10
if ps -p $PID > /dev/null; then
echo "RealDash started successfully."
exit 0
else
echo "RealDash crashed. Retrying in $RETRY_DELAY seconds..."
sleep $RETRY_DELAY
fi
done
echo "RealDash failed to start after $MAX_RETRIES attempts."
exit 1
"
—Then make it executable by running (note that my user name was changed from PI to jesusday)
chmod +x /home/jesusday/start_realdash.sh
—Then run crontab
crontab -e
—You might have to select a file path, I picked #1
—At the bottom of the file, add the below and make sure there is another blank line under it (this file must have an extra blank line at the base to work (note that my user name was changed from PI to jesusday))
@reboot sleep 12 && /home/jesusday/start_realdash.sh
—You might need to adjust the sleep time to make it suitable for your setup. Note that the bash file is retrying with 5 second delays so it is possible that 13 seconds would be quicker than a 12 second. Triggers at 12 seconds and runs 5 second delay because 13 seconds was the ideal setting)