Configuring RedBoot

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Configuring RedBoot

Configuring RedBoot

Configuring RedBoot

The configuration is made using a Minicom session that need to be established between host and target through serial port. To have an operational system been executed just on the power on, configure the right for Boot script. The chooses are shown in Boot Script section. To avoid the start of operational system, power on the board and press CTRL-C immediately. Wait until RedBoot> prompt appears.

Overview

The main command for beginners is fconfig -l that can be abbreviated as fc -l    This command shows the actual configuration of Redboot, like:

RedBoot> fc -l

Run script at boot: true

Boot script:

.. load -r -b 0x100000 /tftpboot/zImage

.. exec -b 0x100000 -l 0x200000 -c "noinitrd console=ttymxc0,115200 root=/dev/n"

Boot script timeout (1000ms resolution): 1

Use BOOTP for network configuration: false

Gateway IP address: 10.29.241.254

Local IP address: 10.29.241.6

Local IP address mask: 255.255.254.0

Default server IP address: 10.29.244.99

Board specifics: 0

Console baud rate: 115200

Set eth0 network hardware address [MAC]: false

GDB connection port: 9000

Force console for special debug messages: false

Network debug at boot time: false

RedBoot>

  • Run script at boot: set true for booting with a script or false to always enter on prompt directly
  • Boot script: define what commands to execute as script at the startup
  • Boot script timeout: how many time to wait before execute boot script
  • Use BOOTP for network configuration: set true for getting configuration from BOOTP or false for manually configuring gateway and IP address
  • Gateway IP address: The IP address of the gateway
  • Local IP address: The board IP address
  • Local IP address mask: The board IP mask address
  • Default server IP address: The host IP address when NFS and TFTP server are running

Configuring Network

Execute the command to configure network parameters:

RedBoot> fc 

This step guarantee the possibilities to load images from some server previously connected and configured.

For Use BOOTP for network configuration: answer false.

For Gateway IP address: type the gateway IP address of your network;

For Local IP address: type an IP address to your board, it needs to be a valid IP in your network;

For Local IP address mask: type the IP mask address;

For Default server IP address: type the IP of your host server where are running TFTP and NFS.

Pay special attencion for Update RedBoot non-volatile configuration - continue (y/n)?. Answer y to have your configuration saved in the flash.

To verify if your configuration is working use ping, be patient this command is very slow:

RedBoot" ping -h 10.29.244.99

Network PING - from 10.29.241.6 to 10.29.244.99

PING - received 10 of 10 expected

Use the "-n" option to change the number of pings and the "-r" option to speed things up, such as:

ping -n 3 -h 10.29.244.99 -r 10.

The boot script configuration is done in the next section.

Boot Script


NFS Boot


In NFS Boot mode, a kernel image and a root file system image are loaded from a configured server through TFTP and NFS that can be executed doing the development more easy.

To configure RedBoot for NFS Boot reset the board and press CTRL-C immediately.

In a Minicom session type fc to modify the configuration boot.

Enter the script boot below:

RedBoot> fc

Run script at boot: true

Boot script:

Enter script, terminate with empty line

>> load -r -b 0x100000 /tftpboot/zImage

>> exec -b 0x100000 -l 0x200000 -c "noinitrd console=ttymxc0,115200 root=/dev/nfs nfsroot=10.29.244.99:/tftpboot/rootfs init=/linuxrc ip=10.29.241.6:10.29.244.99"

>>

Boot script timeout (1000ms resolution): 1

Use BOOTP for network configuration: false

Gateway IP address: 10.29.241.254

Local IP address: 10.29.241.6

Local IP address mask: 255.255.254.0

Default server IP address: 10.29.244.99

Board specifics: 0

Console baud rate: 115200

Set eth0 network hardware address [MAC]: false

GDB connection port: 9000

Force console for special debug messages: false

Network debug at boot time: false

Update RedBoot non-volatile configuration - continue (y/n)? y

... Read from 0x07ee0000-0x07eff000 at 0x00080000: .

... Erase from 0x00080000-0x000a0000: .

... Program from 0x07ee0000-0x07f00000 at 0x00080000: .

RedBoot>

The script is composed by two lines. The first line load the kernel image (zImage) by TFTP from /tftpboot, the directory configured in TFTP.\

The second line executes the kernel and mount the root file system using NFS.

The path /tftpboot/ltib indicates the path that should be exported in the host machine. (It's the path in the /etc/exports)

10.29.244.99 is the host IP address

10.29.241.6 is the target IP address

Flash Boot


For flash boot the Boot Script differs a little bit:

fis init kernel

exec -c "noinitrd console=ttymxc0,115200 root=/dev/mtdblock8 rw rootfstype=jffs2 ip=none"

The value for root can be different for each board type.


Tags (1)
No ratings
Version history
Last update:
‎09-10-2020 03:04 AM
Updated by: