Machsupport Forum

Mach Discussion => VB and the development of wizards => Topic started by: kerim on September 29, 2006, 07:19:14 AM

Title: Macro in background
Post by: kerim on September 29, 2006, 07:19:14 AM
Hi I'm new here and my English isn't very good so please be patient and full of understanding. Thanks.

My question is: How can I write macro which works in background while Mach3 is running? Macro must working all the time.

Is this possible? How can I do this?

kerim
Title: Re: Macro in background
Post by: Graham Waterworth on September 29, 2006, 12:51:34 PM
If you look in the manual under macropump that should do what you want.

Graham.
Title: Re: Macro in background
Post by: kerim on September 29, 2006, 05:02:44 PM
But macropump doesn't work all the time in background. It runs consistently. It run once and couple of seconds (I don't know how many) later it run again, and again. It's not working all the time continually without stopping or killing the process. Is it possible to do such a macro that works continually? If not, what period of time is betwean executes macropump?
Please help.
Thank you and sorry for my English again.

kerim
Title: Re: Macro in background
Post by: Graham Waterworth on September 29, 2006, 05:30:27 PM
the macropump runs about 4 times a second

Graham.
Title: Re: Macro in background
Post by: kerim on October 04, 2006, 05:52:00 PM
So, if I want to write a macro which sends dData to output port continually with frequency say about 100 dDatas per second, how can I do it?
I know that if I write simple macro like:

PutPortByte( 0x378, dData )

It will send dData to my COM port with frequency 4 dDatas per second but if I write:

While IsMoving()
PutPortByte( 0x378, dData )
WEnd

It sends dData with higher frequency, but I don't know what is the value of frequency and how to solve problem of a macro which sends dData with known value.
Please help.

PS. Sorry for being late. I was busy a little...