Machsupport Forum

Mach Discussion => General Mach Discussion => Topic started by: xlr8sion on March 21, 2019, 06:28:57 PM

Title: Limit switches and PWM for laser
Post by: xlr8sion on March 21, 2019, 06:28:57 PM
Newbie online.  I have Mach3 running on windows 10 - no problems.  Trying to hookup limit switches to a Prt-E1500W (usb) spindle controller and possibly PWM control for laser.  Ive looked all over the net for answers, but none found. Any ideas?  After days of configuring the setup -- it works pretty as is.  I don't really want to go with a new BOB.  Can I run a different /smaller spindle controller, parallel on the (usb).

Thanks
Title: Re: Limit switches and PWM for laser
Post by: reuelt on March 21, 2019, 07:51:17 PM
I think you have confused the VFD inverter "PRT-e1500w" with the usb motion controller (& BOB).
You connect limit switches not to "PRT-e1500w" but to the Break Out board (BOB) model of which you have not identified by name.

https://madexp.com/wp-content/uploads/2018/01/PRT-E1500W-.pdf has good reference information for your "PRT-e1500w". Download that and save for later use.

But until you name your USB motion controller-break out board model, it is impossible to answer your question.
Title: Re: Limit switches and PWM for laser
Post by: xlr8sion on March 21, 2019, 08:41:33 PM
reuelt, thanks for the quick reply.  The only thing I can find is that it might be the TX14175.  Only photos of this BOB is for parallel hook-up.  Thanks again
Title: Re: Limit switches and PWM for laser
Post by: reuelt on March 22, 2019, 01:58:44 AM
We need definite model #
Perhaps
Unplug the power cable of the control box, open the lid and use your mobile phone camera to take a clear picture or two of the Break Out Board.
Usually the model number of the Break Out Board (BOB) will be engraved somewhere.
Upload the picture to this forum after some resizing and croping if necessary.

Don't change anything yet. Close back the lid and plug the power back on.
From the picture(s) some forum members might be about to suggest how you can connect the limit switches and what PWM adapter board you might need to buy for the laser.

Reuel
Title: Re: Limit switches and PWM for laser
Post by: xlr8sion on March 22, 2019, 11:55:40 AM
Reuel, I have found info on the usb interface card.  Made by Bitsensor,   BSMCE04V USB Board.  Here's the wiring schematic for anyone else that may need it.  This will take care of my needs. See attachment:
Title: Re: Limit switches and PWM for laser
Post by: xlr8sion on March 22, 2019, 12:01:21 PM
Reuel,  I forgot to thank you for all your help.  Still haven't found info on the spindle converter card.

xlrsion
Title: Re: Limit switches and PWM for laser
Post by: Overloaded on March 22, 2019, 12:35:46 PM
 :) Nice schematic of a typical set-up.
One little part could be corrected for clearer understanding.
Russ
Title: Re: Limit switches and PWM for laser
Post by: reuelt on March 22, 2019, 03:43:01 PM
Attached is a doc for BSMCE04V
From the doc, there is a 0-10V analogue output already used (to be used) for VFD spindle.
There is NO MORE PWM output usable for laser
Do you have the 4th Axis?
If not, I think someone in this forum used the output for unused pulse and Dir pins to control a laser.
Search this forum on laser ...
Title: Re: Limit switches and PWM for laser
Post by: xlr8sion on March 23, 2019, 12:59:16 PM
Reuelt, you are right.  I couldn't get any PWM from the spindle hookup for the laser.  Rec'd variable voltage form the AVI connection.  I'll look up the 4th axis hookup.  These machines are definitely not plug n play.  Fairly good learning curve for non electrical types.  I'm finding there is allot of good info and allot of bad info on the web.  Thanks for help.
xlr8sion
Title: Re: Limit switches and PWM for laser
Post by: xlr8sion on March 23, 2019, 01:01:27 PM
Thanks for the correction, I've learned that card maker has gone out of business.

xlr8sion
Title: Re: Limit switches and PWM for laser
Post by: MN300 on March 23, 2019, 01:56:50 PM
It would help to know if your laser is looking for an analog signal or PWM signal (digital). As an example, Opt Laser’s PLH3D will work with either.
Title: Re: Limit switches and PWM for laser
Post by: reuelt on March 24, 2019, 02:06:07 AM
It would help to know if your laser is looking for an analog signal or PWM signal (digital). As an example, Opt Laser’s PLH3D will work with either.
I think he already said PMW. It is easy to get an analog from PMW pin. His problem is his BOB has only an analogue to be used for Spindle.

In the USB system, you cannot just add another BOB (unlike parallel port system) - it won't work. You have to replace the whole motion control with a more expensive one + 2 parallel BOBs. Then you can have more than 1 PMW or analogue.
That's why I will never buy a cheap USB motion controller.
Title: Re: Limit switches and PWM for laser
Post by: xlr8sion on March 24, 2019, 03:31:21 PM
MN300, Here's the driver module.  I thought getting a usb vs parallel connection, I would be getting something easier to work with on the VFD inverter.  My bad.

xlr8sion
Title: Re: Limit switches and PWM for laser
Post by: MN300 on March 24, 2019, 06:25:02 PM
xlr8sion,

Your laser board appears to be a SW-LD73 V1.1 which uses PWM to control the output.

reuelt asked earlier if you are using all 4 axes. If one axis is free it can be used to provide PWM for the laser. If none are free and the laser is a must then you will need a different BOB board.

The documentation for the BSMCE04V USB board is questionable. The diagram seems to be from an Aliexpress site selling a controller and drive package. The PDF file says it's the Mach3 USB Motion Card STB4100 V2.1 Installation manual.

There is no explanation of the uses of AVI+ and AVI- terminals. In the diagram AVI- connects to the Inverter GND terminal, this would say it's the same as COM. If so, why isn't it just labeled COM? Although it's normally a high end feature maybe the analog output is opto-isolated. Use your ohmmeter to measure from the COM terminal to AVI+ and to AVI-. If the readings are infinite then the output is isolated.

Since this board is what you have let's make our best attempt to make it work.

First you can follow instructions and do the setup to get the axes moving. Leave the spindle and laser wiring for later. The switches in the diagram are all normally open. The home switches are connected in parallel. You will have to make sure none are on at the start of the homing sequence. If one is actuated at the start the controller would have no way to determine which it is and which axis to move to clear it. Actually I suppose if just the Z switch is on and the Z axis is first the homing will work.

Once you have things moving you can go on to the spindle and the laser.

MN300
Title: Re: Limit switches and PWM for laser
Post by: reuelt on March 25, 2019, 12:27:40 AM
"In the diagram AVI- connects to the Inverter GND terminal, this would say it's the same as COM. If so, why isn't it just labeled COM? "

Analogue ground for Inverter is different from COM which is the digital ground.
If the BOB provides 0-10V analogue rather than PWM, then there must be a separate ANALOGUE Ground which must not be connected to com.
I have a Nowforever VFD inverter and I MUST connect 4 wires to my BOB when others who use PWM only need 3 wires.

(The Manual was a translated manual from a Russian manual by someone in CNCZONE because no one could find the BSMCE04V manual anywhere . In Russia, the same board has a different model number.)
Title: Re: Limit switches and PWM for laser
Post by: xlr8sion on March 25, 2019, 10:24:06 AM
Reuelt, MN300,  thanks for all the time and effort that you have put into my questions.  Still working on the project.  And yes I do have the 4th axis that I can work with.  I still need to hook up the limit switches, have some cannon connectors on order for the backside of the VFD box. Going with four connectors in case I renew the BOB.  Do I need to use shielded cable for wire run?  Connecting the switches in parallel as needed by the BOB, would disable the functions in MACH3 diagnostics readout.  Just the same, as long as keeps me from jamming the table.

xlr8sion -- may change to (snail), for my CNC experience
Title: Re: Limit switches and PWM for laser
Post by: MN300 on March 25, 2019, 10:41:34 AM
Yes, the equipment you have is limited but usable.

Could you get away without using shielded cable? - Maybe, but you don't want to find out the hard way. Run a separate shielded pair to each switch, someday you will probably invest in a better BOB board with more inputs.
I suggest that you start up the system is stages, First get the axes moving, then the spindle.

I can't find a manual for the hardware side of your PRT-e1500w inverter. Did you get a paper copy? A picture of its terminal strip(s) would be a help if nothing else is available.
Title: Re: Limit switches and PWM for laser
Post by: MN300 on March 25, 2019, 11:13:01 AM
It occurred to me that your system has only a software E-Stop. On an industrial machine the E-Stop hardware stops motion independent of the main control. Better BOB boards have a dedicated E-Stop input that will stop the steppers and the spindle immediately. You have to decide how much risk there is of damage to the machine and of personal injury.

The inverter wiring can be tied to the E-Stop, this probably will involve adding a relay.

Info on your stepper driver boards will show if they have an enable input that can be shutdown by an E-Stop.

Title: Re: Limit switches and PWM for laser
Post by: reuelt on March 25, 2019, 05:25:49 PM
Reuelt, MN300,  thanks for all the time and effort that you have put into my questions.  Still working on the project.  And yes I do have the 4th axis that I can work with.  I still need to hook up the limit switches, have some cannon connectors on order for the backside of the VFD box. Going with four connectors in case I renew the BOB.  Do I need to use shielded cable for wire run?  Connecting the switches in parallel as needed by the BOB, would disable the functions in MACH3 diagnostics readout.  Just the same, as long as keeps me from jamming the table.

xlr8sion -- may change to (snail), for my CNC experience
If you have the 4th axis, there is another way to use the laser even without changing your BOB. You can have a micro-switch with bended long lever mounted on the spindle mount so that when the z-axis is lowered and the micro-switch is switched-on by touching the material, then the laser in turned ON.
You can get an external PWM power supply to control the light in volume.
Some have done it that way and uploaded videos on YOUTUBE
It is better to use shielded cable for the limit switches but even non-shielded wire is OK - IF you use "normally closed" limit switch system. Because the two limit switches connected in series for each axis and are normally closed (current is already flowing), it is less affected by EMI noise.
Even with limit switches installed, you should set up soft limits to trigger about 0.1" BEFORE the far end limit switches go open.
Take a clear picture of your BOB (as I requested before) and I can help you with limit switches step by step.
Title: Re: Limit switches and PWM for laser
Post by: joeaverage on March 25, 2019, 07:48:35 PM
Hi,
there is another way...its a bit of a cheat but it works.

If you have the 4th axis step and direction pins still available use the direction pin to turn the laser on or off
and use a frequency-voltage converter IC on the step pin to generate an analogue voltage.

There are some significant limitations with this idea.

The main one is that if you want a low laser output power then the step frequency of the 4th axis will necessarily be
low, so low in fact that it may represent the limiting axis of a coordinated move (the  X and Y axes go slow so as to be
coordinated with the 4th axis). Conversely if you limit the 4th axis step frequency and thereby establish a maximum
analogue voltage then the 4th axis will again be the limiting axis.

Craig
with respect to coordinated moves.
Title: Re: Limit switches and PWM for laser
Post by: xlr8sion on March 27, 2019, 12:07:34 PM
 reuelt, here's some photos of the  STB4100.  It's located at the back of the controller box and is hard to photograph.

xlr8sion
Title: Re: Limit switches and PWM for laser
Post by: reuelt on March 27, 2019, 07:31:37 PM
You board has ONLY 4 inputs.
One input (pin 1) must be used for E-stop

Would you sacrifice the use the probe input (pin 4)  so that I can have 3 separate X Y Z limit switches?
If so follow attachment for wiring.
If not you have to combine all X Y Z 6 switches in series into 1 input say pin 2.