Chapter 8 Mantracan Communication Protocol; Basic Command Structure; Read - Mantracourt DCell User Manual

Strain gauge or load cell embedded digitiser module mantracan – 2nd generation
Hide thumbs Also See for DCell:
Table of Contents

Advertisement

Chapter 8 MantraCAN Communication Protocol

This chapter gives details of communication protocols and bus connections.
Each device has a singe base ID to enable configuration and is factory set to 1. All data sent to the device is sent to
this ID. All data returned from the device is on the base ID + 1.
The ID can be changed via standard parameters. Communications defaults are 500K bit rate with 11 bit identifier (CAN
2.0a)

Basic Command Structure

To read, write and issue commands the following protocol is used:
CAN ID
11 or 29 bit
ID
The ID of the device. set by NODEIDL and NODEIDH. The size of the ID is set by IDSIZE
Descriptor
The Descriptor is used to indicate the type of message, a message can be one of the following types:-
• Write which writes a new value into a parameter, Write is also used to perform an action command such as RST, in
which case no data is sent.
• Read is used to read back the value of a parameter.
• Response is always sent by the slave on receipt of a valid message. The response always returns the command
number byte sent by the master.
• A NAK is sent if the Command index is not recognised or if the data sent is invalid.
Command Number
Refer to the table in Chapter 9 for command numbers
Data
Data is ALWAYS in the format of a floating point number to the IEEE 854-1987 standard. When requesting parameter
values do not use data. Also do not use data when issuing a command.

Read

To read a parameter send message to appropriate ID with a Request descriptor, data will be ignored so can optionally
be left off.
CAN ID
Base ID
11 or 29 bit
Then wait a timeout period for a message of the Base ID+1 marked as either Response or NAK descriptor. If a response descriptor is received
then the result will be in the data part. The Command number in the reply will match the transmitted Command number.
Successful Response From Slave
CAN ID
Base ID + 1
11 or 29 bit
Not Acknowledged Response From Slave
49
Mantracourt Electronics Limited DCell & DSC MantraCAN User Manual
Descriptor
1 Byte
Type
Descriptor Value
Read
Write
Response
NAK
CAN Data
Descriptor
Read
Descriptor
Response
CAN Data
Command Number
1 Byte
1
2
6
21
Command Number
1 Byte
CAN Data
Command Number
1 Byte
Data
4 Bytes
Data
4 Bytes

Advertisement

Table of Contents
loading

This manual is also suitable for:

Dsc

Table of Contents