Support

If you have a problem or need to report a bug please email : support@dsprobotics.com

There are 3 sections to this support area:

DOWNLOADS: access to product manuals, support files and drivers

HELP & INFORMATION: tutorials and example files for learning or finding pre-made modules for your projects

USER FORUMS: meet with other users and exchange ideas, you can also get help and assistance here

NEW REGISTRATIONS - please contact us if you wish to register on the forum

Users are reminded of the forum rules they sign up to which prohibits any activity that violates any laws including posting material covered by copyright

Auto Com ?

Discuss Control Systems here

Re: Auto Com ?

Postby JB_AU » Tue Aug 05, 2014 12:00 pm

Helps to not turn ruby off!

I now only need to add some delays , but most importantly stop the module from firing until i have entered the vid & pid.
I dare say i have to wrap that ruby descriptor code into an if statement or something simpler & wait for the button to be pressed.

Oh my, round & round i go.

regq_autocom.fsm
(30.83 KiB) Downloaded 2473 times
"Two things are infinite: the universe and human stupidity; and I'm not sure about the the universe."

Albert Einstein
User avatar
JB_AU
 
Posts: 171
Joined: Tue May 21, 2013 11:01 pm

Re: Auto Com ?

Postby JB_AU » Fri Aug 08, 2014 10:41 pm

I'm just stuck, when no port is found it gives a message , after acknowledgement i need to reset the counter & clear the descriptor values.
Then it's finished & can go into 'user examples' , where someone can add polish.
This project i started when i got the flu weeks ago.

I knew the windows registry holds current ports of active hardware & previous ports, but nether the same port for different hardware to reduce conflicts.
The KEY i was interested in was 'HKLM\SYSTEM\CurrentControlSet\Enum\USB\' , so i needed to look at the Device Descriptor VID(VendorID) & PID(ProductID) & do a recursive search. Knowing that a usb device is either SI(SingleInterface) or MI(MultipleInterface).
I use ShellExecute to load REG.EXE & Thanks to 'TheOm' i used his ruby code so i could do a recursive search, I then filter the results with "Trogluddite's" stringystuff filters.
Compare the array of known useable ports from 'ComPort' module & 'and' them against the current interface in registry 'MI0x' looking for the value that exists in both arrays.
The cycle is repeated until either a 'Port' value is found or 'No' value is found, where the latter 'Nubeat's' messagebox asks to check the hardware.

And of course just some finishing touches needed.

regq_autocom_rev.fsm
Rev0.0005
(30.77 KiB) Downloaded 2508 times
"Two things are infinite: the universe and human stupidity; and I'm not sure about the the universe."

Albert Einstein
User avatar
JB_AU
 
Posts: 171
Joined: Tue May 21, 2013 11:01 pm

Previous

Return to Machine Control

Who is online

Users browsing this forum: No registered users and 2 guests