AN2600 Freescale Semiconductor / Motorola, AN2600 Datasheet - Page 7

no-image

AN2600

Manufacturer Part Number
AN2600
Description
A Simple Keypad Using LIN with the MC68HC908QT/QY MCU
Manufacturer
Freescale Semiconductor / Motorola
Datasheet
FLASH/RAM
Memory Occupation
CodeWarrior
Project
MOTOROLA
Not assigned
Enable LED
Function
Short key press
Long key press
Description
®
A Simple Keypad Using LIN with the MC68HC908QT/QY MCU
Received message,
Received message,
These status variables are then used in the second function LIN_Msg().
Because they contain data to be sent by the LIN slave node, they are stored by
the LIN_PutMsg() function into the buffer linked with the message to be
transmitted.
LIN_GetMsg() reads the buffer associated with the message to be received.
Out of the two received bytes, only the LSB of the first data byte is used by the
application; when it is set, the LED on the PTA3 pin is switched on. The format
of the received message is shown in
The size of the code in the FLASH memory depends on the application
functionality, and can be as low as 1400 bytes (with minimum functionality) and
about 1900 bytes supporting the keypad functions.
The driver and presented application use about 100 bytes of the RAM memory.
The presented project is structured as shown in
Sources contains:
The last two mentioned files for the driver determine the behavior of the slave
node. LINmsg.c is used for the LIN frames definition, as provided in
Message Configuration File
MCU is used as a LIN transmit pin. The remaining files in Driver Source folder
Table 3. Format of the Received Command Message
higher byte
lower byte
Keypad status 1
Keypad status 2
Freescale Semiconductor, Inc.
(data1 variable)
(data2 variable)
Name
For More Information On This Product,
Application source code (also at LIN_Keypad_QY.c)
vector.c files
Driver source with files of the Motorola LIN QY/QT driver software
Driver config contains LINmsg.c and TxConfig.h files
Name
Table 2. Format of Keypad Status Variables
Go to: www.freescale.com
Bit 7
Bit 7
Key F Key E Key D Key C
Key F Key E Key D Key C
Bit 6
Bit 6
section. TX_Config.h specifies which pin of the
Bit 5
Bit 5
Table
Bit 4
Bit 4
3.
Figure
Bit 3
Bit 3
3. The subfolder
Bit 2
Bit 2
-—
Application Software
Key B Key A
Key B Key A
Bit 1
Bit 1
LIN
AN2600/D
Bit 0
Bit 0
LED
7

Related parts for AN2600