New answers tagged

0

This line in your script: cd "$(/home/pi "$0")"; is trying to execute /home/pi as if it's a program, but it's surely a directory. What did you mean this line to be?


0

Since you are using stdio, a fifo might be a solution for your input. For example, open two terminals and do: terminal 1: |terminal 2: $ mkfifo fifo | $ tail -f fifo | sed 's/a/A/' |$ echo hoppa > fifo hoppA | So, you could create a fifo in your ...


1

If you want it to keep a process running so you can use it then install the screen program then use screen at the start command in the cron job. This is where you use the /usr/bin/screen -d -m -fa -S Screen_Name_For_Instance /usr/bin/name_of_server_program to start it up. You can test the command at your command line. Once happy it runs correctly then the ...


1

BASH script for PWM function gpiopwm() { sleep_low=$(awk -v freq="$2" -v duty="$3" 'BEGIN{print (1/freq)*((100-duty)/100)}') sleep_high=$(awk -v freq="$2" -v duty="$3" 'BEGIN{print (1/freq)*((100-(100-duty))/100)}') var_count=0 repeat=1000 while [ $var_count -lt $repeat ] do echo 1 >...


Top 50 recent answers are included