Page 14 of 14

Re: Duet setup - instructions in progress

Posted: Thu Jan 05, 2017 3:46 am
by dc42
Bang-bang for the bed only works well if the temperature fluctuations it causes are very small and the PSU is well-regulated (otherwise the voltage fluctuations cause the extruder heater power to vary, which typically causes banding). Now that we have auto tuning, I recommend using PID for the bed.

Re: Duet setup - instructions in progress

Posted: Thu Jan 05, 2017 7:13 am
by DeltaCon
dc42 wrote:Bang-bang for the bed only works well if the temperature fluctuations it causes are very small and the PSU is well-regulated (otherwise the voltage fluctuations cause the extruder heater power to vary, which typically causes banding). Now that we have auto tuning, I recommend using PID for the bed.
Does Bang-Bang in your reprap branch work different then in a Rambo firmware? Else I have no clue as to why my fluctuations are so high, except for the fact that I am using 20V for it (that probably explains it). I assume that the DC42 firmware also sustains dead-time? I am not liking PID for the difficult to understand parameters, and the fact that is switches very fast. I have a good Auber SSR but if I can make it go easy on it that's what I prefere (less change of overheating).

Re: Duet setup - instructions in progress

Posted: Thu Jan 05, 2017 10:51 am
by IMBoring25
One of them is on a Rambo (Kapton over glass over Onyx, Rostock), but that one is 12V for the time being. The other is 20V on RepRapFirmware (Kapton over glass over heat spreader over Mk 2B heated bed, Mendel). They run pretty similarly as best I can tell. Going easy on the SSRs was my reason also. Were I having your results and couldn't explain them I'd probably bite the bullet and go to dead-time.

Re: Duet setup - instructions in progress

Posted: Thu Jan 05, 2017 5:24 pm
by dc42
RepRapFirmware uses slow (10Hz) PID PWM for the bed and chamber heaters so as to be compatible with (and kind to) all types of SSR.

Re: Duet setup - instructions in progress

Posted: Fri Jan 06, 2017 3:45 am
by DeltaCon
dc42 wrote:RepRapFirmware uses slow (10Hz) PID for the bed and chamber heaters so as to be compatible with (and kind to) all types of SSR.
That is good to know, thanks! Which raises the next question: does PID really offer improvement when (through the use of a SSR) the current to the bed does not get limited like when you do 12V directly from the board? I thought the main raison for using PID was that it is able to regulate the current to the bed. 50% power through PID flips the SSR and 100% power from the PSU goes to the bed...

Re: Duet setup - instructions in progress

Posted: Fri Jan 06, 2017 12:30 pm
by dc42
DeltaCon wrote:
dc42 wrote:RepRapFirmware uses slow (10Hz) PID for the bed and chamber heaters so as to be compatible with (and kind to) all types of SSR.
That is good to know, thanks! Which raises the next question: does PID really offer improvement when (through the use of a SSR) the current to the bed does not get limited like when you do 12V directly from the board? I thought the main raison for using PID was that it is able to regulate the current to the bed. 50% power through PID flips the SSR and 100% power from the PSU goes to the bed...
Sorry, I meant slow PWM, not slow PID. The PWM frequency just needs to be fast enough so that there is no appreciable heating or cooling during a single PWM cycle. Heated beds have a high thermal capacity, so 10Hz is fast enough.

Using PID for the bed heaters of my printers makes the temperature variation much smaller. Switching to PID solved a Z banding problem for one of our OEM customers.

Re: Duet setup - instructions in progress

Posted: Fri Jan 06, 2017 1:10 pm
by DeltaCon
dc42 wrote:Sorry, I meant slow PWM, not slow PID.
Ah, that explains ;-)
dc42 wrote:The PWM frequency just needs to be fast enough so that there is no appreciable heating or cooling during a single PWM cycle. Heated beds have a high thermal capacity, so 10Hz is fast enough.
In my experience the temp keeps rising for a little while after the power switches off, hence the big variation in measured temp. Dead-time takes this effect into account and it works perfectly. It stops heating before the target temp is reached, knowing it will heat a bit more after it shuts down heating. Hence no over and undershoot, while the switching frequency is much lower that 10Hz. It solved my problem with banding too :D

Still I am not sure that PID switching is favorable for beds. It is not only much more complicated to setup, but I never got it to perform better than dead-time. And I am still uncertain that SSR's are happy with it on the long term.

Re: Duet setup - instructions in progress

Posted: Fri Jan 06, 2017 2:03 pm
by Xenocrates
DeltaCon wrote:
dc42 wrote:Sorry, I meant slow PWM, not slow PID.
Ah, that explains ;-)
dc42 wrote:The PWM frequency just needs to be fast enough so that there is no appreciable heating or cooling during a single PWM cycle. Heated beds have a high thermal capacity, so 10Hz is fast enough.
In my experience the temp keeps rising for a little while after the power switches off, hence the big variation in measured temp. Dead-time takes this effect into account and it works perfectly. It stops heating before the target temp is reached, knowing it will heat a bit more after it shuts down heating. Hence no over and undershoot, while the switching frequency is much lower that 10Hz. It solved my problem with banding too :D

Still I am not sure that PID switching is favorable for beds. It is not only much more complicated to setup, but I never got it to perform better than dead-time. And I am still uncertain that SSR's are happy with it on the long term.
In industrial systems, PID is the usual control method, and SSR's were developed to function in this environment. You are correct that it is more complicated to set up however, which is part of why so many printers have issues with it not having good performance. PID is annoying to tune properly, however a well tuned system should be able to handle almost any disturbance and stay very close to the set point. I wouldn't worry about SSR lifespan much, since most are rated for 50-500 million "operations", which is a pessimistic set of assumptions that most "operations" involve a thermal cycle, which becomes less and less true as switching frequency rises. Ignoring thermal cycle lifespan, they are conservatively rated for an on-time of a mere 228 years, while more optimistic models put them at 830 centuries (I believe that may be overly optimistic, as I think the contacts would have oxidized and the casing decomposed, however the resin potted components might still be functional).

Re: Duet setup - instructions in progress

Posted: Fri Jan 06, 2017 5:56 pm
by dc42
DeltaCon wrote:
dc42 wrote:Sorry, I meant slow PWM, not slow PID.
Ah, that explains ;-)
dc42 wrote:The PWM frequency just needs to be fast enough so that there is no appreciable heating or cooling during a single PWM cycle. Heated beds have a high thermal capacity, so 10Hz is fast enough.
In my experience the temp keeps rising for a little while after the power switches off, hence the big variation in measured temp. Dead-time takes this effect into account and it works perfectly. It stops heating before the target temp is reached, knowing it will heat a bit more after it shuts down heating. Hence no over and undershoot, while the switching frequency is much lower that 10Hz. It solved my problem with banding too :D

Still I am not sure that PID switching is favorable for beds. It is not only much more complicated to setup, but I never got it to perform better than dead-time. And I am still uncertain that SSR's are happy with it on the long term.
The auto tune process in RRF measures the dead time and uses it in conjunction with the other parameters (gain and time constant) to calculate two different sets of PID parameters, one to minimise overshoot when heating up, and the other to react quickly to changes in load.

Re: Duet setup - instructions in progress

Posted: Wed Jan 11, 2017 11:58 am
by aerouta
aerouta wrote:Finally had time to get some work done on calibration when i notice this strange behavior, at least to me. I have posted a link below to a YouTube video. While doing the paper grip test I noticed that it was difficult for me to get consistent results. Then I noticed that the friction/force on the paper was varying significantly without any commands sent to the printer. I seemed to coincide with the bang bang control of the heat bed and sure enough, turned of the heat bed and no more fluctuations. Once the head bed is on, regardless of bed temperature it seems to lower the nozzle slightly.

In the video you will hear the friction on the paper increase at 12 and 25 secs


https://youtu.be/17Dt0IXVa1s
mhackney wrote:Might it simply be current fluctuations due to the bed heater are affecting the steppers?
This problem persisted after changing to "high dollar" PSUs and running a dedicated PSU for the Duet.

What solved it was changing the idle current from 60% to 100%. I believe mhachneys suggestion to turn off heaters during probing would also be good to consider, at least for bed leveling, maybe not bed grid compensation. But for paper grip testing the idle current should be 100%, there is no need to introduce additional variables to that process.

Re: Duet setup - instructions in progress

Posted: Thu Jan 12, 2017 6:21 am
by dc42
aerouta wrote:
aerouta wrote:Finally had time to get some work done on calibration when i notice this strange behavior, at least to me. I have posted a link below to a YouTube video. While doing the paper grip test I noticed that it was difficult for me to get consistent results. Then I noticed that the friction/force on the paper was varying significantly without any commands sent to the printer. I seemed to coincide with the bang bang control of the heat bed and sure enough, turned of the heat bed and no more fluctuations. Once the head bed is on, regardless of bed temperature it seems to lower the nozzle slightly.

In the video you will hear the friction on the paper increase at 12 and 25 secs


https://youtu.be/17Dt0IXVa1s
mhackney wrote:Might it simply be current fluctuations due to the bed heater are affecting the steppers?
This problem persisted after changing to "high dollar" PSUs and running a dedicated PSU for the Duet.

What solved it was changing the idle current from 60% to 100%. I believe mhachneys suggestion to turn off heaters during probing would also be good to consider, at least for bed leveling, maybe not bed grid compensation. But for paper grip testing the idle current should be 100%, there is no need to introduce additional variables to that process.
If the bed heater going on/off in bang-bang mode cause fluctuations in the paper grip, then it will probably cause print quality issues too. Try enabling PID for the bed.

Re: Duet setup - instructions in progress

Posted: Sun Jan 22, 2017 3:09 am
by aerouta
dc42 wrote:
aerouta wrote:
aerouta wrote:Finally had time to get some work done on calibration when i notice this strange behavior, at least to me. I have posted a link below to a YouTube video. While doing the paper grip test I noticed that it was difficult for me to get consistent results. Then I noticed that the friction/force on the paper was varying significantly without any commands sent to the printer. I seemed to coincide with the bang bang control of the heat bed and sure enough, turned of the heat bed and no more fluctuations. Once the head bed is on, regardless of bed temperature it seems to lower the nozzle slightly.

In the video you will hear the friction on the paper increase at 12 and 25 secs


https://youtu.be/17Dt0IXVa1s
mhackney wrote:Might it simply be current fluctuations due to the bed heater are affecting the steppers?
This problem persisted after changing to "high dollar" PSUs and running a dedicated PSU for the Duet.

What solved it was changing the idle current from 60% to 100%. I believe mhachneys suggestion to turn off heaters during probing would also be good to consider, at least for bed leveling, maybe not bed grid compensation. But for paper grip testing the idle current should be 100%, there is no need to introduce additional variables to that process.
If the bed heater going on/off in bang-bang mode cause fluctuations in the paper grip, then it will probably cause print quality issues too. Try enabling PID for the bed.

you are spot on, I am having quality issues even with using PID. The banding is due to the heat bed. Any suggestions?

Re: Duet setup - instructions in progress

Posted: Sun Jan 22, 2017 4:35 am
by dc42
How stable is the bed temperature? Does the bed heater LED show a steady flicker when the bed is up to temperature, or can you see it cycling?

Re: Duet setup - instructions in progress

Posted: Sun Jan 22, 2017 9:09 am
by aerouta
SO i just ran the M307 command and found that is says the following..

M307 H0
Heater 0 model: gain 90.0, time constant 700.0, dead time 10.0, max PWM 1.00, mode: bang-bang

However the my config file says
M301 H0 P20 I0.80 D120 T0.50 S1.0

I am running autotune now. The online wiki says S and P are optional, I was unable to send the M303 command without them.

Re: Duet setup - instructions in progress

Posted: Sun Jan 22, 2017 11:19 pm
by 3D-Print
I found when I used Bang-Bang my bed temperature and fluctuations were huge. Since I optimized my PID settings the bed is money on and stable with the temp I set. Solved many of the above mentioned problems.

Her is a link detailing what I did which was earlier in this Thread (http://forum.seemecnc.com/viewtopic.php ... 200#p87861)

Re: Duet setup - instructions in progress

Posted: Sun Jan 22, 2017 11:23 pm
by 3D-Print
Additionally with an optimized PID my SSR which runs my bed flickers as noted (http://forum.seemecnc.com/viewtopic.php ... 200#p87954). No problems with the SSR to date.

Re: Duet setup - instructions in progress

Posted: Sun Feb 05, 2017 1:44 pm
by aerouta
aerouta wrote:SO i just ran the M307 command and found that is says the following..

M307 H0
Heater 0 model: gain 90.0, time constant 700.0, dead time 10.0, max PWM 1.00, mode: bang-bang

However the my config file says
M301 H0 P20 I0.80 D120 T0.50 S1.0

I am running autotune now. The online wiki says S and P are optional, I was unable to send the M303 command without them.

Using the autotune values resolved this issue!! Thanks for the help.

Re: Duet setup - instructions in progress

Posted: Sun Feb 05, 2017 11:19 pm
by aerouta
Any clue why the edges are being truncated?

Re: Duet setup - instructions in progress

Posted: Mon Feb 06, 2017 3:12 am
by dc42
That will be because the corners are outside the printable radius you declared in the B parameter of the M665 command.

Re: Duet setup - instructions in progress

Posted: Mon Feb 06, 2017 4:55 pm
by aerouta
I looked everywhere for where the print radius could be defined.

Thanks!

Re: Duet setup - instructions in progress

Posted: Sun Feb 12, 2017 8:37 pm
by aerouta
largest footprint I have been able to print.
IMG_0703.JPG
Though the first layer was not perfect. Depending on which direction(clockwise or counter clockwise) these loops where made changed the location of the thin area. Any clue what may cause this. My first though was hysteresis in the head movement. Does the Duet have the ability to have hysteresis settings?
IMG_0702.JPG

Re: Duet setup - instructions in progress

Posted: Mon Feb 13, 2017 10:09 am
by mhackney
Yes, you have some slop in your motion mechanics somewhere. It could be simple like loose belts or a loose stepper pulley or it could be sloppy arm joints. But something is not tight. Duet's RepRapFirmware (dc42) does not have backlash compensation. Sometimes reducing your acceleration values can help with this. In config.g:

M201 X1000 Y1000 Z1000 E1000 ; Accelerations (mm/s^2)

changes X, Y and Z to 200 and see if you get any improvements.