Community Documents

cancel
Showing results for 
Search instead for 
Did you mean: 

Animatics Smart Motor Control via RS232

Animatics Motor Control

Animatics are a company that make smart motors that can be controlled using RS232 serial commands. At STFC we have two of these motors that control a plate inside a vacuum tank. One motor is to lift the plate up and down the other is to rotate the plate inside the tank.This will be used for testing samples that need to be moved inside the tank.

As I could not find any LabVIEW Animatics motor control programs out there I made my own. Provided you have a similar motor controller to mine you should be able to control the motors with this program or to use this as a basis for your own program.

Untitled.png

Disclaimer

Anyone who runs and uses this code does so at their own risk. No liability is rested with the author of the code/program or with STFC.

Daniel Harryman MEng
CLA, CPI
Download All
Comments
jangwon
Member
Member
on

That is exatly what i need and i look for ,

Thanks to you,

I think I can controll smart motor in labview soon,

In my case, I have 2 motor in 1 port (ex COM1)

when I used SMI(smatr motor interface), I controlled motors using each address

Is it same in lavbiew ?

and would you please upload or e-mail under version vi ?

unfortunatly i have 2012 version.

I will wait for your kindness.

DanHarryman
Member
Member
on

Hi Jangwon,

I've uploaded the 2012 version of the code but will need to be approved by a moderator before you can download it I believe, hopfully won't take too long.

As for the code itself it should work controlling two motors from one port. One of the motors on our setup is a rotary motor, so the limit swtiches are disables as it has no limit. so you may want to take care when controlling the second motor if yours is a linear stage.

Thanks,

Dan

Daniel Harryman MEng
CLA, CPI
jangwon
Member
Member
on

Dan, I really appreciate for your kindness

I tried to understrand and run your vi for few days.

At fisrt time running your vi, 2 linear motors didn't move at all.

but order o=0 is can use.

Anyway I'm using your vi usefully and I can controll 2 motors

I don't understand yet, about ZS, RP, RU, RW, SLD, UDI, UCI..

I din't use RP, RU,RW ~~ not yet

one more time, I want to say thank you so much dan,

jangwon

DanHarryman
Member
Member
on

Hi Jangwon

I'm glad my code is of use to you. There's an Animatics document somewhere that tells you what each command does. I can't quite remember all of them (I should have commented better) but some of the ones you mention are:

ZS = Reset flags
SLD = software limit disable

UDI & UCI = something to do with the limit switches (at least i think so?)

RP = read position

RU & RW = one is read the limit switches, one is read the flags, unsure of what one each is

Daniel Harryman MEng
CLA, CPI
LaThoS
Member
Member
on

The first time I need some LabVIEW code in a hurry and Dan Harryman provides!

Are you sure you aren't still an AE? 😛

ewilliams
Member
Member
on

Dan,

Thank you for uploading your work and sharing it with us, and my apologies for resurrecting a 3 year old project. However, I was surprised to see someone else using the same technology.

 

We are looking to control an Animatics motor over serial, but not in LabVIEW. Was the communication to the motor as simple as sending the SmartMotor commands (same as you'd enter into the "Terminal" in SMI) to the appropriate COM port with the baud rate, parity, etc set correctly? We've tried to do the same from a standard TTY console with no luck so far.

 

Thanks,

Eric

DanHarryman
Member
Member
on

Hi All, 

 

I believe chatting through the console is pretty much the same as my LabVIEW program. I remember when I first built this I actually used their software, and a USB 'sniffer' that would monitor what commands are sent when you selected different commands on their software. I also re wrote this whole project using Objects and Classes about a year or so ago, but annoyingly I don't have a copy of the code as I no longer work for that employer. 

 

Happy to answer any questions if I can remember, 

 

🙂 

 

P.S. I'm no longer in AE (that was about 6/7 years ago now!), I'm actually a PhD student these days doing research into particle accelerator instrumentation, after working a few years at STFC doing the same thing. 

Daniel Harryman MEng
CLA, CPI
Contributors