Difference between revisions of "Command Line User Guide"

From ZynthianWiki
Jump to navigation Jump to search
 
(21 intermediate revisions by 5 users not shown)
Line 1: Line 1:
Use '''ssh''' to remotely access the console (terminal) of the Zynthian from another computer. Use the  '''ssh''' command in Mac Terminal or use the freely downloadable '''PuTTY''' software for Windows. You need to know the IP address of the Zynthian on your local network to use ssh. See [[Finding your IP address]] for help on this.
+
Use '''ssh''' to remotely access the console (terminal) of the Zynthian from another computer. Use the  '''ssh''' command on Linux/Mac Terminal or use the freely downloadable '''PuTTY''' software for Windows. In most modern computer, using the name "zynthian.local" should work. If it doesn't, you can use the IP address too. See [[Finding your IP address]] for help on this.
 
=SSH/SFTP access:=
 
=SSH/SFTP access:=
  
Line 5: Line 5:
 
  password: raspberry
 
  password: raspberry
  
User pi doesn't exist any more and ... it's a good idea to change the password :wink:
+
'''''Note:''' on the new Bookworm (64bit) image, still in development, the password has changed to '''opensynth'''.''
  
=Base Directory:=
+
If you use ssh from the linux/mac terminal, it's so easy as:
  
  /zynthian
+
  ssh root@zynthian.local
 +
or
 +
ssh root@zynthian.lan
  
Almost all the zynthian stuff like synth engines, audio plugins, soundfonts, zynthian user interface, setup scripts and other specific software is in this directory.
+
* User pi doesn't exist any more
 +
* It's a good idea to change the password, specially if your zynthian is connected to public networks. You can do it easily from the webconf.
  
=UI configuration file=
+
=Base Directory:=
  
  /zynthian/zynthian-ui/zynthian_gui_config.py
+
  /zynthian
  
This file contains some configuration parameters for the Zynthian User Interface:
+
Most of zynthian stuff is in this directory.
  
* Logging level
 
* Wiring layout
 
* Font & Color scheme
 
* etc.
 
 
=Stopping/Starting the Zynthian UI=
 
=Stopping/Starting the Zynthian UI=
  
You must use systemd-style commands to stop & start any system service, that includes the zynthian UI:
+
You must use systemd-style commands to stop & start any system service. For the zynthian UI you would use:
  
 
  systemctl stop zynthian
 
  systemctl stop zynthian
Line 32: Line 31:
 
If you want to run the Zynthian UI in the console,  you must stop the zynthian service and run the zynthian UI as a normal script using these commands:
 
If you want to run the Zynthian UI in the console,  you must stop the zynthian service and run the zynthian UI as a normal script using these commands:
  
  systemctl stop zynthian
+
systemctl stop zynthian
  /zynthian/zynthian-sys/sbin/zynthian.sh
+
zynthian.sh
 +
 
 +
Running zynthian from the console (terminal) allows you to view the detailed debug messages, which is convenient for solving issues. Posting these to the forum will enable experts to help you. You can also access the UI log messages from the webconf.
 +
 
 +
=Stopping/Starting the Zynthian Webconf=
 +
 
 +
systemctl stop zynthian-webconf
 +
systemctl start zynthian-webconf
 +
 
 +
If you need access the webconf's log messages, you can use:
 +
 
 +
journalctl -u zynthian-webconf
 +
 
 +
=Configuration without WebConf=
 +
If you can't access WebConf with a browser, you may edit this file:
 +
 
 +
/zynthian/config/zynthian_envars.sh
 +
 
 +
and run this command after saving the changes:
 +
 
 +
# zynthian_update_sys.sh
 +
 
 +
=Viewing the Zynthian graphics display on a computer=
 +
 
 +
If you are using Linux on your PC (or MacOSX with a X window server installed), you can login into your Zynthian box with '''ssh''' using the “-Y” flag:
 +
 
 +
  ssh -Y root@zynthian.local
 +
 
 +
this will allow you to run graphic applications in your Zynthian, while displaying the graphics window on your PC/laptop.
 +
 
 +
=Useful zynthian command line commands=
 +
 
 +
aconnect -l        list MIDI connections (that ALSA knows about)
 +
aplay -l          lists audio hardware devices (that ALSA knows about)
 +
aplay -L          lists the ALSA device names of all hardware and software devices
 +
alsamixer          graphical mixer program for the ALSA that is used to configure sound settings and adjust the volume
 +
aseqdump          show the events received at an ALSA sequencer port
 +
jack_lsp -c        lists connections to/from each JACK port
 +
lsusb              list known USB devices
 +
lsof              list of all open files and the processes that opened them.
 +
patchage          graphical modular patch bay for audio and MIDI systems based on JACK and ALSA
 +
gpioinfo          to see current GPIO status
 +
scrot              to take screenshots
 +
 +
export DISPLAY=:0  set which display is to be used
 +
 
 +
=Create screenshot=
 +
 
 +
1. Access to your Zynthian
 +
 
 +
2. If first time you create screenshot
 +
 
 +
export DISPLAY=:0  set which display is to be used
 +
 
 +
3. Take the screenshot
  
Running zynthian from the console (terminal) allows you to view the logging/debug messages, which is necessary for debugging (posting these to the forum will enable experts to help you.)
+
scrot file_name.png
  
=Debugging MIDI=
+
4. The screenshot will be in the root folder of your Zynthian
You can use commands to see what's going on with MIDI I/O
 
[[Debugging MIDI]]
 
  
 
=More detailed info=
 
=More detailed info=
  
 
More info on this page [[Accessing_Zynthian_from_your_computer]]
 
More info on this page [[Accessing_Zynthian_from_your_computer]]

Latest revision as of 19:04, 28 February 2024

Use ssh to remotely access the console (terminal) of the Zynthian from another computer. Use the ssh command on Linux/Mac Terminal or use the freely downloadable PuTTY software for Windows. In most modern computer, using the name "zynthian.local" should work. If it doesn't, you can use the IP address too. See Finding your IP address for help on this.

1 SSH/SFTP access:

login: root
password: raspberry
Note: on the new Bookworm (64bit) image, still in development, the password has changed to opensynth. 

If you use ssh from the linux/mac terminal, it's so easy as:

ssh root@zynthian.local
or
ssh root@zynthian.lan
  • User pi doesn't exist any more
  • It's a good idea to change the password, specially if your zynthian is connected to public networks. You can do it easily from the webconf.

2 Base Directory:

/zynthian

Most of zynthian stuff is in this directory.

3 Stopping/Starting the Zynthian UI

You must use systemd-style commands to stop & start any system service. For the zynthian UI you would use:

systemctl stop zynthian
systemctl start zynthian

If you want to run the Zynthian UI in the console, you must stop the zynthian service and run the zynthian UI as a normal script using these commands:

systemctl stop zynthian
zynthian.sh

Running zynthian from the console (terminal) allows you to view the detailed debug messages, which is convenient for solving issues. Posting these to the forum will enable experts to help you. You can also access the UI log messages from the webconf.

4 Stopping/Starting the Zynthian Webconf

systemctl stop zynthian-webconf
systemctl start zynthian-webconf

If you need access the webconf's log messages, you can use:

journalctl -u zynthian-webconf

5 Configuration without WebConf

If you can't access WebConf with a browser, you may edit this file:

/zynthian/config/zynthian_envars.sh

and run this command after saving the changes:

# zynthian_update_sys.sh

6 Viewing the Zynthian graphics display on a computer

If you are using Linux on your PC (or MacOSX with a X window server installed), you can login into your Zynthian box with ssh using the “-Y” flag:

 ssh -Y root@zynthian.local

this will allow you to run graphic applications in your Zynthian, while displaying the graphics window on your PC/laptop.

7 Useful zynthian command line commands

aconnect -l        list MIDI connections (that ALSA knows about)
aplay -l           lists audio hardware devices (that ALSA knows about)
aplay -L           lists the ALSA device names of all hardware and software devices
alsamixer          graphical mixer program for the ALSA that is used to configure sound settings and adjust the volume 
aseqdump           show the events received at an ALSA sequencer port
jack_lsp -c        lists connections to/from each JACK port
lsusb              list known USB devices
lsof               list of all open files and the processes that opened them.
patchage           graphical modular patch bay for audio and MIDI systems based on JACK and ALSA
gpioinfo           to see current GPIO status
scrot              to take screenshots

export DISPLAY=:0  set which display is to be used

8 Create screenshot

1. Access to your Zynthian

2. If first time you create screenshot

export DISPLAY=:0  set which display is to be used

3. Take the screenshot

scrot file_name.png

4. The screenshot will be in the root folder of your Zynthian

9 More detailed info

More info on this page Accessing_Zynthian_from_your_computer