Jump to content
  • 0

DMC60c CAN Bus


opethmc

Question

I am looking at the DMC60c CAN protocol guide and also the software API reference manual. What are the API numbers needed in the CAN message to communicate with the DMC60c. For example if I wanted to send a voltage command using the function driveVoltage, what should go in the API field (Byte 1) of the message identifier?

 

Thanks,

matt

Link to comment
Share on other sites

11 answers to this question

Recommended Posts

Hi @opethmc,

The message identifier for sending control messages, which are the types of messages that are sent for driving the output, is 0x02060000 (API  field = 0 decimal).  You need to append the device number of the target DMC60c to the lower 6-bits. This should be documented in the Output Control Protocol section of the DMC60C CAN Protocol Guide.

Thanks,
Michael

Link to comment
Share on other sites

@malexander Thank you. I am also wondering what message format to send to read the current, voltage, and fault information. I am trying to communicate over CAN from a texas instruments TMS570LC4357 processor to the dmc60c. In this case I am not able to use the API so I will have to directly communicate with CAN messages.

Link to comment
Share on other sites

Hi opethmc,

The current and voltage information is reported by the DMC60C every 100ms (by default) in the STSANALOG (0x020614C0) frame. This info can be found on page 28-30 of the CAN protocol guide.

Fault status can be found in byte 4 (fs2) in the STSGENERAL(0x02061400) frame that is sent every 10ms (by default). You can find the fault counts by reading parameters 51 through 57. This can be done by sending PARAMREQ (0x02061800) frames containing the parameter you want to read, then scanning for a PARAMRESP(0x02061840) packet.  This info can be found on page 12-28.

 

Hope this helps!

Tommy

Link to comment
Share on other sites

@tom21091 Thanks Tom, that's helpful. What is the bit rate of the DMC60c CAN line?

Is it possible to read the statuses from CAN and control the driver via PWM? There are 2 sets of input signals - can one be used for CAN and the other for PWM?

I have found from other posts on the forum that the CAN data rate is 1MBps, correct? I have connected Yellow and Green of one of the signal pairs to CAN high and CAN low respectively on a MicroChip CAN Bus Analyzer and I am not seeing any periodic messages sent out. Is there some configuration needed or should this be working out of the box?

Cheers,

matthew

Link to comment
Share on other sites

DMC60C is 1MBps. No, those green and yellow wires are connected together, either CAN or PWM, not both.

The DMC60C must be connected to a CAN bus controller to send out the periodic messages. Otherwise it will flash red. When it detects a CAN bus controller the LEDs will flash Yellow (by default).

 

-Tommy

Link to comment
Share on other sites

@opethmc

I think reducing the baud rate should be fairly simple but this will result in an image that's not compatible with First Robotics Competition and it wouldn't be compatible with our configuration utility, which runs on a RoboRio in the FRC environment. Assuming that I can find time to make such an image what baud rate did you have in mind and how many devices were you planning on having on the bus?


Thanks,
Michael

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...