Boot Sequence Manages To Embedded MicroController For Seco Boards

From WIKI SECO

User Interface

The SECO Q7 module implements a supervisory system, SSM (Supervisory System Module), It has the options for control the Boot sequence of the module.Following one of the primary features of the SSM is :

• Boot sequence of the module

Note: This feature is only applicable for some listed SECO boards Q7-928, ΜQ7-962, SBC-984.

Many parts of the SSM system can be configured by the user to adapt the behavior of the module to the user’s needs. All the settings that are modified become permanent and remain even if power is removed from the module / system. Therefore, it is recommended to know all the various setting options very well before making any modifications on the SSM system functions3. However, in case of any errors, there is a method to reset the factory default parameters of the module .

For all the features implemented by the SSM, there are user level interfaces (file descriptors) available that enable setting and managing the configuration options. Such interfaces are realized through a virtualization of the configuration options in the file system directory /proc/ectrl. The following table describes the directory tree of the virtualized functions of the SSM system:

/proc/
|__ ectrl/
|__ events/
|__ power_management/
|__ boot/
|__ watchdog/

Further along in this manual, there will be a description of the various options available for each SSM function and the methods with which the user can manage them. Within each directory associated with a specific function, there will be different interfaces, called file descriptors, which can have permissions of read, write or both according to their functions.
In general, the access methods to the file descriptors are:

READ operation:
From within the directory where the file descriptor is, execute the following command Here we are explaining one of the following configurations are available for this feature to set the module’s boot mode:

cat file_descriptor_name

this command will display the value contained in the file descriptor.

WRITE operation:
From within the directory where the file descriptor is, execute the following command.

 
echo value > file_descriptor_name

For information on the return values for the cat command and valid input values for the echo command, refer to the description of the relative functions in the following sections.

The following configurations are available for this feature to set the module’s boot mode:

•Set the boot sequence device order.
•Select the recovery Device.

To manage the module’s boot mode, the user can use the relative interface available in the virtual directory under the following path: /proc/ectrl/boot/. Once in the directory, the user has available the following interface structure; each interface executes a specific function.

Boot/
|__ available_bootdevice
|__ boot_sequence
|__ devboot_1th
|__ devboot_2th
|__ devboot_3th
|__ recovery_boot

The available interfaces can be divided into the following two categories : Info Interfaces [available_bootdevice] These interfaces provide information on the relative settings of the module boot mode. The file descriptors have only read permissions.

available_bootdevice
A read operation on this file descriptor returns a list of all the possible peripherals that can be used as a boot device (i.e.):

 
root@imx6-qsdl:/proc/ectrl/boot# cat available_bootdevices 
0 internal uSD 
1 external SD 
2 internal eMMC 
3 internal SPI flash

Note: The return value varies according to the module being used. Infact, not on all the modules will you have all of the mentioned boot devices. The available boot devices vary not only according to the different module models QuadMo747-X/i.MX6, μQ7-i.MX6 or SECOμSBC-i.MX6, but even within the same model according to the product code / part number. Therefore, it is strongly advised to verify the devices available on your module by consulting the documentation (datasheet, manual) of the product and of the specific product code.

boot_sequence
A read operation on this file descriptor returns both the device boot order and the device chosen as the peripheral recovery device (i.e.).

 
root@imx6-qsdl:/proc/ectrl/boot# cat boot_sequence 
BootDev0: 1 external SD 
BootDev1: 2 internal eMMC 
BootDev2: 1 external SD
Recovery: 1 external SD

Setting Interfaces [devboot & recovery_boot]
Through these interfaces it is possible to set the behavior of the module during the boot phase. In particular, it is possible to set the sequence of the boot devices and choose the peripheral boot recovery device. The parameters are set by writing the desired values in the relative file descriptor, which have both read and write permissions. The following file descriptors are available through this interface. For a description of the possible values that can be written to the single file descriptors.

devboot_i_th
A write operation on this file descriptor allows the user to choose the boot device to insert in the ith position of the sequence.

recovery_boot
A write operation on this file descriptor allows the user to choose the device to be used as the peripheral recovery device following a watchdog timeout event (the WATCHDOG system needs to be correctly configured in this case).

Available boot sequence for SECO modules

Note: The boot sequence can be a combination of any of the available devices listed in the file descriptor. And below mentioned in the table of file description option of Boot_sequence of devboot_i_th are default to SECO modules.But you can change it as per your preference and need to follow with the WRITE operation explained above.

SECO Boards File description Permitted value Boot device selected
Q7-928 available_devices
0 Internal uSD
1 External SD
2 On board eMMC
3 On board SPI flash
Boot_sequence of devboot_i_th
0 External SD
1 On board eMMC
2 Internal uSD
Recovery:3 On board SPI flash
MQ7-962 available_devices
0 External SD
1 On board eMMC
2 On board SPI flash
Boot_sequence of devboot_i_th
0 External SD
1 On board eMMC
2 On board SPI flash
Recovery:3 External SD
SBC-984 available_devices
2 On board eMMC
3 On board SPI flash
Boot_sequence of devboot_i_th
3 On board SPI flash
2 On board eMMC
Recovery:3 On board SPI flash