STA015-STA015B-STA015T
5.6. STA015 CONFIGURATION FILE FORMAT
The STA015 Configuration File is an ASCII format. An example of the file format is the following:
58 1
42 4
128 15
............
It is a sequence of rows and each one can be interpreted as an I2C command.
The first part of the row is the I2C address (register) and the second one is the I2C data (value).
To download the STA015 configuration file into the device, a sequence of write operation to STA015 I2C
interface must be performed.
The following program describes the I2C routine to be implemented for the configuration driver:
42
4
I2C REGISTER VALUE
D98AU976
I2C SUB-ADDRESS
STA015 Configuration Code (pseudo code)
download cfg - file
{
fopen (cfg_file);
fp:=1;
/*set file pointer to first row */
do {
I2C_start_cond;
/* generate I2C start condition for STA015 device address */
I2C_write_dev_addr;
/* write STA015 device address
*/
I2C_write_subaddress (fp); /* write subaddress
*/
I2C_write_data (fp);
/* write data
*/
I2C_stop_cond;
/* generate I2C stop condition
*/
fp++;
/* update pointer to new file row
*/
}
while (!EDF)
/* repeat until End of File
*/
}
/* End routine
*/
Note:1
STA015 is a device based on an integrated DSP core. Some of the I2C registers default values are loaded after an internal DSP boot operation.
The bootstrap time is 60 micro second. Only after this time lenght, the data in the register can be considered stable.
Note 2:
Refer also to the application note AN1250
40/44