Benbox Laser Machines/CO2 Lasers/3D Printers

Software => T2 Engraving => Topic started by: a_kent on February 26, 2017, 04:44:12 PM

Title: T2 laser comes on when going to laser control. SOLVED!!
Post by: a_kent on February 26, 2017, 04:44:12 PM
When going from the main editing screen to the laser control screen, the laser comes on full for a couple of seconds.

This is startling and puts a mark on the board. I also am not in the habit of putting on the goggles until I hit 'go'!

I am running the A5 2500mw Banggood machine with the Mana SE board, with 1.1E firmware and T2 version 1.3W registered.
I have had it running only for a couple of days.

Is there a way to stop the laser from coming on like this?

Regards,
Kent

Title: Re: T2 laser comes on when going to laser control.
Post by: nottingham82 on February 26, 2017, 04:53:17 PM
oh the dreaded ttl firing up.  So this is a known issue.  Carolynsdad found a way to cut the circuit.  He has a writeup on it and Zax is working on something.  It has to do with the nano firing up during the pc handshake. 
Title: Re: T2 laser comes on when going to laser control.
Post by: Zax on February 26, 2017, 05:00:49 PM
It happens when Grbl is starting up, or rather before it has started. It doesn't do it on my system so must be a design fault with their latest modules.

There's not really a firmware/software solution although I may be able to workaround it.

Just leave the controller off until you are in the laser screen.
Title: Re: T2 laser comes on when going to laser control.
Post by: a_kent on February 26, 2017, 05:11:57 PM
I would be very interested in seeing what Carolynsdad found out!

I'm also a retired EE, so I can do things.

I do have the GRBL source tree. I have not scrounged for schematics on this design, although I seem to remember that it's all public domain.

Thanks!
Kent

Title: Re: T2 laser comes on when going to laser control.
Post by: Zax on February 26, 2017, 05:12:57 PM
Are you in the USA, and is you're laser what came in the latest kit?

Feel free to PM or email me if you prefer.
Title: Re: T2 laser comes on when going to laser control.
Post by: a_kent on February 26, 2017, 05:15:40 PM
Yes and yes.
Title: Re: T2 laser comes on when going to laser control.
Post by: ggallant571 on February 26, 2017, 05:27:07 PM
The design is not public. I reverse engineered the L7 & L8 controllers and posted the schematics on this site.

It is somewhat odd that not all systems behave this way. The the signal used for laser ON/OFF control is floating during reset but should not provide sufficient energy to turn the laser on. I suspect a pulldown resistor might might help. It is also possible that the boot firmware on some boards is driving the signal high.

IMO, the solution is to add hardware with an ENABLE signal (with pulldown) from a completely unused I/O pin.
 
Title: Re: T2 laser comes on when going to laser control.
Post by: a_kent on February 26, 2017, 06:02:18 PM
The design is not public. I reverse engineered the L7 & L8 controllers and posted the schematics on this site.

It is somewhat odd that not all systems behave this way. The the signal used for laser ON/OFF control is floating during reset but should not provide sufficient energy to turn the laser on. I suspect a pulldown resistor might might help. It is also possible that the boot firmware on some boards is driving the signal high.

IMO, the solution is to add hardware with an ENABLE signal (with pulldown) from a completely unused I/O pin.
 

Hi GG:
That is great that you were able to reverse engineer those things.

NO SIGNAL should ever ever be left floating!!! Rule in my camp. To many things can happen to that signal. All bad.

I have seen signals left floating where a new silicon revision caused a state change at any given point!

While I have no clue yet why this signal is doing what it is, I hope to find out.

I do know from past Atmel designs that you can program pull ups and pull downs in the firmware fuses. I think this is an Atmel processor used here, so yes, you can affect the hardware with the boot code and firmware, possibly.

Kent
Title: Re: T2 laser comes on when going to laser control.
Post by: Zax on February 27, 2017, 05:10:14 AM
The problem happens before Grbl is running, as it's booting up.

The pins haven't been assigned as inputs or outputs so are floating or in the wrong state, of course a good electrical design on the laser module side would still not allow a floating input to turn on the laser, even adding an enable pin wouldn't help if they don't design it correctly (it may also float high and trigger the laser).

I am going to send a_kent a Nano running Grbl 1.1e without the boot loader. It starts up almost instantly which I am hoping may help this situation. If you remember from Hippie's thread I wasn't able to replicate the pulse or see it with my o-scope but it's still worth testing.
Title: Re: T2 laser comes on when going to laser control.
Post by: a_kent on February 27, 2017, 02:08:57 PM
Well, it's fixed!
It really is the simple issue of a floating signal. I also consider this an engineering oversight.

If any of you have a Mana SE, you can easily see if you have this issue.
Put your glasses on first!!
Turn off the power to the board.
Unplug the USB cable from the Nano.
Then turn on the power to the board with the 12v supply plugged in.

On mine, the laser would go to full on and would stay there.

Mine would also turn on the laser when you first turn on your computer if you turn on the machine first. It would also turn on when you go into laser control mode from the T2 software.

To fix this, I installed a 1k ohm pull down onto the laser signal on the large board.
(Solder a 1k ohm resister between the 'S' signal and the center ground signal on the laser connector.)

Any resister value >1k is not enough.

On mine, this left the float at about 0.4 volts. When it is floating after power on, there is a very low level light from the laser, about like pressing the button on the laser module.

Also if anyone is using this board for driving a motor on the red connector, this same signal goes to the gate of a Mosfet that controls that motor. It will come on the same way the laser does without this pull down.

Best!
Kent
Title: Re: T2 laser comes on when going to laser control.
Post by: a_kent on February 27, 2017, 02:12:02 PM
And a HUGE thank you to Zax for the offer of sending a Nano board to me!!
Title: Re: T2 laser comes on when going to laser control. SOLVED!!
Post by: pascalp on March 01, 2017, 06:49:24 AM
I've just solder a 1k ohm resistor. Seems to works, test in progress.
Thanks
Title: Re: T2 laser comes on when going to laser control. SOLVED!!
Post by: ggallant571 on March 01, 2017, 08:06:42 AM
@a-kent - I consider it more than an engineering oversight. The entire MOSFET drive circuit is deficient. Each MOSFET has has definitive current and voltage requirements to reliably turn fully ON/OFF in a specified time. The AVR328 I/O pin barely suffices. I have 2 cheap NANO clone boards that generate less than 4.2V for a logic high and they cannot fully turn the MOSFET ON. The result is excessive heat. Eventually (2 minutes) they get stuck in the ON state and melt the PCB trace.

I have posted before and some users say my analysis is wrong. I contacted the MOSFET manufacturer and they agree with me. My boards now contain dedicated MOSFET driver chips. They work reliably and run cool with 3.3V ARM processors.

Perhaps there are power MOSFETs that do work with 5V logic. IMO - This circuit is something that a legitimate engineering department would investigate and make rock solid before releasing onto the consumer market.
Title: Re: T2 laser comes on when going to laser control. SOLVED!!
Post by: jtice on March 01, 2017, 08:10:09 AM
Any pics of where exactly you are soldering the resistor on?
Mine does as described, I have learned to just NOT have the work piece under the laser until AFTER I have started laser control.
But it would be nice to actually fix it.
Title: Re: T2 laser comes on when going to laser control. SOLVED!!
Post by: pascalp on March 01, 2017, 08:38:25 AM
My modded Mana SE, limit switch on D9 and 1k Ohm resistor.
Title: Re: T2 laser comes on when going to laser control. SOLVED!!
Post by: a_kent on March 01, 2017, 12:21:52 PM
@a-kent - I consider it more than an engineering oversight. The entire MOSFET drive circuit is deficient. Each MOSFET has has definitive current and voltage requirements to reliably turn fully ON/OFF in a specified time. The AVR328 I/O pin barely suffices. I have 2 cheap NANO clone boards that generate less than 4.2V for a logic high and they cannot fully turn the MOSFET ON. The result is excessive heat. Eventually (2 minutes) they get stuck in the ON state and melt the PCB trace.

I have posted before and some users say my analysis is wrong. I contacted the MOSFET manufacturer and they agree with me. My boards now contain dedicated MOSFET driver chips. They work reliably and run cool with 3.3V ARM processors.

Perhaps there are power MOSFETs that do work with 5V logic. IMO - This circuit is something that a legitimate engineering department would investigate and make rock solid before releasing onto the consumer market.

@ggallant571, mine (Mana SE) has a single Mosfet to drive the motor's low side on the red connector. I don't see a problem there.

My board does not have a Mosfet driving the Laser. It is a signal directly from the Nano. The same signal also drives the servo port.

Pascalp, that is perfect!
Kent


Title: Re: T2 laser comes on when going to laser control. SOLVED!!
Post by: ggallant571 on March 01, 2017, 04:15:20 PM
The MOSFET driving the "Motor" port is the problem.
Title: Re: T2 laser comes on when going to laser control. SOLVED!!
Post by: Zax on March 02, 2017, 06:36:45 AM
It's at the end of page 1 in this thread:

http://benboxlaser.us/index.php/topic,1705.msg20815.html#msg20815
Title: Re: T2 laser comes on when going to laser control. SOLVED!!
Post by: mrehmus on March 02, 2017, 08:55:12 AM
Thanks for the pictures.
Where do the wires go and for what purpose?
Thanks.
Title: Re: T2 laser comes on when going to laser control. SOLVED!!
Post by: Zax on March 02, 2017, 09:08:44 AM
http://benboxlaser.us/index.php/topic,1718.msg20827.html#msg20827

Title: Re: T2 laser comes on when going to laser control. SOLVED!!
Post by: a_kent on March 02, 2017, 11:11:33 AM
Thanks for the pictures.
Where do the wires go and for what purpose?
Thanks.

The wires on there are to some kind of limit switch as mentioned by Pascalp, and are not a part of this fix.
I have not looked into that mod.
Kent
Title: Re: T2 laser comes on when going to laser control. SOLVED!!
Post by: a_kent on March 02, 2017, 11:31:23 AM
The MOSFET driving the "Motor" port is the problem.

Ggallant571:
The Mosfet used on this board is rated at 10 amps continuous and 35 amps pulsed.
In this design, it is switching the low side of the motor port (ground side).
The gate voltage threshold is from 1 to 2 volts (Vgs), and is rated for logic levels.

So in this design, it is well implemented.

I have attached a datasheet for the part.

Kent
Title: Re: T2 laser comes on when going to laser control. SOLVED!!
Post by: ggallant571 on March 02, 2017, 12:46:12 PM
Thanks. Will order a tube and replace my current IRLR7843. They are cheaper than the mosfet driver chips.
Title: Re: T2 laser comes on when going to laser control. SOLVED!!
Post by: Koskee on April 02, 2017, 06:44:12 PM
So I did this mod with a 1k resistor, but the only effect was that it made my laser unresponsive. Trying to send Gcode wouldn't work, although i could still manually jog the steppers. As soon as I removed the resistor, it was business as usual. This leads me to believe that the pulldown that was installed was too strong for the signal from the arduino to be properly transfered. Are we sure that 1k is the appropriate value for the pulldown? Most any pullup/down I've ever seen are more on the order of 4.7k-100k+ with 10k being a very common value.
Title: Re: T2 laser comes on when going to laser control. SOLVED!!
Post by: ggallant571 on April 02, 2017, 07:04:54 PM
I agree that 1K is quite strong but I would expect the CPU to be capable of driving it high. I use 10K on my boards. I don't use the same CPU or MOSFET circuit so I cannot verify. Do you have a scope?
Title: Re: T2 laser comes on when going to laser control. SOLVED!!
Post by: Koskee on April 02, 2017, 07:09:31 PM
I have a really old analog scope, not good for much other than getting an idea what's going on. I'm not sure how to actually read voltages off of it and besides, it hasn't been calibrated since I got it off of eBay so I doubt it would be all that accurate anyway.

If you're using a 10k then maybe I will try that instead of messing about with measuring anything.
Title: Re: T2 laser comes on when going to laser control. SOLVED!!
Post by: ggallant571 on April 02, 2017, 07:22:45 PM
Please try and measure. The MOSFET spec sheet is brutal reading but I recall 3.0V being a good turn on voltage. Which controller do you have?
Title: Re: T2 laser comes on when going to laser control. SOLVED!!
Post by: Koskee on April 02, 2017, 09:01:29 PM
Mana SE, without the jumper. I bought it around Xmas 2016.
Title: Re: T2 laser comes on when going to laser control. SOLVED!!
Post by: denmark219 on April 04, 2017, 09:58:06 AM
I'm about to order a 1k resistor.... I have a Mana SE, this is the correct resistor for this mod correct?
Title: Re: T2 laser comes on when going to laser control. SOLVED!!
Post by: a_kent on April 04, 2017, 11:46:05 AM
1k is a value that will work with the Laser output of the Mana SE, IF the laser itself does not already have a pull down.

Again, the way to tell, is to turn on the Mana SE with the USB unplugged.

If the laser goes full on, then you need this mod. The laser will also go full on for a second or so when you go to Laser control from the T2 software if you need this mod.

Also, the MOSFET has no bearing on the port labelled 'Laser'. The MOSFET is used for non-TTL lasers on the red port labelled 'Motor'. It switches the low (ground) side of the laser power on this port.

The Laser port PWM control signal is a direct digital output from the Arduino. The Arduino has no trouble driving this signal with the mod.

Best,
Kent
Title: Re: T2 laser comes on when going to laser control. SOLVED!!
Post by: Koskee on April 04, 2017, 05:47:26 PM
Before you "order a 1k resistor" I would suggest ordering a pack of them, many different values. For the price you'll end up paying for a single + shipping,  you can get a handful of all different kinds that (assuming you will be doing something with electronics down the road) will come in handy at times you never would have expected. A few dollars will score you anywhere up to 50 different values x 10 of each. There's smaller packs as well.  Check eBay or whatever your site of preference may be. These are always good to have on hand, and are plenty cheap enough to do so. Then the value doesn't really matter until you receive them & then you won't order the wrong one! ;)

Edit: I tried a 10K, and the effect was the opposite.. The laser still works, however, it also still turns on when going into the control interface, so now I will try values between 1k and 10k until I find something suitable.

I tried to use the scope on it, didn't really get very far with it other than I had what appeared to be a PWM signal that kind of looked like --> I==I==I== (not really sure how I can use that to find the appropriate value, but the signal was in the 2us range if that means anything? Like I said this thing is analog as fk, and hasn't been calibrated since the early 90s lol)
Title: Re: T2 laser comes on when going to laser control. SOLVED!!
Post by: Stonemull on April 08, 2017, 10:11:13 PM
I just turned my damn laser on full power while not wearing goggles dammit.

Turned off the nano while motor switch was still on.

Added the 1k resistor but put it on the laser itself as I figure it is the laser that should be off with a floating signal.
If you have a bunch of SMD resistors and a small iron tip I suggest this is the correct location, soldered between the pwm and ground pins on the back of the laser board, no screws need to be removed as it is an accessible spot with the driver board still attached to the laser.

You might have to zoom in to see it. Also it does not totally kill the laser when floating but it is not full power any longer, just slightly brighter than the 'safe' mode button, at least it is not likely to cause damage any longer.

Title: Re: T2 laser comes on when going to laser control. SOLVED!!
Post by: Koskee on April 09, 2017, 09:51:26 AM
^ Pictures a little dark, but i see it! Only problem with it done this way is that it becomes no longer a "universal fix" that can be recommended to anyone with a mana board.. For example, I couldn't do this because I have a different laser module.

 Also I can report that with my mana se board and the 3.5w TTL laser (as discussed before in this thread) that these are my results so far:

1K - laser became completely unresponsive (actual value ~985ohm)
10K - no effect, laser still comes on (actual value ~9.89Kohm)
4.7K - no effect, laser still comes on (actual value ~4.66K)
(slowly chipping away at it since it's not super urgent and it would be super tedious to do it all in one go.. Will report findings once I have them)
Title: Re: T2 laser comes on when going to laser control. SOLVED!!
Post by: a_kent on April 09, 2017, 10:57:38 AM
That's the way it should work, Stonemull! Nice job with the SMD part.

It would also be interesting Koskee, to know why the 1k stops the 3.5 watt laser. It should not. It's just a digital signal going to the laser controller. A scope on the PWM would be interesting to see.

Kent
Title: Re: T2 laser comes on when going to laser control. SOLVED!!
Post by: Stonemull on April 09, 2017, 12:05:03 PM
I can't see why 1k would kill it either, I am pretty sure the nano pin goes straight to the laser terminals with no series resistor, a nano should be capable of 20mA for a single pin, so driving down to around 200 ohms should be fine.
odd ..
Title: Re: T2 laser comes on when going to laser control. SOLVED!!
Post by: Koskee on April 09, 2017, 11:55:34 PM
Maybe a loose fitting connector, parasitic resistance &  capacitance on the pcb traces, internal pullup, or the fact that the single pin is split into 3 separate servo, laser and motor connections (including MOSFET circuit) could add up to enough that he pin wasn't able to drive to the minimum 2.7V to properly propogate the ttl/pwm signal down the line?
Just guessing though.

It appears that the value is going to need to be between 1k and 4k7 anyway,  based on preliminaries, so it's not very far off from the suggested value if anything? Not really sure.

Could also be affected by the kind of wire I used between mana + ttl, since I didn't get one with either purchase, I had to make one.
Title: Re: T2 laser comes on when going to laser control. SOLVED!!
Post by: Stonemull on April 10, 2017, 01:06:18 AM
Loose fitting connector and perhaps a pull up on the laser would be the only valid concerns of that bunch.
The frequency is only 1 or 7.8khz depending on grbl version, mosfet gate is going to appears as a very small capacitance, the board does not even have a ground plane and paralelling a few connectors is not going to make capacitance any sort of issue.
In reality anything from 1k to 100k should do the job so I suspect the laser module has some odd input schematic to cause the weird response.
I would attempt to trace it out however it needs desoldering to remove and the interface chip has had its numbers sanded off.
Title: Re: T2 laser comes on when going to laser control. SOLVED!!
Post by: Koskee on April 13, 2017, 04:05:52 AM
Tried a couple more values tonite:
2K2 - 2.168k actual - no effect
1k5 - 1.461k actual - this value worked for me. Laser still functions, and does not turn on when it shouldn't.
So it appears that the prescribed value of 1k was not far off the mark for me, and the actual value of the initial resistor I used was lower than 1k (i think i metered it at ~968ohm but i didn't write it down, so going by memory). This is interesting because the same mod with a 2k2 did not yield results, and (barely) lower than 1k in the initial trial ended up modifying the signal so that it was not recognized. This seemingly gives a pretty narrow window for what values will work on my system. Something like 1K < R < 2K? Not sure why it would be quite so lucky, but it works now, so I'm satisfied.

Title: Re: T2 laser comes on when going to laser control. SOLVED!!
Post by: Zax on April 13, 2017, 05:02:20 AM
It shouldn't be that sensitive to resistance but glad you worked it out, 1.5k is very reasonable for a pull down.
Title: Re: T2 laser comes on when going to laser control. SOLVED!!
Post by: bernd.dk on December 29, 2017, 12:06:41 PM
1 k ohm / 0.25 W ---- the perfect solution for my system. It cost me about 10 cents and took 10 minutes.
Title: Re: T2 laser comes on when going to laser control. SOLVED!!
Post by: kered on January 02, 2018, 11:53:58 AM
For testing and finding the exact resister could i just push the legs of the resistor into the required pins on the back of the cable? would save a lot of soldering and desoldering.

cheers
Derek
Title: Re: T2 laser comes on when going to laser control. SOLVED!!
Post by: bernd.dk on January 02, 2018, 01:36:17 PM
Maybe with some hot glue ?, but I'm not sure you get electrical contact in this way. Just try and solder the small (0.25W/1KOhm) resistor, it's hard to destroy the print and there are no components on the opposite side.
Title: Re: T2 laser comes on when going to laser control. SOLVED!!
Post by: Zax on January 02, 2018, 01:51:17 PM
It will work just fine pushed in the connector, in fact I ran one of my lasers like that for a month before finally soldering it on the laser module input.
Title: Re: T2 laser comes on when going to laser control. SOLVED!!
Post by: kered on January 03, 2018, 01:20:02 PM
Thanks Zax, it will just till i find the right one then I'll solder it, a lot easier and faster to just plug & test, change , plug & test etc. once found then solder it.
cheers
Derek
Title: Re: T2 laser comes on when going to laser control. SOLVED!!
Post by: minora72 on January 13, 2018, 03:18:18 PM
Resistor added. VERY SIMPLE procedure... no laser discharge when switching on/off from T2laser.  Now I wish the trace frame could turn on and off through the software...

Always left wanting more!  ;D
Title: Re: T2 laser comes on when going to laser control. SOLVED!!
Post by: nottingham82 on January 13, 2018, 04:13:40 PM
you can just turn the laser power to 1 then click engrave frame (power on)
This will not affect your gcode and your engraving will still be at whatever power you had set.
Title: Re: T2 laser comes on when going to laser control. SOLVED!!
Post by: Zax on January 14, 2018, 05:59:29 AM
Exactly. Trace Frame does not use the laser (just shows you the perimeter with the head), Engrave Frame uses the laser with the manual power setting.
Title: Re: T2 laser comes on when going to laser control. SOLVED!!
Post by: pbucc on February 23, 2018, 06:14:06 AM
does t2 save the manual power setting?  if I make it 1 (i know the g code will use the speed there.) and close t2 will it save.?

also we are talking about the black and red leads.  i was going to stick the ends of the resistor into the cable leads.
Title: Re: T2 laser comes on when going to laser control. SOLVED!!
Post by: Zax on February 23, 2018, 06:35:19 AM
Yes T2Laser saves settings, but the manual power value has nothing to do with G-code generation. That is set on the design screen.

The resistor goes between the TTL signal and ground, which should be the yellow and black wires but I've seen so many with the wrong colors it's best to check the screen printing and put it between S and GND.
Title: Re: T2 laser comes on when going to laser control. SOLVED!!
Post by: dpharand on March 02, 2018, 08:50:53 PM
I'm totally green with laser.
Will adding a 1K resistor reduce the full power.
T2 is the way to go (I'm convince) but I didn't have that issue trying other software.
I repeat myself I'm a newby and don't want to offend nobody.
Could it be resolved in the software itself.
Title: Re: T2 laser comes on when going to laser control. SOLVED!!
Post by: ggallant571 on March 02, 2018, 09:25:45 PM
I suspect if you rewrote the Arduino boot loader (reset code)  you could reduce the time to a few microseconds. But then you couldn't use the built-in flash upload function. The $0.03US hardware fix is cheaper, quicker, and safer.
Title: Re: T2 laser comes on when going to laser control. SOLVED!!
Post by: Zax on March 03, 2018, 03:53:50 AM
No you do not lose any power, it is a TTL logic signal (5VDC) to turn the laser on and off. The laser is powered separately from the 12VDC. All you are doing is keeping the signal at 0V when it is not turned on, to prevent the laser from unexpectedly switching on. Logic is either on or off, so even if the signal were only 4VDC it would be full power.

I tested Grbl without the boot loader and the pulse was eliminated but many people don't have the hardware or skills to do this so it isn't practical.
Title: Re: T2 laser comes on when going to laser control. SOLVED!!
Post by: dpharand on March 03, 2018, 06:50:12 AM
Thank you for your quick reply.


Title: Re: T2 laser comes on when going to laser control. SOLVED!!
Post by: bennettmarks on December 17, 2020, 10:30:29 AM
I also had the same "laser on" problem. So I put a 1K resistor between the PWM and ground. It didn't work. I got it to work by reducing the resistor to 500 ohms. Now its perfect. Seems the requirement for pulldown resistance is potentially different for different setups. Thank to all for documenting and fixing the problem.