Regarding query ?FM on drive MDC2230

9 years 3 months ago #29528663 by rajeshwar
I am using limit switches for forward limit and reverse limit detection. I tried to use query ?FM to know the status of limit switches. The results I got was strange.

1. On forward limit for channel 1, the value returned was 128 (2^7).
2. On reverse limit for channel 1, the value returned was 512 (2^9).
3. On forward limit for channel 2, the value returned was 32768 (2^15).
4. On reverse limit for channel 2, the value returned was 0 (perhaps 2^17 which overflowed the data type and hence 0).

In the user manual, only seven different conditions (f1 to f7) was mentioned for query ?FM. which make me wonder that what are values of f1, f2...f7 for the above query? I was assuming them to be either 0 or 1.

Now I am stuck here and no clue how to check the status of reverse limit switch for channel 2.

Please Log in or Create an account to join the conversation.

9 years 3 months ago #29528664 by Griffin Baker
Replied by Griffin Baker on topic Regarding query ?FM on drive MDC2230
You check for the channel itself. If you are specifically looking at channel 2, then the syntax for the query is ?fm 2. If there are no status flags being used, then it generates a zero. Refer to Page 180 and 181. If you did ?fm, it looks at both channels, and adds them up.

Each flag status will be either a 0 or a 1.

As for the flag status, it reports back a decimal answer in which case you have to convert it to binary.
f1 = Amps Limit currently active - 0001 : 1
f2 = Motor stalled - 0010 : 2
f3 = Loop Error detected - 0100 : 4
f4 = Safety Stop active - 1000 : 8
f5 = Forward Limit triggered - 1111 : 16
f6 = Reverse Limit triggered - 0001 0000 : 32

Example channel 1
If the answer comes back as 3, then status flags F1 and F2 are flagged. If the answer is 25, then F1, F4, and F5 are flagged.

Please Log in or Create an account to join the conversation.

9 years 3 months ago #29528666 by rajeshwar


Griffin,

I am not looking for only channel 2. I am interested in both the channels and status of limit switches in each channel.
I was expecting the same response from drive as you have mentioned, but what I got surprised me a lot. Perhaps the image I have attached will make the things clearer.

I changed the configuration of Digital Inputs (DIN) as limit switches and checked the response from drive using hyperterminal on windows XP machine.
Attachments:

Please Log in or Create an account to join the conversation.

9 years 3 months ago #29528675 by Griffin Baker
Replied by Griffin Baker on topic Regarding query ?FM on drive MDC2230
Thank you for your screenshot and we will investigate this to see if this may be a bug in our software.

Please Log in or Create an account to join the conversation.

9 years 3 months ago #29528687 by Griffin Baker
Replied by Griffin Baker on topic Regarding query ?FM on drive MDC2230
Thank you for reporting this bug. Attached is the firmware to fix this for your controller. We will update this fix for all controllers in the next firmware release.

The update is a .dfu, so it will need to be upgraded via usb.
Attachments:

Please Log in or Create an account to join the conversation.

9 years 3 months ago #29528693 by rajeshwar
I tried to update the firmware but failed to do so.

1. First It was asking me to install drivers for STM32 DFU, which eventually I installed through zadig.

2. Even after installing the drivers for STM32 DFU, the DFU loader utility of Roborun crashes each time I tried to update the firmware.

3. I have attached the screenshots for your reference.

Please Log in or Create an account to join the conversation.

9 years 3 months ago #29528694 by rajeshwar





Pls find screenshots attached here.
Attachments:

Please Log in or Create an account to join the conversation.

9 years 3 months ago #29528695 by Griffin Baker
Replied by Griffin Baker on topic Regarding query ?FM on drive MDC2230
The drivers weren't selected. See attached.
Attachments:

Please Log in or Create an account to join the conversation.

9 years 3 months ago #29528696 by rajeshwar
I understood too that Roboteq DFU loader should detect a DFU device. I installed the driver again using ST microelctonic DFU utility and was able to uplaod the .dfu file to the drive using the Roborun DFU loader. But even then the response from drive remains unchanged.

Please Log in or Create an account to join the conversation.

9 years 3 months ago #29528697 by Griffin Baker
Replied by Griffin Baker on topic Regarding query ?FM on drive MDC2230
Did the controller update the firmware successfully?

If so, the power has to be cycled after you close out the DFU loader. This will then re-establish comm connections with Roborun+ again.

Please Log in or Create an account to join the conversation.

Moderators: tonysantoni
Time to create page: 0.098 seconds