OK, I have got the new DSPMC from Vital Systems hooked up and running. BUT I'm still running into the same problem that I had with the Galil.
Here is a copy of my M03 macro:
SpinCW = GetRPM()
Message "S-Word = " & GetRPM()
'high gear input OEM#1, output#7
'low gear input OEM#2, output#8
'DeActivateSignal(OUTPUT2)'Spin Reverse
'ActivateSignal(OUTPUT1)'Spin Forward
If SpinCW < 901 Then
Call LowGear
SetPulley(1)
End If
If SpinCW > 900 Then
Call HighGear
SetPulley(2)
End If
Sub LowGear
DeActivateSignal(OUTPUT7)'HG=7 LG=8
ActivateSignal(OUTPUT8)'Low Gear
While IsActive(OEMTRIG2) = False'HG=1 LG=2
Sleep 10
Wend
Sleep 100
If IsActive(OEMTRIG2) Then
Message "Low gear input is active"
End If
Call SpinSpindle
End Sub
Sub HighGear
DeActivateSignal(OUTPUT8)'HG=7 LG=8
ActivateSignal(OUTPUT7)'Low Gear
While IsActive(OEMTRIG1) = False'HG=1 LG=2
Sleep 10
Wend
Sleep 100
If IsActive(OEMTRIG1) Then
Message "High gear input is active"
End If
Call SpinSpindle
End Sub
Sub SpinSpindle
'DoSpinCW()
End Sub
Exit Sub
I'm just trying to test the gear changer without running the spindle, note the noted out 'DoSpinCW(). I can step through the macro just fine, I get all the messages and the wends work perfect. As soon as I try to run it through MDI, aka M3S100, I don't see the message from "Message "S-Word = " & GetRPM()". It still seems like it is running so fast through the program that it isn't reading it correctly. Even the Sleep 100's are not working in MDI, but work fine when stepping through it.
Any help would be great!!
Thanks,
Aero