Machsupport Forum

Mach Discussion => General Mach Discussion => Topic started by: learman on February 18, 2009, 01:54:03 PM

Title: output for smooth stepper
Post by: learman on February 18, 2009, 01:54:03 PM
Bread boarding a smooth stepper,, First the things working,, X axis signals pin 2 and 3  fine, spindle signals pin 4 and 5 Good, both set to port 1.  Input good, oem triggers working, inputs on port 1.  Now the bad,, no output signals,, none,, even when I change the active low setting the pins has no response, my outputs are enabled and set to Port 1.. whats up any ideas ??

I and using a handy c11 Multifunction brakeout board from cnc4pc.

thanks
Josh
Title: Re: output for smooth stepper
Post by: learman on February 18, 2009, 02:56:36 PM
I am progressing slowly,, I changed the state my output pins are in to active low and hit apply and OK and there condition changed,, IE my LEDS lit up :)
So my smooth stepper is working the outputs, but is ignoring them in my Gcode?? I feel like I am missing an enable button some where

still working
josh
Title: Re: output for smooth stepper
Post by: HimyKabibble on February 18, 2009, 03:02:00 PM
I am progressing slowly,, I changed the state my output pins are in to active low and hit apply and OK and there condition changed,, IE my LEDS lit up :)
So my smooth stepper is working the outputs, but is ignoring them in my Gcode?? I feel like I am missing an enable button some where

still working
josh

You should be aware the CNC4PC C11 does NOT work well with the SmoothStepper.  That *may* be your problem.  Clearly Mach can "talk" to the outputs, and the SS is doing what it's told under "static" conditions.  The C11 contains filters on the Step/Dir lines which, due to their design, can filter out the step pulses from the SS.  I would expect it to work at least at low speed, but who knows....  I had to modify my C11 to make it work with my SS.  You should probably call Arturo at CNC4PC.

Regards,
Ray L.
Title: Re: output for smooth stepper
Post by: learman on February 18, 2009, 03:15:36 PM
Thanks for the post Ray,,
So you think the board is ignoring my M11 P4, M11 P9, output commands?,, could it be the bleed down resistors?

thanks
Title: Re: output for smooth stepper
Post by: Hood on February 18, 2009, 03:18:53 PM
what is M11?

Hood
Title: Re: output for smooth stepper
Post by: learman on February 18, 2009, 03:20:23 PM
M11 output on M10 Output off
Title: Re: output for smooth stepper
Post by: Hood on February 18, 2009, 03:23:46 PM
They are custom macros? if so that may be your problem as macros under 100 are reserved for Mach use. To be honest I have used custom macros under 100 and not had a problem but maybe the ones you are using are being used internally.
Hood
Title: Re: output for smooth stepper
Post by: learman on February 18, 2009, 03:32:20 PM
I have no custom macros, all the commands IE outputs on Outputs off I got of your wiki?  My system works ok with PP port exept for the loss of some steps here and there,, that being the reason I am trying out a SS

josh
Title: Re: output for smooth stepper
Post by: learman on February 18, 2009, 03:48:09 PM
I got those comands M11 and M10 from Brian Barker not a WIKI,, Sorry
Title: Re: output for smooth stepper
Post by: Hood on February 18, 2009, 03:54:07 PM
Have you set up a new profile for the SS? If you have then check that the M10 and M11 macros are there and that the content of them is correct.
Hood
Title: Re: output for smooth stepper
Post by: learman on February 18, 2009, 04:01:56 PM
I did set up a new profile for the SS and my setting are there Including the M10 and M11 in the Macro folder, I did not write these marcos they were already there..

Thanks
Title: Re: output for smooth stepper
Post by: Hood on February 18, 2009, 04:05:54 PM
yes but are the contents the same between the PP one and the SS one?
Hood
Title: Re: output for smooth stepper
Post by: learman on February 18, 2009, 04:08:36 PM
the contents in the folder are the same but when I go to click on the M10 or M11 file windows dose not now what program to use to open It.
Title: Re: output for smooth stepper
Post by: HimyKabibble on February 18, 2009, 04:12:14 PM
Thanks for the post Ray,,
So you think the board is ignoring my M11 P4, M11 P9, output commands?,, could it be the bleed down resistors?

thanks

I have no idea what M10 and M11 do.  But why aren't you using move commands (M0/M1/M2/M3)??  Or simply jogging?

Regards,
Ray L.
Title: Re: output for smooth stepper
Post by: Hood on February 18, 2009, 04:12:41 PM
Open it from Mach, operator menu then VB Editor. Then use File, Open and then browse to the macro you want to look at or edit.
Hood
Title: Re: output for smooth stepper
Post by: learman on February 18, 2009, 04:28:53 PM
OK I looked at both SS profile and Mill profile M10 and M11 commands in the VB editor,   and they are exactly the same  in both profiles, I dont understand how they work but they are the same

josh
Title: Re: output for smooth stepper
Post by: Hood on February 18, 2009, 04:30:31 PM
what are you using the outputs for and what outputs?
Might want to copy and paste the M10 from the PP profile into the SS profile just in case there is a difference.
Hood
Title: Re: output for smooth stepper
Post by: learman on February 18, 2009, 04:41:10 PM
Output #4 on pin 7 turns machine on, output #9 on pin14 turns cooling water on output# 5 on pin1 ejects a part,, there are a lot of things going on in a short amount of time



M3
X -00.000 Y00.00000 Z00.00000 F550.00
M11 P4
G1 X -00.145 Y00.00000 Z00.00000 F014.0
M11 P9
G1 X -05.0030 Y00.00000 Z00.00000 F078.0
M10 P4
M10 P4
X -06.000 Y00.00000 Z00.00000 F800.00
G4 P1.0
X -06.100 Y00.00000 Z00.00000 F7800.00
M11 P7
M11 P5
X -06.200 Y00.00000 Z00.00000 F800.00
M10 P9
G4 P00.2
M10 P7
X -06.250 Y00.00000 Z00.00000 F800.00
M6
G4 P0.5
X -00.000 Y00.00000 Z00.00000 F800.00
M30
M30

josh
Title: Re: output for smooth stepper
Post by: learman on February 18, 2009, 05:02:57 PM
I checked pin 1 without the c11 board hooked up and i did not see any voltage, I should have seen 5 v dc with my program running,, soo it must me in the SS ??
Title: Re: output for smooth stepper
Post by: Hood on February 18, 2009, 05:03:59 PM
Ah ok did  Brian write that macro specifically for you, the P values are for the outputs you want to use?
Hood
Title: Re: output for smooth stepper
Post by: learman on February 18, 2009, 05:28:31 PM
Yes P is the output being used but Brian didn't write these macros,, they are installed with mach3.

Could you write me a macro command to turn on an output #1 and to turn off an output #1 that the SS would understand.  If it works I will modify my G codes. And hopefully understand better how macros are written and write some for the rest of the outputs

josh
Title: Re: output for smooth stepper
Post by: Hood on February 18, 2009, 05:37:20 PM
Brian may well have written  these and put them in the Mach install.
You can easily  activate or deactivate an output via a macro but I would have thought if the PP is able to use them the SS should not have a problem, are you sure you have the outputs enabled?

If you want to write a macro you could have one for output 4 and name it M104.m1s and save it in the macro folder for the SS profile. What you would need in the macro is

ActivateSignal(OutPut4)

When you called M104 from code or MDI output 4 would switch on, you could then do the same to switch it off by making a macro called maybe M114.m1s and in that macro you would have

DeActivateSignal(OutPut4)

You can name the macros anything you want but under m100 is meant for Machs internal macros.



Hood
Title: Re: output for smooth stepper
Post by: learman on February 18, 2009, 05:45:41 PM
The outputs are enabled and when i load machmill and use pp port everything works.  Load mach Smooth stepper the signals for the motors and my inputs are all working but my outputs are ignored,, I will try your written macros tommarrow when i get back to the shop.. Ill post my results to let you know.

 thanks for you help Hood, have a good night
josh
Title: Re: output for smooth stepper
Post by: Hood on February 18, 2009, 05:48:48 PM
If I remember tomorrow I will give the M10/M11 macros a test on the mill and see if I can get them working.
Hood
Title: Re: output for smooth stepper
Post by: learman on February 18, 2009, 05:50:52 PM
Awsome,, I may have found a bug in the ss
Title: Re: output for smooth stepper
Post by: Hood on February 18, 2009, 05:52:47 PM
:D
Title: Re: output for smooth stepper
Post by: learman on February 19, 2009, 08:41:06 AM
Hood,,

I wrote 2 macro just as you described, named them M114 and M104 and sure enough my output turns on and off,, Thanks for your help.  Pls post if you got your M11 and M10 comands to work on your Mill

thanks
Josh
Title: Re: output for smooth stepper
Post by: Hood on February 19, 2009, 03:11:10 PM
I couldnt get M10/11 to work but possibly I am doing something wrong.
Could you attach the macro and xml of your parallel port setup and I will have a look and see if I can spot anything.
Hood
Title: Re: output for smooth stepper
Post by: learman on February 19, 2009, 03:21:56 PM
I dont like looking like a fool but I dont now how to post My Macro file, sorry
I could email them to you if you like
josh
Title: Re: output for smooth stepper
Post by: Hood on February 19, 2009, 03:26:45 PM
Have sent you a pm with my email address.
Hood
Title: Re: output for smooth stepper
Post by: Hood on February 19, 2009, 03:28:24 PM
For future reference, you can use the additional options on the reply page to attach files and pics to a post, you will have to rename a xml as the forum will only accept a file name once.
Hood
Title: Re: output for smooth stepper
Post by: mhasting2004 on March 11, 2009, 06:09:49 AM
Another newbie question.

I have no problems activating outputs 1,2,3,5,6 either by mapping them in ports and pins or via VB script. Output4 however does not want to play. It seems to be reserved by something else in Mach3 (ver R3.042.020,  SS beta 2 ver. 0.015obg) it is getting fired whenever i do a regen and also at specific times during the roadrunner file. It does not activate in single step mode.

Its not like Mach is trying to turn it on and the SS is not doing it. Nor is it noise or random. All inputs and outputs are optoisolated and run at 24VDdc. Pins have been reassigned to test with same result. Standard install no custome macros etc yet.

Is there a way to find out if a button or led in Mach has been assigned? Ive checked the edit button script and the XML but don't see anything obvious. Question has been posted over on the Warp9 forum as well.

For now I've reassigned the output elswhere to avoid output4 but would like to figure it out.

Cheers.

Mark
Title: Re: output for smooth stepper
Post by: Hood on March 11, 2009, 07:22:08 AM
Do you see the LED activating on the Diagnostics page?
Tried another revision of Mach as I seem to remember I had a problem with OP4.
Hood
Title: Re: output for smooth stepper
Post by: mhasting2004 on March 11, 2009, 10:59:03 PM
Yep.

Mach and SS are showing exactly what they are doing... just not why they are doing it :) I tried to spot something specific in the roadrunner Gcode that might be driving the signal but as far as I could see it was all just standard moves. I was thinking it may be a buffer full/empty type request between the Mach s/w and the SS and hence the question of is it reserved.

I've not tried earlier versions of Mach yet as I thought... latest and greatest lock down was the go.

Cheers

Mark
Title: Re: output for smooth stepper
Post by: Hood on March 12, 2009, 03:21:03 AM
Can you attach your xml and I will see if I can repeat the problem here.
Hood
Title: Re: output for smooth stepper
Post by: mhasting2004 on March 12, 2009, 04:20:40 PM
Here ya go

BTW Thanks for the help

Cheers

Mark
Title: Re: output for smooth stepper
Post by: Hood on March 12, 2009, 05:21:45 PM
It seems to be working fine here at the workshops desktop computer, write an ActivateSignal(OutPut4) and the LED lights up. Also ran the Roadrunner and didnt see the LED activate. Do you see it light up on the diagnostics page or is it something on your output that works when you do the Roadrunner?
Hood
Title: Re: output for smooth stepper
Post by: mhasting2004 on March 12, 2009, 08:59:52 PM
Hmm the plot thickens

ActivateSignal(outpu4)...... no light in diag, no output
Roadrunner regen.(or during the run).....Light in diag and output

Its not port or pin dependant eitehr as I have tried changing this to no avail.

Your running the same version of Mach3?

Cheers

Mark
Title: Re: output for smooth stepper
Post by: Hood on March 12, 2009, 09:15:31 PM
originally I was running 042.005 then tried with 042.022
However this was just the desk computer so no SS hooked up, both machines were being i=used so couldnt try on them but will tomorrow if I remember.
Hood
Title: Re: output for smooth stepper
Post by: mhasting2004 on March 12, 2009, 11:37:46 PM
Ok I guess its because the s**t goes down the toilet clockwise down here! ???

I just tried 42.022 (was 42.020 lockdown version) and have the same problem, Offline and setup to use the nonexistant parrallel port. So SS is off the hook.

May be relevant (but can't see how) but I'm running on a Compaq 8710W laptop.
 

very strange.

Mark
Title: Re: output for smooth stepper
Post by: mhasting2004 on March 13, 2009, 01:47:53 AM
Bit off topic but still possibly relevent...


Am I correct in assuming that the main issue with the use of Laptops and Mach3 are steady pulse timing related and that these issues are overcome by the SS generating its own clock?
So far the only issue I've had is this output4 and as I would assume that the SS driver translates this command into a serial string which is sent to and recognised by the SS board. And as such, the ability to send this string is not related to the platform on which Mach runs.

Interestlingly enough output4 acts the same way as any other output signal that is not enabled. You can run a VBscript activatesignal(output4) but it ignores the command. If I disable say port 3 it does the same.


So to recap.
Output4 is enabled but acts as if it wasn't and it can not be user driven but is activated by something elsewhere in the code.

I'll try loading this up on a old desktop I have at home this wekend and see if it works that way.

Cheers
Mark
Title: Re: output for smooth stepper
Post by: Hood on March 13, 2009, 03:21:21 AM
Just as a test can you set up another profile, entering your settings manually rather than copying, and try that to see if its still a problem.
Hood
Title: Re: output for smooth stepper
Post by: mhasting2004 on March 13, 2009, 05:47:29 AM
I'll give that a go, however in effect I think I allready did that by starting machmill and choosing the parallel port setup (neither of which had any settings) I also dissabled all inputs.

But for the sake of thorughness I'll start from a clean install.

I'll get back to you with the results.

Cheers

Mark
Title: Re: output for smooth stepper
Post by: mhasting2004 on March 13, 2009, 07:19:53 AM
Well as the saying goes... "if in doubt... chuck it out!"    Thats fixed it! cleaned out all the various installs of Mach and Quantum then reloaded 43.022 and reinstalled SS plugin, 10 minutes of reconfigure and boobs yur anty she all works... including output4


Thank you very much for your patience Hood and if you are ever in the newer, more southern version of wales you have a place to crash.

I owe you one.

Cheers

Mark
Title: Re: output for smooth stepper
Post by: Hood on March 13, 2009, 07:47:37 AM
Great your sorted :)
 Dont think they would let me in to Ozz ;D
 Hood
Title: Re: output for smooth stepper
Post by: mhasting2004 on March 13, 2009, 08:09:39 AM
Hey they let a half kiwi,half cunnuck in! let alone all them convicts in the first place  ;D

I'll drink to your health then!

Cheers

Mark

PS It actually fixed a few other things that where not right also that I had not noticed like a software e-stop dropping the charge pump.

Title: Re: output for smooth stepper
Post by: Hood on March 13, 2009, 08:22:32 AM
Yeh suppose so, they let my Uncle in so the regulations must be pretty lax ;D
Hood