1
Mach SDK plugin questions and answers. / Re: Movement plugin with DDA
« on: February 08, 2013, 09:43:19 PM »
Sorry, I made a mistake above: it is 22/42 fixed point format. So you have to devide by 2^42.
This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.
Hello to all.
I have written a plugin for Mach3, that uses my USB movement controller. I have a problem with a misunderstanding of units, in which DDA values are measured. I assumed, that DDA frequencies are 4467843509235 (yes, about 4 trillion!) times greater than my real frequencies, and everything works fine. But I would like to discover this magic constant and understand how it works. Can anyone helps me?
1. Is there a way to set the Mach error label like MachErrorMsg("*********x") or SetMachError("*********x")? From the Shuttle Plugin:
void SetMachError(Cstring Message){
CString *err = &MainPlanner->LastError;
if(err != NULL )
*err = Message;"}
In Ed's -TrajectoryControl structure LastError is a LPCSTR pointer. In C++/CLI I came up with:
void SetMachError(LPCSTR Message){
LPCSTR err = (LPCSTR)&MainPlanner->LastError;
if(err != nullptr )
err = Message;// Compiles NO OUTPUT
}
Has anybody figured this out?