From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.
We appreciate your patience as we improve our online experience.
From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.
We appreciate your patience as we improve our online experience.
04-14-2010 11:39 AM
Hi Adam,
I suggest that you stick to MAX to troubleshoot this issue. I am a little confused on how you're using the Halt/ Kill modes. It is important to understand the difference and use what applies to your application. Here is a good document that explaines the Stopping Modes . Also, I was wondering what is the sittings on your PID Gains (Kp, Kd, Ki); Do you have reasonable values?
Thanks and have a great day.
Esmail Hamdan | Applications Engineering | National Instruments
04-30-2010 11:57 AM
Hi Esmail,
I'm familiar with the different stopping modes. The problem with a halt is that it requires encoder feedback in order to stop properly (hence the PID values make a big difference). I should of explained our end application better, but we're using an optical encoder within a magnetic resonance imaging scanner. We occasionally loose encoder feedback to to EM interference (this requires a separate solution altogether). So we need our limit switches to function as a stop even when our servo system becomes unoperational (hence the kill rather than a halt).
I checked another thread (http://forums.ni.com/ni/board/message?board.id=240&message.id=8846&query.id=3926216#M8846) and they suggested adding a line of code which calls "Set u32.flx" (Attribute = Stop Type on Switch, Value = 2). Apparently the "value = 2" changes the default behaviour of the limit switch to call a kill rather than a halt. We added this to our VC++ application and it seems to have solved the problem for our acutal program. I can now litterally disconnect the encoder (simulating and EMI problem) and prompt the system to move either in the forward or reverse direction and the corresponding limit switch will actually kill the motor once triggered.
I am wondering now how this "Set u32.flx" can be configured in MAX though, so far there doesnt' seem to be a way to access these low-level controls in MAX. This isn't a show stopper for us, since we only use our VC++ application when we're down in the MRI, but it would be nice to know if these attributes are accessible in MAX.
Thanks,
Adam
05-03-2010 03:59 PM
Hi Adam,
MAX is a wonderful tool for troubleshooting, but changing the default behavior and other lower level attributes are not available in this program.
Cheers,