Resources | developer.brewmp.com Resources | developer.brewmp.com

Developer

resources

File formats used in the Resource Manager

The Resource Manager uses the following file formats.

Brew MP module files

  • The CIF is a human-readable file that provides metadata about a module, and describes resources that the module requires to execute in the Brew MP application execution environment. CIF files are Lua tables that contain C primitives, used to provide metadata about the module, and information about resources that it requires. CIF contains information used to generate stub code needed for the module generation. The Resource Manager incorporates the CIFC compiler to generate the MIF and associated stub code, based on the input CIF files. CIF assigns the ClassID, and calls a C function to create the class. The CIF class declaration gets the specified function name.
  • The MIF is a binary file used in the Brew MP application. The MIF contains metadata about the module, and describes resources that the module needs in order to execute. The MIF is generated from the CIF by the CIFC compiler. After the MIF is created, it is submitted with the binary and loaded on a target device. You can create multiple MIFs with images for different device displays.

Brew MP resource files

The CIFC compiler takes the CAR file and compiles it into a BAR file for use in the final application.

  • The CAR is an intermediate file, in CIF format. The CAR file can be edited using the Resource Manager and saved until it is ready to be used as input to the CIFC compiler to produce the final output.
  • The BAR is a binary file produced by the CIFC compiler as part of the final output.

The files (CAR and BAR) are placed in the same directory, unless the output location is changed using Settings (see the section on Compiling Brew MP resource files from the GUI for more information). If you try to generate the final output without saving the intermediate file, the Save dialog prompts for the name and directory path of the intermediate file. The same directory and root name (CAR filename without the .CAR extension) are used to generate the BAR file. Conversely, if the intermediate file is saved before generating the BAR file, you are not prompted for the name and directory path. The Resource Manager uses the stored directory name and root name of the intermediate file to generate the final output filenames.