| 전자부품 데이터시트 검색엔진 |
|
AN1278 데이터시트(PDF) 13 Page - STMicroelectronics |
|
|
|||||||||||||||||||||||||||||
AN1278 데이터시트(HTML) 13 Page - STMicroelectronics |
|
13 / 44 page ![]() 13/44 LIN (LOCAL INTERCONNECT NETWORK) SOLUTIONS The software is interrupt driven. As soon as a message begins on the bus, an interrupt is gen- erated and automatically handles the protocol. This means that the protocol handler is totally autonomous. It runs in the background. When the received frame is decoded by the software this is notified to the application in the lin_ai.c. In this file the user is able to customize the be- haviour of the application upon reception of a frame for example. 3.1 TYPES AND MACRO DEFINITIONS: LIB.H 3.1.1 Debug settings see 4.4.1 Timing considerations 3.1.2 Types The software uses predefined types for 1-byte and 2-byte variables. The name used for the one-byte type is “uByte“. The name used the two-byte type is “uWord”. Beside these, a third type is used to define two-byte variables that can also be accessed high byte or low byte only. typedef union { unsigned int w_form; struct { unsigned char high, low; } b_form; } TwoBytes; These types are defined in the lib.h file. 3.1.3 Macros Three macros for register bit access are defined: – SetBit(var,pos): Set bit “pos” of “var” variable – ClrBit(var,pos): Clear bit “pos” of “var” variable – ValBit(var,pos): Test bit “pos” of “var” variable. Return “0” if reset another value otherwise. 3.2 PROTOCOL HANDLER: LIN.P/H The lin.p file contains the protocol handler. The user has no access to this file. It should simply be linked to the rest of the application. The lin.p file is encrypted and can therefore not be read but must be compiled and linked to the rest of the application. The lin.h contains the definition of new types and the prototypes of the functions defined in lin.c. |
|
링크 URL |
| ALLDATASHEET 가 귀하에 도움이 되셨나요? [ DONATE ] |
Alldatasheet는? | 광고문의 | 운영자에게 연락하기 | 개인정보취급방침 | 링크 투 데이터시트 | 링크교환 | 제조사별 검색 All Rights Reserved©Alldatasheet.com |
| Russian : Alldatasheetru.com | Korean : Alldatasheet.co.kr | Spanish : Alldatasheet.es | French : Alldatasheet.fr | Italian : Alldatasheetit.com Portuguese : Alldatasheetpt.com | Polish : Alldatasheet.pl | Vietnamese : Alldatasheet.vn Indian : Alldatasheet.in | Mexican : Alldatasheet.com.mx | British : Alldatasheet.co.uk | New Zealand : Alldatasheet.co.nz |
|
Family Site : ic2ic.com |
icmetro.com |