Running picocom in the background without open session
Clash Royale CLAN TAG#URR8PPP
up vote
1
down vote
favorite
I would like picocom to log serial data on a remote computer, without having to keep my ssh session to the remote computer alive.
I have tried:
picocom <my options>
This dies when I logout.
picocom <my options> &
No output on terminal, and exiting picocom
with C-a C-x
leaves the job as stopped, it doesn't kill it (I need to kill -9
, a simple kill
on the job does not work. I then have to manually clean the tty lock in /var/lock/
).
picocom <my options> > tmp/data.log&
then in another ssh session:
tail -f tmp/data.log
No data cames out in the file data.log
.
bash -c "picocom --baud 115200 /dev/ttyACM1 > /home/pi/tmp/data.log" &
No output to the file either. The job becomes "Stopped" right away.
nohup sh -c "picocom --baud 115200 /dev/ttyACM1 > /home/pi/tmp/data.log" &
I get the start output of picocom
in the tailed file, but then the job is exited.
Good to know as well: picocom
does not react to C-z
.
My questions are:
- is it at all possible to run
picocom
in the background? - what alternatives are there to log serial terminal without an open session?
background-process serial-port terminal-emulator nohup jobs
add a comment |Â
up vote
1
down vote
favorite
I would like picocom to log serial data on a remote computer, without having to keep my ssh session to the remote computer alive.
I have tried:
picocom <my options>
This dies when I logout.
picocom <my options> &
No output on terminal, and exiting picocom
with C-a C-x
leaves the job as stopped, it doesn't kill it (I need to kill -9
, a simple kill
on the job does not work. I then have to manually clean the tty lock in /var/lock/
).
picocom <my options> > tmp/data.log&
then in another ssh session:
tail -f tmp/data.log
No data cames out in the file data.log
.
bash -c "picocom --baud 115200 /dev/ttyACM1 > /home/pi/tmp/data.log" &
No output to the file either. The job becomes "Stopped" right away.
nohup sh -c "picocom --baud 115200 /dev/ttyACM1 > /home/pi/tmp/data.log" &
I get the start output of picocom
in the tailed file, but then the job is exited.
Good to know as well: picocom
does not react to C-z
.
My questions are:
- is it at all possible to run
picocom
in the background? - what alternatives are there to log serial terminal without an open session?
background-process serial-port terminal-emulator nohup jobs
add a comment |Â
up vote
1
down vote
favorite
up vote
1
down vote
favorite
I would like picocom to log serial data on a remote computer, without having to keep my ssh session to the remote computer alive.
I have tried:
picocom <my options>
This dies when I logout.
picocom <my options> &
No output on terminal, and exiting picocom
with C-a C-x
leaves the job as stopped, it doesn't kill it (I need to kill -9
, a simple kill
on the job does not work. I then have to manually clean the tty lock in /var/lock/
).
picocom <my options> > tmp/data.log&
then in another ssh session:
tail -f tmp/data.log
No data cames out in the file data.log
.
bash -c "picocom --baud 115200 /dev/ttyACM1 > /home/pi/tmp/data.log" &
No output to the file either. The job becomes "Stopped" right away.
nohup sh -c "picocom --baud 115200 /dev/ttyACM1 > /home/pi/tmp/data.log" &
I get the start output of picocom
in the tailed file, but then the job is exited.
Good to know as well: picocom
does not react to C-z
.
My questions are:
- is it at all possible to run
picocom
in the background? - what alternatives are there to log serial terminal without an open session?
background-process serial-port terminal-emulator nohup jobs
I would like picocom to log serial data on a remote computer, without having to keep my ssh session to the remote computer alive.
I have tried:
picocom <my options>
This dies when I logout.
picocom <my options> &
No output on terminal, and exiting picocom
with C-a C-x
leaves the job as stopped, it doesn't kill it (I need to kill -9
, a simple kill
on the job does not work. I then have to manually clean the tty lock in /var/lock/
).
picocom <my options> > tmp/data.log&
then in another ssh session:
tail -f tmp/data.log
No data cames out in the file data.log
.
bash -c "picocom --baud 115200 /dev/ttyACM1 > /home/pi/tmp/data.log" &
No output to the file either. The job becomes "Stopped" right away.
nohup sh -c "picocom --baud 115200 /dev/ttyACM1 > /home/pi/tmp/data.log" &
I get the start output of picocom
in the tailed file, but then the job is exited.
Good to know as well: picocom
does not react to C-z
.
My questions are:
- is it at all possible to run
picocom
in the background? - what alternatives are there to log serial terminal without an open session?
background-process serial-port terminal-emulator nohup jobs
asked Jan 31 at 13:39
Gauthier
415518
415518
add a comment |Â
add a comment |Â
2 Answers
2
active
oldest
votes
up vote
1
down vote
accepted
An alternative is to setup the device with stty
, then read it with cat:
stty <my options>
nohup sh -c "cat /dev/ttyACM0 > data.log" &
add a comment |Â
up vote
0
down vote
Assuming the user session is meant, you might be able to use screen
with the -X
option to send commands to a running screen session and the stuff
command to send keystrokes to the current window.
screen -dmS newScreen bash
screen -S newScreen -X stuff "picocom <options>n"
screen -ls
screen -r <pid>
Please take note to put the quotes around and the next line in order for the commands to be executed. *
... haven't checked if bash -c
or tmux
would be possible too.
add a comment |Â
2 Answers
2
active
oldest
votes
2 Answers
2
active
oldest
votes
active
oldest
votes
active
oldest
votes
up vote
1
down vote
accepted
An alternative is to setup the device with stty
, then read it with cat:
stty <my options>
nohup sh -c "cat /dev/ttyACM0 > data.log" &
add a comment |Â
up vote
1
down vote
accepted
An alternative is to setup the device with stty
, then read it with cat:
stty <my options>
nohup sh -c "cat /dev/ttyACM0 > data.log" &
add a comment |Â
up vote
1
down vote
accepted
up vote
1
down vote
accepted
An alternative is to setup the device with stty
, then read it with cat:
stty <my options>
nohup sh -c "cat /dev/ttyACM0 > data.log" &
An alternative is to setup the device with stty
, then read it with cat:
stty <my options>
nohup sh -c "cat /dev/ttyACM0 > data.log" &
answered Jan 31 at 16:07
Gauthier
415518
415518
add a comment |Â
add a comment |Â
up vote
0
down vote
Assuming the user session is meant, you might be able to use screen
with the -X
option to send commands to a running screen session and the stuff
command to send keystrokes to the current window.
screen -dmS newScreen bash
screen -S newScreen -X stuff "picocom <options>n"
screen -ls
screen -r <pid>
Please take note to put the quotes around and the next line in order for the commands to be executed. *
... haven't checked if bash -c
or tmux
would be possible too.
add a comment |Â
up vote
0
down vote
Assuming the user session is meant, you might be able to use screen
with the -X
option to send commands to a running screen session and the stuff
command to send keystrokes to the current window.
screen -dmS newScreen bash
screen -S newScreen -X stuff "picocom <options>n"
screen -ls
screen -r <pid>
Please take note to put the quotes around and the next line in order for the commands to be executed. *
... haven't checked if bash -c
or tmux
would be possible too.
add a comment |Â
up vote
0
down vote
up vote
0
down vote
Assuming the user session is meant, you might be able to use screen
with the -X
option to send commands to a running screen session and the stuff
command to send keystrokes to the current window.
screen -dmS newScreen bash
screen -S newScreen -X stuff "picocom <options>n"
screen -ls
screen -r <pid>
Please take note to put the quotes around and the next line in order for the commands to be executed. *
... haven't checked if bash -c
or tmux
would be possible too.
Assuming the user session is meant, you might be able to use screen
with the -X
option to send commands to a running screen session and the stuff
command to send keystrokes to the current window.
screen -dmS newScreen bash
screen -S newScreen -X stuff "picocom <options>n"
screen -ls
screen -r <pid>
Please take note to put the quotes around and the next line in order for the commands to be executed. *
... haven't checked if bash -c
or tmux
would be possible too.
answered Jan 31 at 14:36
U880D
401314
401314
add a comment |Â
add a comment |Â
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f420953%2frunning-picocom-in-the-background-without-open-session%23new-answer', 'question_page');
);
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password