Friday, June 30, 2017

The Secret Combination to Unlocking AutomationDirect Stepper Motors in LabVIEW

I was working on a radiation leakage test system trying to control a STP-DRV-4850 motor designed to spin an array of D-tect sensors around a unit under test.  I was able to spin the motor using AutomationDirect's utility program, SureStep Pro and everything was looking good, until I tried to send the motor controller serial commands from LabVIEW.

After beating my head against the wall for the greater part of an hour, I finally turned to the Internets for wisdom.  I had exhausted all the usual serial communication suspects:

Read the manual?  Check.
COM port?  Check.
Baud rate?  Check, 9600.
Command format?  Check, working in SureStep Pro.
Reread the manual?  Check.
Termination on writes?  Check, carriage return.

No matter what I tried, I could not get this motor to turn.  I had talked with countless instruments over serial and considered myself an expert.  And now my customer was looking over my shoulder, expecting to see magic.

The first few Google hits covered the usual issues (see above) and I began to despair.  After resorting to the second page of hits (who goes there?) I hit gold with an obscure post on the NI forums from 2011.  Apparently lmtis (Jim) had run into the same problem and went to the effort of hooking up a USB bus monitor.

When AutomationDirect's utility, SureStep Pro, connects serially to motors, it first sends an "HR" command.  I quickly tried it, and sure enough, everything started working.

I'm still not sure what "HR" stands for, but it is the "open sesame" of the STP-DRV world.  And after six years it still hasn't made it into the manual (SCL Commands for STP-DRV-4850 and STP-DRV-80100 Step Motor Drives).

Friday, June 2, 2017

2017 World's Fastest LabVIEW Programmer - Endigit 1st and 2nd Places!

Last week at NIWeek, National Instruments held the World's Fastest LabVIEW Programmer competition.  With Robert Mortensen being the 2016 champion, Endigit was hoping to make an impact again this year.

In the first round of competition, competitors complete three programming challenges in as little time as possible.  The competition open to anyone attending NIWeek and runs in the LabVIEW zone on the Expo floor.  

Bryan Heslop from Endigit was the winner of the floor competition.  With the fastest time on the floor, Bryan went against Sung Jin KIM from South Korea.  Sung Jin won the event at NIDays in China and is Asia's Fastest LabVIEW Programmer.

In the final rounds both competitors are given programming challenges and race to complete them.  The first to win 2 challenges wins and advances.  Bryan and Sung Jin went head to head in the semifinals.  There was some fast programming and Bryan came out on top winning 2-1.

The finals featured two Endigit employees, Robert Mortensen and Bryan Heslop!  In an attempt to intimidate, Robert reminded Bryan that he had taken second place more times than Bryan had been to NIWeek, and was the reigning champion.  In awe of Robert's superiority, Bryan felt extreme nervousness because it was only his first time competing.

Robert used his programming wizardry to defeat Bryan 2-1 and retain his title as World's Fastest LabVIEW Programmer.

Congratulations to Robert and Bryan from Endigit and Sung Jin from South Korea for being the fastest LabVIEW programmers in the world!

Endigit is happy to help you with your LabVIEW programming needs.  Contact us for help with your projects.