Software Description
KT912F634UG User’s Guide Rev. 2.0 10/2013
Freescale Semiconductor, Inc.
33
Archive Information
Archive Information
The variables “*fm_address“ (pointer to char) or “*fm_address_16“ (pointer to int) have information on the
register addresses being accessed. If the write command was requested, the values from “fm_data“ or
“fm_data_16“ are written to the address listed in the “*fm_address“ or “*fm_address_16“ variables.
Finally, the variable “fm_status“ is set to “done”. The FreeMASTER then knows that the data was updated.
This code section is also checked if there was a request to enter the STOP mode (if fm_address == 0x216 and
fm_data == 0x1), because first the analog die has to be put in low power mode by writing 0x1 to the Mode
Control Register. The STOP instruction is then executed.
8.4.3
LIN Communication
8.4.3.1
Change of the LIN Communication Parameters
As previously mentioned, LIN communication parameters (baud rate, messages size, messages ID) are set
before code compilation in the LIN software driver. The baud rate can be changed in the file “
slave.cfg
“. The
baud rate is defined by the following formula:
SciBaudRate is the value written to the SCI baud rate register and BR is the real baud rate value (9600 or
19200). The size of the messages and the ID of the messages can be changed or added in the file “
slave.id
“.
The ID shall be assigned, based on the LIN 1.3 protocol specification.
SciBaudRate
BUSCLK
16 BR
⋅
-------------------------
=