Questions tagged [script]

non-compiled programs written in scripting languages (e.g. perl, python or tcl) or command line interpreters such as Unix shell.

Filter by
Sorted by
Tagged with
-1
votes
4answers
64 views

Control fan to lower temperatur via script [duplicate]

I have a raspberry pi 4 and a small fan in the case. I know that the pi can run without a fan but I already have one installed so why not using it. The problem is, that this small fan does make a ...
0
votes
1answer
50 views

Send GPIO trigger(s) at specific video timecode(s)?

Just starting out in the wonderful world of RPi maker projects, scored a Model 2b v.1.1, installed the latest Raspbian and now ready for my first project :-) What I want to build is a video player for ...
0
votes
1answer
16 views

Raspberry Pi POCSAG mail script

I have a raspberry pi configured as a POCSAG receiver with a RTL-SDR USB stick. Everything works just perfect, and it receives signals and messages. I then found a script that was supposed to be able ...
0
votes
2answers
30 views

Very new to scripts, is it possible to loop a script in the background looking for a button press?

I'm trying to build a camera with the new HQ Camera module, but am running into some trouble. I don't want to have to run my little camera.py script (that just opens preview, waits, takes a photo, and ...
2
votes
2answers
58 views

Can't run python script on startup. Raspberry Pi 4

I am trying to run a python script when my Raspberry pi 4 boots. THis python script works when I run it directly, with no errors. I have edited the crontab file to do this as can be seen below: # ...
0
votes
0answers
122 views

Fuse Mount Option “-nonempty” is Not Working

I have a setup where I need to log quite a bit of data on my Raspberry Pi. I have a 128GB USB stick that mounts to a folder called external where all my scripts/programs log to. This works well, ...
-2
votes
1answer
60 views

Running a program on boot (Pi 4)

I have been trying to get a program to start automatically on boot. I have tried using systemd, init.d, rc.local, and cron to execute my bash script in order to invoke a program (e.g. open an instance ...
1
vote
2answers
41 views

How Do I Create a Startup for No-ip?

I am on Raspbian. I want no-ip to startup everytime it boots. How can I accomplish this?
1
vote
1answer
67 views

Permission denied on executing script

I can't execute a script. I'm struggling with this. OS version and hardware model I'm on Raspbian GNU/Linux 10, Raspberry Pi 3 Model B. Devices When I call lsblk I get: $ lsblk NAME MAJ:...
1
vote
1answer
36 views

Raspberry pi capture desktop without any connected monitor

I want to capture raspberry pi desktop without connected monitor. IS it possible to run a program capture with script at boot up and record the desktop? Or the raspberry pi must be connected with ...
1
vote
1answer
34 views

Script that saves file to USB when plugged in

I am currently building a weather logger with a DHT22 that logs the data to a CSV file. It will be used in a place without internet and also without a screen. The script i am using logs the data as ...
1
vote
1answer
164 views

My script in autostart not work correctly

I am very new in linux and I don't know where I make mistake. I am using Raspbian. When I manually start script press.sh everything works fine. But when I start this script from /etc/rc.local it not ...
2
votes
1answer
41 views

Start application into specific workspace (desktop)

I've set up my Raspbian with 4 workspaces/desktops and like to start an application via script into one specific desktop. Is there a parameter I can add to my script #!/bin/bash # myApp & to ...
1
vote
1answer
33 views

Python script refuses to start automatically

I have a python script (taken from the forums here) that reboots my RPI when a button is pressed. It works great, no issues, except that it refuses to start automatically (either on boot, login, ...
2
votes
0answers
51 views

Sending an image from Pi Camera continuously to a display

I want to send 6 images per minute from the Pi Camera continuously to any display. Like for say I have the camera that is at my house but I want to send the images to my work computer. The end goal ...
2
votes
1answer
63 views

Traffic Light Led Change During NOAA Satellite Script?

I have the following script that downloads and processes NOAA satellites. I'd really like some external LEDs to indicate the following; When the script is running, turn or blink red When the script ...
3
votes
1answer
190 views

Rotate screen 180 on the fly?

I think this may be impossible, but I'd like to rotate the display by 180 degrees on the fly, triggered by a button connected to the input pins. I built a cocktail-style MAME cabinet (RetroPie) but ...
1
vote
0answers
120 views

Custom Dualshock 4 Script/Program

I've got a Pi 3b that I originally planned to be a dedicated Steam Link. I already followed these instructions to set up a DS4 controller to control it, and it's working just fine so far: https://...
-2
votes
1answer
36 views

I'm trying to make a shell script that can mount a exFAT drive

Hi I am trying to make a shell script that can create a directory (/mnt/drive) and mount a exFAT drive in that directory on my raspberry pi 2. The problem I am having is that when I try to run the ...
1
vote
3answers
76 views

How to automatically run a script on boot / startup?

I have trying to get a script to run at startup to mount a flash drive and change ownership on dynamically created files. I have not been successful in getting the script to run. It only runs when I ...
1
vote
1answer
245 views

Permissions error with logrotate [closed]

I am using a script to monitor a service. I have added said script in crontab. crontab runs the script every one minute. I have found this script online and it works pretty good, but it writes the ...
2
votes
2answers
342 views

Wiring Pi Issue - #!/bin/bash vs #!/bin/sh

I am working on a project and have an application shell script. For function part, I need the GPIO access, and for that, I am using the standard wiringpi package. The issue I am getting is with the #...
1
vote
1answer
869 views

Script Using CEC-Client Will Turn on TV OR Change Input But Not Both

I'm trying to use this script to turn on a TCL TV and change the input to RPi using cec-client: echo 'on 0' | cec-client -s echo '4f:82:10:00' | cec-client -s It will turn the TV on, but not change ...
1
vote
1answer
96 views

Coproc in shell script

I'm trying to do a simple shell script that will make my raspberry's bluetooth discoverable but i'm facing some issues. My raspberry is running Raspbian. Running this through command line works ...
0
votes
0answers
23 views

Howto tell the difference between a RP3B and RP4B from a script? [duplicate]

I want to create scripts that configure RP3 and RP4 software installations using Raspbian Lite. The scripts need to know the difference between an RP3B+ and and RP4B. How can I do that? Dazz
1
vote
0answers
34 views

shell script does not invoke define variable in autostart script

I try to use the raspberry pi for power point presentation. I want to run this as auto ( I mean once the raspberry pi started or rebooted the power point presentation should run). Basically it works ...
3
votes
1answer
34 views

Include File With Raspbian Setup

I am working on a project which requires many raspberry pi's to be set up pretty much the same way. In order to set up the pi's we put NOOBS on the micro SD card and then install raspbian onto the pi. ...
2
votes
3answers
644 views

Python script won't load on startup

I have tried like 5 methods to get this script loaded after raspi3 load. #!/usr/bin/python3.7 #sudo python /home/pi/masterBaseInterface.py import socket # Import socket module import ...
2
votes
2answers
137 views

how to update customised OS image to a newer version keeping modification?

I am using Hypriot as OS . I have done modifications to some file and script,and i have add new service on boot . I would like to know if i have a newer version of Hypriot how can i update my ...
-1
votes
1answer
135 views

Disable autologin on tty1 on stretch 9.9

I found this answere but it doesnt work anymore. How does it work on the new version?
2
votes
4answers
106 views

Pi - own python startup script in the wrong order

I've written a python script to connect to mysql & insert the current time then close. The use case is if my Pi browns out/restarts (often does) the time of this event will be logged. The script ...
0
votes
1answer
370 views

Execute a script on startup in latest NOOBS OS - Raspberry - Pi 3B+

Actually I have went through this stack answer and followed the 3rd Type for running the script on startup, and It works like a charm for previous version of NOOBS. Today I downloaded the latest zip ...
0
votes
3answers
2k views

Use a bash file to open a lxterminal and run commands into it automatically

I have made a python application for raspberry and it needs to run into a terminal. That's totally necessary. To do that I wrote two bash files, run_.sh and launcher.sh. run_.sh execute the python ...
0
votes
1answer
53 views

I want to do this, what programming languages and libraries do I need to know?

I want to run a program or script on Raspberry Pi 3B+, which allows the user to set an amount of time for it to connect to WiFi 1, after the expiry of that time it has to connect another WiFi 2 for ...
0
votes
0answers
47 views

Can't run a command using Raspi_Runner

I've setup Raspi_Runner to auto run commands reading from a text file every x minutes. Raspi Runner is a BASH script which runs all your scripts delivered by e-mail. It works good with commands like ...
2
votes
2answers
73 views

How do I make a Java application I made run as a deamon?

I have a Java Application is going to be my Discord Server's bot. How do I make this application run as a daemon on a Raspberry Pi, it uses the latest version of Raspbian and the Java application ...
3
votes
2answers
3k views

Run script with virtualenv on init

I have bash script which loads a virtualenv and run 3 python scripts. I have tried to init on startup by ini.d and rc.local methods but it doesnt work and I have no idea why is not working but if I ...
2
votes
1answer
163 views

Run bash script after New WiFi connection

Noobs installation. I've a script which needs to be run after a new WiFi connection is set. Is there any way to run this script automatically once we connect/set WiFi?
1
vote
1answer
398 views

Retrieve data from Smart Plug via Raspberry Pi (need help with python script)

I am using a tutorial from BeardMonkey in order to retrieve and store the measured data from a smart plug (a smart plug is monitoring the power consumption of my kettle at the moment) https://www....
4
votes
2answers
328 views

Visualize execution of scripts

I have a script that always runs on the Raspberry Pi. I defined with sudo nano /etc/rc.local so that they turn even after a reboot or a power failure. My question is how can visualize the execution ...
0
votes
2answers
2k views

Raspberry pi starting shell script at boot not working

I've been trying to implement a custom procedure triggered by a button connected to my raspberry pi. To do that I've tried to launch a python script on boot that always listens to the button trigger. ...
2
votes
2answers
1k views

Why doesn't my autostart file run a simple shell script

I am trying to launch a simple script (let's say it is /home/pi/python/python_code/hello-world.sh) from the /home/pi/.config/lxsession/LXDE-pi/autostart file. I have added the following line to the ...
-1
votes
3answers
1k views

Runing python script after startup

R Pi 3 B+, Raspbian I would like to run a Python script after the Pi has booted up. There loads of posts about this like here & here & here. They either dont work or I just plain dont ...
0
votes
1answer
221 views

Python script execution time limits?

I have a python3 script called bot.py which is running a simple (for now) telegram bot, and I can retrieve some PI system states. It's required to maintain the bot online, so I added next string to ...
0
votes
0answers
25 views

Help with connect / disconnect script

Very noob to Pi programming but am tech savvy. Can somebody help with the 2 questions below: 1) How to I go about setting a script to run boot 2) Can you also help with a script to do the following: ...
1
vote
0answers
74 views

Calling a program from /etc/rc.local

I have a simple script that adjusts the monitor's brightness that is set to run on startup. #!/bin/bash gpio -g 18 1024 gpio -g mode pwm gpio pwmc 1000 gpio -g 18 800 I am calling this script from /...
1
vote
1answer
1k views

How to start a systemd service as a non-root user?

I've been using qbittorrent-nox on a headless Raspberry Pi 3 B+. The setup was a breeze. But then I wanted to autostart qbittorrent after boot, so I wrote a systemd service unit and enabled it. It ...
2
votes
2answers
102 views

Waiting for network connectivity instead of just sleep fixed time

I'm new to the whole Raspberry Pi and Bash scripting thing, so bear with me. I run raspberry autopilot on a remotely controlled vehicle thru a 3G/4G connection. Raspberry Pi is installed onboard the ...
2
votes
1answer
47 views

Monitoring NICs on the Pi

Is it possible to have a script running as a service constantly monitor certain NICs and alert me throught LEDs if one of them has been disconnected or is not properly detected by the OS? Would ...
1
vote
1answer
303 views

Controlling Raspberry pi3 Wirelessly with HTML (Lighttpd)

I've been working on a Obstacle avoidance robot using Ultrasonic and IR sensors. The scope of my project is to execute my program over the air. Control the robot's movement using mouse or touch ...

1
2 3 4 5