Piezo20 probe and piezo kit now available
-
As most firmware does not look at the sensor other than when probing this does not normally create a problem. However, the LED on the piezo sensor boards on my 3D printers flash a lot during printing so there is signal to work with. If the amplifier put out an analogue signal instead of a logic one then perhaps the firmware could be set to look for error indicating values.
Mike
-
Well whether it's designed to or not it does put out an analogue signal. I can read from 216 to 1000 on the duet web control depending on rate of pressure change on the piezo. It's goes to around 500 during rapid moves or over rough previous layers. I set 600-700 as a trigger level for probing.
But even then what would we use as a stop trigger? 1000? Maybe a slowdown to half speed at 700 then gradual increase back to normal at the next layer? It would be interesting to develop as its not been done before that I am aware of.
700 equate to 15g of force on probing, I'll set 1000 (or 999) probing threshold and stick the scales under the nozzle.
-
I'm on holiday at the moment but when I get home I'll dig out the protoboard version of the circuit and have a look at the output of the differentiator section on an oscilloscope during a print. The output of the differentiator should be an analog signal proportional to, in my case, movement of the bed.
If anyone has access to a 'scope you're looking at either pin 1or pin 9 of the IC or the centre most end of either C1 or R3
Idris
-
So a bit of experimenting.
Set the probe to digital in config.g using
M558 P5 I1 F500 X0 Y0 Z0
G31 X0 Y0 Z0 P100And in this mode (I am using inverted setup for piezo board (active low), if you are using active high then remove I1) the G31 P100 is the debounce which filters the signal, so using this config I can probe at normal speed/jerk/accel which brings the probe performance into line with that on smoothieware, which has debounce parameter also.
However in this mode I think it would be less easy/not possible to use data from the probe for crash detection/quality improvement as discussed above by briangilbert, unless we take a feed from the pins Moriquendi suggested above and connect them to a spare analogue input on the duet. And then there is some coding required.
Here is it probing at normal speed:
https://youtu.be/MURqDTL9oVA -
Piezo endstops? Don't mind if I do
Idris
-
Idris How repeatable it it? I have a few of them 10.5mm ones now
Doug
-
I've only just got it together but it seems to be pretty good, not sure exactly how I'll measure repeatability but I'll have a look at it tomorrow.
Idris
-
I realise that in my excitement to show off the piezo endstops working I didn't actually show how they were working and how they were set up, I'll try to rectify that now.
Very simply I have a 10.5mm (also very thin, 0.2mm) piezo element centred below an 8mm hole in the mount, the head of the bolt in the carriage touches dead centre in the bottom of the piezo.
One of these at the top of each axis connects to the three channel endstop board. The sensitivity and threshold of each channel is linked so they all trigger at the same force.
I think I've reached the limits of rigidity of my printer as I'm not seeing any improvement in z-leveling. I think that DJdemonD's printer is rather more robust so hopefully when he gets round to playing with the board I sent him we'll get better data on accuracy and repeatability.
I've got six more of these endstop boards on their way from OSHpark and hopefully they'll be here within two weeks.
I'm still working on the best way to organise piezos as endstops and their signal conditioning requirements, I could use some feedback here.
One option I'm looking at is an integrated board that has a piezo soldered on as well as the signal conditioning circuit, you'd then need one of these per axis. The issue with this is that you wouldn't be able to tune them, or if you could you couldn't guarantee that they were all tuned the same, I don't know how much of a problem this would be. This is likely to be the simplest, mount it, plug it in and forget about it. the difficulty is I'd have to find tuning values that work reliably for everyone.
Option two is the same as one but the piezo mount part of the board can be snapped off and mounted separately, this gives more flexibility without having the have multiple board types.
Option three is what I have at the moment, one board handling three separate piezos, the issue here is that long wires may pick up interference and in the app note we're warned against long wires due to the capacitance affecting the strength of the signal. How long does the cable have to be before this is a problem, no idea, may need further investigation.
Opinions most welcome, or if you've got other ideas I'd love to hear them.
Idris
-
Wiki page http://reprap.org/wiki/Piezo-electric_sensors
Feel free to edit if you have the access or let me know if you want something changed.
-
That's actually very helpful, DjDemonD.
Made me realize I need to change my mount idea a little bit.
-
Idris - Haven't tried them yet, though I will. The first and second options sound good but, you/we will have to supply and pretest the piezo discs, the sensitivity etc shouldn't be a problem we'll just find the optimum for whichever Piezo can be reliably sourced into the future. Same as opto/IR sensor they're pre-calibrated.
Option 3 sounds less exciting but currently we all have long wires running to each endstop terminating at the controller. So it would be a case of using the same wires just terminating them at the 3-Piezo board which can be installed next to the controller. So that's less change for existing machines.
Just some thoughts which will probably change after I've tried them, I wondered about supporting the disc at one side and having my carriages hit the other side for maximum flex (and signal).
-
That's actually very helpful, DjDemonD.
Made me realize I need to change my mount idea a little bit.
Maybe but if it's not too difficult try it then change it if it doesn't work, as these things are very versatile, most designs work but some are slightly better signal to mechanical noise ratio. Let us know either way.
-
Will do. Trivial to change either way.
-
Option 2 sounds the most appealing to me.
-
Idris could you possibly use individual screened 2 core cable to try and reduce the Capacitance effect or even screened single core cable routed the opposite way round the frame.
Just random thoughts
Rapid online is a good source of Cheap Piezo discs in all sorts of sizes and I will be experimenting with mine at the weekend once I have finished my Callout week
-
Just a thought about the endstops. How do we test them? Is there a gcode for test endstop repeatability? I can install them and then autocalibrate and measure the precision? Or do repeat endstop calibrations and measure the spread, compared to my opto's I have now?
-
Ok, got my pcb, mounted up the piezo, ready to go… connected to the duet, and no matter what it shows a signal of 1000 on the Z-Probe value.
I'm using either of the two configurations below:
M558 P5 I1 F500 X0 Y0 Z0 ; Z probe is a piezo sensor
G31 X0 Y0 Z0 P100 ; zprobe height and threshold - piezo;M558 P1 I1 F500 X0 Y0 Z0 ;analogue piezo sensor output falls on contact, probing speed, not used to home axes
;G31 X0 Y0 Z0 P700 ;sensor is nozzle and trigger value.Shows 1000 for a value if the signal line is connected. I have the LED wired up, and it's off. What am I missing?
-
Using a multimeter, it's putting out 3.3v on the signal line all the time, regardless of if the LED is lit or not.
Hmm.
-
I take that back, when the LED is lit, the signal stops. if I trigger it rapidly enough, the z-probe value falls to 0.
Switching the I1 to I0 to invert it did the trick. Should be ready to rock now.
-
Go easy at first lower your motor currents during probing, to the minimum needed to move the axes, mine are at 500. Then any head crashes are fairly low impact. A little finesse on the signal conditioning board is required.
The digital config above M558 P5 …. is the one to try first. Lower the debounce value if you get false triggers.
Any issues with that, switch to the analogue one and use the analogue value as a guide for fault finding, use low jerk/accel values with this mode.