Stack Exchange Network

Stack Exchange network consists of 175 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange
Search type Search syntax
Tags [tag]
Exact "words here"
Author user:1234
user:me (yours)
Score score:3 (3+)
score:0 (none)
Answers answers:3 (3+)
answers:0 (none)
isaccepted:yes
hasaccepted:no
inquestion:1234
Views views:250
Sections title:apples
body:"apples oranges"
URL url:"*.example.com"
Favorites infavorites:mine
infavorites:1234
Status closed:yes
duplicate:no
migrated:no
wiki:no
Types is:question
is:answer
Exclude -[tag]
-apples
For more details on advanced search visit our help page
Results tagged with Search options answers only user 13650

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

2
votes
Probably because the script does not have a stdout. Try this instead (where pi is the user who should be told) #!/bin/sh write pi <<EOM YOU HAVE ADDED A USB KEY EOM …
answered Aug 22 '15 by joan
3
votes
Remember that this question is not specific to the Raspberry Pi. You could find answers on all sorts of general Linux sites. The following bash script should find your router's IP address. #!/bin …
answered Jul 11 '14 by joan
2
votes
The only reason I can think of for not being able to save the file is that the file system has been mounted read only as it is corrupt. You need a PC with a SD card reader. That PC must be another L …
answered Dec 14 '15 by joan
0
votes
According to http://download.chip45.com/BTM222_DataSheet.pdf the factory settings of the UART are as follows Baud rate: 19200 bps Data bit: 8 Parity: none Stop bit: 1
answered Jul 30 '15 by joan
0
votes
Re sh: 1: scan.sh: not found Either: no file called scan.sh exists in the current working directory (of the script) scan.sh does not have the executable bit set the user has no permission to view scan.sh I suppose 2. is the most likely. To set the executable bit use the command chmod +x scan.sh …
answered Dec 11 '17 by joan
1
vote
Add the following line as the first of your Python script. #!/usr/bin/env python This tells the system that the script should be executed by the Python interpreter. At the moment the shell thinks the script is a list of shell commands and is getting confused. …
answered May 11 '17 by joan
1
vote
Replace your [ with [[ and ] with ]]. Replace temp="temp | cut -c 6-9" with temp=$(temp | cut -c 6-9).
answered Aug 6 '14 by joan
2
votes
You must not connect 5V to a Pi gpio (unless your intention is to fry the gpio and/or Pi). All the Pi's gpios are 3V3. The 3V3 and 5V power rails have no method of knowing if something is attached. …
answered Jul 30 '15 by joan
1
vote
By default wiringPi's gpio utility is installed in /usr/local/bin. It is unlikely to be in the path of the root user when init scripts are run. Rather than gpio use /usr/local/bin/gpio.
answered Sep 14 '15 by joan
2
votes
jobs. One option is to schedule a job on reboot. If your script needs to be run as root add it to /etc/rc.local or to the root crontab. sudo crontab -e If your script doesn't need to be run as … file in /usr/local/bin called mysync with the following content #!/bin/bash cd /usr/share/pyplate nohup ./onchange.sh & Then just type mysync to run the script. The nohup will allow the script to run to completion even if you terminate its parent session. …
answered Jan 20 '15 by joan
1
vote
network using NFS. On the Pi the laptop NFS directory is mapped to /code. That allows me to develop on the laptop (or Pi) and run the script on the Pi simply by ssh'ing to the Pi and using /code …
answered Jul 10 '15 by joan
2
votes
Raspbian supports the /dev/gpiomem device which allows access to the GPIO without being the root user. If /dev/gpiomem does not exist on your system you will need to run the Python script as the root user (with all the risks that entails). …
answered Oct 24 '17 by joan