About Firmwared#


Firmwared is a daemon whose job is to manage a pool of machine firmwares, to run one or even several instances of these firmwares and to make sure there is no harmful interaction between them and with the host system.

Three man pages are available : firmwared, fdc and firmwared.conf. To display them:

$ fdc --help
$ firmwared --help
$ firmwared --help-conf

Starting firmwared#

As mentioned in Quick start, firmwared can be started via systemd:

$ sudo systemctl start firmwared.service

or it can be started directly within a shell…

$ sudo firmwared

If you know what you are doing, you can customize the default settings. To achieve that, create a file firmwared.conf in /etc and put the options you would like to set. The list of the available options is available in firmwared’s help page.

Example of firmwared.conf to enable some extra logs in ulog.

-- lua language syntax


To have firmwared take this file into account, just restart it.

$ sudo systemctl restart firmwared.service

To see the logs produced#

By default, all logs produced by firmwared are directed to ulog. Therefore to see the logs, launch ulogcat from root user:

$ sudo ulogcat -C -v long

fdc (FirmwareD Client)#

fdc is a command line tool that lets you control and monitor firmwared. Below are some typical examples of what fdc can do. To have more info, refer to the man page.

  • list up the firmwares present in the cache

$ fdc list firmwares
  • list up the existing firmware instances (should be none if no simulation is running):

$ fdc list instances
  • retrieve information about an existing instance:

$ fdc show instances tremulous_patty
name: tremulous_patty
sha1: 13238174bdcb5db0327832bc39c5bd240b4637d7
id: 1
pid: 1
state: ready
firmware_path: /opt2/work/sphinx/firmwares//ardrone3-milos_pc.ext2.firmware
base_workspace: /opt2/work/sphinx/mount//7d99bf3e58c94f938113cdcf24a0b0d00e240840
inner_pts: /dev/pts/10
outer_pts: /dev/pts/7
firmware_sha1: 2722eb42c643febd76fa9d99433b7e56a8778737
time: Fri Jun 12 14:39:06 2015
virt_iface: eth0
cmdline: /sbin/boxinit ro.hardware=mk3_sim_pc ro.debuggable=1 ro.boot.console=/pts/10
  • kill (if needed) and remove a specific instance:

$ fdc drop instances tremulous_patty
  • kill (if needed) and remove ALL instances. This command is convenient when spurious instances are still running in background for any reason.

$ fdc drop_all instances