English
Language : 

AMIS-30621 Datasheet, PDF (36/59 Pages) AMI SEMICONDUCTOR – LIN Microstepping Motordriver
AMIS−30621
Writing Frames
The LIN master sends commands and/or information to
the slave nodes by means of a writing frame. According to
the LIN specification, identifiers are to be used to determine
a specific action. If a physical addressing is needed, then
some bits of the data field can be dedicated to this, as
illustrated in the example below.
Identifier Byte
Data Byte 1
Data Byte 2
ID0 ID1 ID2 ID3 ID4 ID5 ID6 ID7
phys. address
command parameters (e.g. position)
<ID6> and <ID7> are used for parity check over <ID0>
to <ID5>, conform LIN1.3 specification. <ID6> = <ID0> ⊗
<ID1> ⊗ <ID2> ⊗ <ID4> (even parity) and <ID7> =
NOT(<ID1> ⊗ <ID3> ⊗ <ID4> ⊗ <ID5>) (odd parity).
Another possibility is to determine the specific action
within the data field in order to use less identifiers. One can
for example use the reserved identifier 0x3C and take
advantage of the 8 byte data field to provide a physical
address, a command and the needed parameters for the
action, as illustrated in the example below.
ID
Data Byte 1 Data Byte 2
0x3C 00
1
AppCmd
command
Data Byte 3
physical
address
Data Byte 4
Data Byte 5
Data Byte 6
parameters
Data Byte 7
Data Byte 8
NOTE: Bit 7 of Data byte 1 must be at ‘1’ since the LIN specification requires that contents from 0x00 to 0x7F must be reserved for
broadcast messages (0x00 being for the “Sleep” message). See also LIN command Sleep
The writing frames used with the AMIS−30621 are the
following:
Type #1: General purpose two or four data bytes
writing frame with a dynamically assigned
identifier. This type is dedicated to short writing
actions when the bus load can be an issue. They
are used to provide direct command to one
((<Broad> = ‘1’) or all the slave nodes
(<Broad> = ‘0’). If <Broad> = ‘1’, the
physical address of the slave node is provided
by the 7 remaining bits of DATA2. DATA1 will
contain the command code (see Dynamic
assignment of Identifiers), while, if present,
DATA3 to DATA4 will contain the command
parameters, as shown below.
ID
ID0 ID1 ID2 ID3 ID4 ID5 ID6 ID7
Data1
command
NOTE: <ID4> and <ID5> indicate the number of data bytes.
ID5
ID4
Ndata (number of data fields)
0
0
2
0
1
2
1
0
4
1
1
8
Type #2: two, four or eight data bytes writing frame
with an identifier dynamically assigned to an
application command, regardless of the
physical address of the circuit.
Data2
Physical address
Broad
Data3 ...
Parameters ...
Type #3: two data bytes writing frame with an
identifier dynamically assigned to a particular
slave node together with an application
command. This type of frame requires that
there are as many dynamically assigned
identifiers as there are AMIS−30621 circuits
using this command connected to the LIN bus.
Type #4: eight data bytes writing frame with 0x3C
identifier.
http://onsemi.com
36