Welcome! Log In Create A New Profile

Advanced

RRF 2.04 and filament runout sensor command M591 P7

Posted by MKSA 
RRF 2.04 and filament runout sensor command M591 P7
February 19, 2020 03:49AM
Has anyone used this feature with a pulse generating runout sensor; command M591 P7 ....

How comes this function requires to print from the SD card (I assume it is the one on the controller board, containing the config and firmware)

Note I am using Sdavi firmware on a MKS Sbase and has already asked in the related thread. I found a free input pin I could use; not an endstop as the pin has to be interrupt capable.t.


"A comical prototype doesn't mean a dumb idea is possible" (Thunderf00t)
Re: RRF 2.04 and filament runout sensor command M591 P7
February 19, 2020 08:19AM
Quote
MKSA
Has anyone used this feature with a pulse generating runout sensor; command M591 P7 ....

There have been posts about this type of filament monitor on the Duet3D forum, so that type of sensor has definitely been used. BTW there is a section on the Duet3D forums for RepRapFirmware running on other hardware.

Quote
MKSA
How comes this function requires to print from the SD card (I assume it is the one on the controller board, containing the config and firmware)

It works when printing from any SD card managed by the controller, so on Duets that means either the internal one or an external one. But i think the LPC port only supports one SD card socket, not 2.

Have you tried doing a print with the sensor disabled (S0 in the M591 command), and sending M591 D# (where # is the extruder drive number) at intervals to see whether the firmware it is collecting calibration data?



Large delta printer [miscsolutions.wordpress.com], Robotdigg SCARA printer, Crane Quad and Ormerod

Disclosure: I design Duet electronics and work on RepRapFirmware, [duet3d.com].
Re: RRF 2.04 and filament runout sensor command M591 P7
February 19, 2020 10:19PM
Quote
MKSA
How comes this function requires to print from the SD card (I assume it is the one on the controller board, containing the config and firmware)

My guess would be cause when streaming GCodes from a host over USB/serial (i.e. PC, TFT32 etc) the printer doesn't know when its actually running a print, paused or if the user is just doing some manual moves etc as the host is in control, whereas when printing from SD the printer knows when its started a print, paused, stopped etc.

Since most people have the filament runout to run a macro (i.e. move to some location away from the printed part and do something etc etc), it could be dangerous to have that accidentally triggered when its not running a print, for example when you are changing filament and could have your hands inside the machine and suddenly it starts moving cause the filament detector has tripped. So I figure it's a safety feature.
Re: RRF 2.04 and filament runout sensor command M591 P7
February 20, 2020 03:26AM
@DC42
Thanks, will do some reading.
Note currently I am just making this sensor and integrating it in my extruder idler.
I found a small radially magnetised tore and wanted to try it. I get 6 pulses per turn which represents about 7mm of filament per pulse.

@sdavi
Indeed, makes sense if you want to be able to pause then resume a print but if you want to just raise an alarm then abort/stop, it would be nice to have it.
Note on the TFT32 I use as display/crude control panel there is an input for a simple ON/OFF filament outage detection. I prefer not to commit to this kind of panel and besides I would have to add some circuitry.


"A comical prototype doesn't mean a dumb idea is possible" (Thunderf00t)
Re: RRF 2.04 and filament runout sensor command M591 P7
February 21, 2020 11:11AM
OK, found a usable pin on the MKS Sbase, the one used for a 4th thermistor (???) as none of the endstop are interrupt capable. Got it to work. It just adds 2 g to my extruder and a nice flashing blue LED smiling smiley


"A comical prototype doesn't mean a dumb idea is possible" (Thunderf00t)
Re: RRF 2.04 and filament runout sensor command M591 P7
February 23, 2020 03:13AM
@DC42

M591 D0
SENDING:M591 D0
Pulse-type filament monitor on endstop input 3, enabled, sensitivity 7.143mm/pulse, allowed movement 80% to 120%, check every 8.0mm, measured sensitivity 7.105mm/pulse, measured minimum 93%, maximum 104% over 156.3mm

Looks OK isn't ?

About the parameter:

"Enn minimum extrusion length before a commanded/measured comparison is done, default 3mm"

Does it mean you only check ever nn ? So as my sensor only sends a pulse every 7mm, I have to make E bigger to avoid a false ?


"A comical prototype doesn't mean a dumb idea is possible" (Thunderf00t)
Re: RRF 2.04 and filament runout sensor command M591 P7
February 23, 2020 01:44PM
Yes, 1 pulse every 7mm isn't much. You will need a sample distance much larger than that. Try 35mm.



Large delta printer [miscsolutions.wordpress.com], Robotdigg SCARA printer, Crane Quad and Ormerod

Disclosure: I design Duet electronics and work on RepRapFirmware, [duet3d.com].
Re: RRF 2.04 and filament runout sensor command M591 P7
February 23, 2020 03:09PM
@DC42

Indeed, 7mm is quite big but I decided to use a magnet instead of an optical disk that would be bigger, fragile and subject to dirt.

Not easy to find multi pole radially magnetized magnets.The tore magnet I use (taken from a main timer clock "motor") has only 6 poles but is so small (9mm diam) I could fit it to my extruder idler (14mm).

The output I get is a square wave that corresponds to, (about) 3.5mm high, 3.5 mm low. I guess the firmware just look for the rise or fall. Using both would double the resolution provided the duty cycle to be 50% of course

Note, it seems to work with E = 8mm. If E is too big, there will be no filament left in the hot end making the "resume" pointless.

Edited 1 time(s). Last edit at 02/23/2020 11:24PM by MKSA.


"A comical prototype doesn't mean a dumb idea is possible" (Thunderf00t)
Sorry, only registered users may post in this forum.

Click here to login