For many embedded applications, you not only want the file to debug the target, that is generate *.abs or *.elf file, but you also need an S19 (Motorola S-Record) file, an Intel Hex file, or a Binary file of the application. Very likely you need these files for production programming or as input to other tools.
The wizard generated 8/16 bit projects for MCU10 includes a burner.bbl file for exactly this purpose. BBL stands for Batch Burner Language and is a simple batch/script language to generate and process S-Records, Intel Hex, and Binary files.
You can find the burner.bbl file within the Project_settings\Linker_Files folder in the project.
The file includes a script to generate an S19 file.
OPENFILE "%ABS_FILE%.s19" format=motorola busWidth=1 origin=0 len=0x1000000 destination=0 SRECORD=Sx SENDBYTE 1 "%ABS_FILE%" CLOSE
The script in burner file opens/creates a .s19 file, configures some settings, such as the output file format, sends all bytes from the application .abs file to the output file, and then closes it.
The *.bbl file is processed by the make file after linking the application binary. There is a graphical way to configure or create such a script file.
To configure burner script file graphically, perform these steps.
The Burner Default Configuration dialog box appears.
The Burner dialog box appears (as the image, Burner Dialog Box - Input/Output Tab listed below shows).
The Command File tab page displays the script as per the settings done in the Input/ Output and Content tabs.
Now, you can easily create a burner.bbl file that can generate three different output files, S19, Intel Hex, and Binary, as shown in the following listing.
busWidth=1 origin=0 len=0x1000000 destination=0 SRECORD=Sx undefByte=0xff format=motorola OPENFILE "%ABS_FILE%.s19" SENDBYTE 1 "%ABS_FILE%" CLOSE format=binary OPENFILE "%ABS_FILE%.bin" SENDBYTE 1 "%ABS_FILE%" CLOSE format=intel OPENFILE "%ABS_FILE%.hex" SENDBYTE 1 "%ABS_FILE%" CLOSE
Also, the BBL file allows you to merge multiple files. For example, you can take a Binary file as input and convert it into an S-Record file. Or you add additional information to your files.
For example, if there is an S19 file that defines a firmware signature, and you want to make sure this signature is included into the S19 file for production.
You can implement the burner.bbl file as shown in the following listing.
OPENFILE "%ABS_FILE%.s19" format=motorola busWidth=1 origin=0 len=0x1000000 destination=0 SRECORD=Sx SENDBYTE 1 "%ABS_FILE%" SENDBYTE 1 "MyFirmwareSignature.S19" CLOSE