Linux 5.10 Yocto SDK
V2.1
7/25
© MicroSys Electronics GmbH 2022
4.2
Running Linux Programs
Once you see the Linux prompt and have logged on, you can enter Linux com-
mands. Here are some useful commands:
# uname -a
// shows Linux kernel version and other info
# ifconfig -a
// shows the Ethernet interfaces, including IP addresses
# df
// display filesystems
# cat /proc/mtd
// shows the partitions in NAND Flash
# reboot
// gracefully shutdown Linux and reboot
# shutdown now
// shutdown Linux immediately (no reboot)
# restool dpmac info dpmac.17 // show status of the Ethernet port in MC domain
4.2.1 Ethernet Connectivity
One of the first things you are likely to want to do is transfer programs from your
host machine to the SBC target.
By default, the Linux is not configured to use DHCP, therefore no IP address will
have been assigned.
To see the Ethernet interfaces, enter:
root@mpxls10xx:~# ifconfig -a
The SBC-LS1046A and SBC-LS1088A will show 4 Ethernet interfaces and the
SBC-LS1043A will show 3 interfaces.
To assign an IP address to an Ethernet interface, you can either configure the in-
terface manually:
CRX05:
root@mpxls10xx:~# ifconfig fm1-mac3 192.168.0.111 up
CRX08:
root@mpxls10xx:~# ifconfig dpmac17 192.168.0.111 up
Or, to avoid having to enter this every time you boot Linux, you can edit the
/etc/network/interfaces
file and add configurations for all the interfaces you
intend to use. For example, here fm1-mac3 is configured to use dhcp:
root@mpxls10xx:~# cat /etc/network/interfaces
# /etc/network/interfaces -- configuration file for ifup(8), if-
down(8)
# The loopback interface
auto lo
iface lo inet loopback
# The fm1-mac3 interface
auto fm1-mac3
iface fm1-mac3 inet dhcp