Writeflashcodesectorline(); Description; Actions; Prototype - Infineon SP37 Function Manual

High integrated single-chip tpms sensor with a low power embedded microcontroller and wireless fsk/ask uhf transmitter
Table of Contents

Advertisement

2.31

WriteFlashCodeSectorLine()

2.31.1

Description

This function offers the possibility to write one Code Sector (sector 0) flash line. It enables the application program
to modify the code sector, thus enabling code patches or configuration blocks to be applied to the Flash during
application execution.
Some requirements to use this function are mandatory:
The code sector must be unlocked
The flash-line to be written must be already in erased-state
No provision for erasing the Code Sector via ROM library call will be provided
The function can not be called in debug mode
This function writes one line (32 bytes) to the Flash Code Sector located at Flash address 4000
SP37 is in RUN mode and Lockbyte 2 is not set the write is performed, otherwise this function will return -1. The
line contents are verified after the entire line has been written. In the event that the write verification fails, this
function will return -2.
Note: The application software has to ensure that Flash is only programmed or erased when all required
environmental conditions are fulfilled. Special care has to be taken that ambient temperature
V
voltage
and Endurance E
bat
Note: Each Flash Code Sector Line may be written only once. Once a line is written with data, it must not be written
again. there is no corresponding ROM function to erase the Flash Code Sector under application program
control.
2.31.2

Actions

Write one Code Sector flash line.
2.31.3

Prototype

signed char WriteFlashCodeSectorLine (unsigned int StartAddress, unsigned char idata *WrData)
2.31.4

Inputs

Table 133
WriteFlashCodeSectorLine: Input Parameters
Register / Address
R6, R7
R5
ROM Library Function Guide
n
are within specified range (see [1]).
FL
Type
Name
unsigned int
Startaddress
unsigned char
WrData
idata*
Tire Pressure Monitoring Sensor
Description
Must be between 4000
containing Lockbyte2 is excluding)
Must be multiple of 32
Pointer to 32 Byte buffer in RAM holding the
contents to be written to the specified Flash line.
107
SP37
ROM Library Functions
-- 575F
. If the
H
H
T
, supply
FL
and 575F
(the line
H
H
Revision 1.0, 2011-12-15

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents