Duet3D Logo Duet3D
    • Tags
    • Documentation
    • Order
    • Register
    • Login

    M106 Maximum Fan Speed Setting - unproportional

    Scheduled Pinned Locked Moved
    Firmware wishlist
    6
    34
    3.4k
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • c310undefined
      c310
      last edited by

      I was installing berd-air and found that driving at more than 50% not only does not help, but harms the print and produces lots of noise.

      on our has WiKi M106 L and X parameters (min and max fan speed).
      my config has this line

      M106 P1 L10 X150 F22500 S0 H-1 B0.1
      

      M106 P1 reports
      Fan 1 pin: F1, frequency: 22500Hz, speed: 0%, min: 7%, max: 58%, blip: 0.10, inverted: no

      Questions:
      (1) why X parameter is not proportional? i.e. with my config line once i run M106 P1 S85 (that should me 50% median for my limits.However P1 reports 33% of max, that is in fact 33% of 255, not 150. I suggest to re-map 100% to limited maximum with scale length of max - min
      doing so will ease working with slicers without re-calculating what % of cooling to put in.

      (2) why fan switches on for 1-2 seconds during reboot cycle?
      (3) fan "remembers" its speed before reboot and continues to run. in other words, if fan was running it continues to run unless i put S0 in confing. is it by design?

      thanks!

      0_1548872752866_07a5f926-fa04-412d-a773-a170b94df201-изображение.png

      P.S. similar treads are closed for commenting .

      dc42undefined 1 Reply Last reply Reply Quote 0
      • dc42undefined
        dc42 administrators @c310
        last edited by dc42

        @c310 said in M106 Maximum Fan Speed Setting - unproportional:

        (1) why X parameter is not proportional? i.e. with my config line once i run M106 P1 S85 (that should me 50% median for my limits.However P1 reports 33% of max, that is in fact 33% of 255, not 150. I suggest to re-map 100% to limited maximum with scale length of max - min

        The S parameter is always on a scale of 0-1 (if <= 1) or 0-255 (if > 1). We could change it, but that would make it behave differently from other firmwares.

        (2) why fan switches on for 1-2 seconds during reboot cycle?

        Because we intend Fan 1 output to be used for the hot end heatsink fan, so it defaults to on for safety (e.g. if you upgrade the firmware while the hot end is hot, you don't want to end up with a filament jam).

        (3) fan "remembers" its speed before reboot and continues to run. in other words, if fan was running it continues to run unless i put S0 in confing. is it by design?

        Are you sure that fans do not remember their speed across a reboot? If so, that isn't intentional.

        Duet WiFi hardware designer and firmware engineer
        Please do not ask me for Duet support via PM or email, use the forum
        http://www.escher3d.com, https://miscsolutions.wordpress.com

        1 Reply Last reply Reply Quote 0
        • c310undefined
          c310
          last edited by

          @dc42 said in M106 Maximum Fan Speed Setting - unproportional:

          The S parameter is always on a scale of 0-1 (if <= 1) or 0-255 (if > 1). We could change it, but that would make it behave differently from other firmwares.

          i understand the difference. however is seems logical for me to "fit" 0...100% scale in between hardware limits that are set by L and X parameters declared in config. In other words, in config we set limits, and when slicer sets fan (for example) at 50% that 50% should be median between L and X.
          in current configuration if i set Lo and High values slicer generated M106 are irrelevant to real scale .

          So, L and X are setting hardware limitations, S should be controlling speed in between those limits.

          deckingmanundefined 1 Reply Last reply Reply Quote 0
          • deckingmanundefined
            deckingman @c310
            last edited by

            @c310 said in M106 Maximum Fan Speed Setting - unproportional:

            So, L and X are setting hardware limitations, S should be controlling speed in between those limits.

            That's a debatable point.

            Slicers tend to use values such as M106 S0.5 meaning run fan at half speed. If the firmware were changed as you suggest, then that "0.5" takes on a completely different meaning. In fact it become meaningless because the upper and lower limits could be set to anything. So 50% fan speed could be actually be 10% of the fan's speed. But if the limits were changed again, then that 50% could be 80% of the fan's actual speed.

            If the firmware was modified as you suggest, I could foresee many users wanting it to be changed back to how it was (me for one).

            Ian
            https://somei3deas.wordpress.com/
            https://www.youtube.com/@deckingman

            1 Reply Last reply Reply Quote 0
            • dragonnundefined
              dragonn
              last edited by dragonn

              Why not?
              This could work nice with filaments profile, so you are able to set cooling from filament profile in Duet by just scaling it.
              I even though this is how it works, unfortunately not :/.
              For examples to be more explanatory:

              1. for ABS I would set M106 L0.0 X0.2
              2. for PLA I would set M106 L0.8 X1.0
              3. for PET-G I would set M106 L0.1 X1.0

              Maybe add an option to M106 to enable scaling.

              wilrikerundefined 1 Reply Last reply Reply Quote 0
              • wilrikerundefined
                wilriker @dragonn
                last edited by

                @dragonn said in M106 Maximum Fan Speed Setting - unproportional:

                Maybe add an option to M106 to enable scaling.

                I think there is no right or wrong way here. Both variants have their place. I think an option to enable scaling would be a good idea.

                Changes are minor to achieve this. @dc42: What do you think about an option? I can implement that quite easily. Hardest part as always: which parameter to use. 😂

                Manuel
                Duet 3 6HC (v0.6) with RPi 4B on a custom Cartesian
                with probably always latest firmware/DWC (incl. betas or self-compiled)
                My Tool Collection

                deckingmanundefined 1 Reply Last reply Reply Quote 1
                • deckingmanundefined
                  deckingman @wilriker
                  last edited by

                  @wilriker Yup. Optional would be good. More chance of pleasing "all of the people, all of the time" rather than "some of the people all of time" or "all of the people some of the time". ☺

                  Ian
                  https://somei3deas.wordpress.com/
                  https://www.youtube.com/@deckingman

                  1 Reply Last reply Reply Quote 0
                  • wilrikerundefined
                    wilriker
                    last edited by wilriker

                    Have this implemented and ready to create a PR if @dc42 is OK with the basic idea.

                    Only one open question: what should the fan status report as the set speed? Physical or logical speed? I have it implemented as physical speed but swapping it to logical is just deleting one line of code.

                    BTW: I used Wnnn as the parameter for now. Like "Whatever you want the fan to behave". 😂

                    Manuel
                    Duet 3 6HC (v0.6) with RPi 4B on a custom Cartesian
                    with probably always latest firmware/DWC (incl. betas or self-compiled)
                    My Tool Collection

                    dragonnundefined deckingmanundefined 2 Replies Last reply Reply Quote 1
                    • dragonnundefined
                      dragonn @wilriker
                      last edited by

                      @wilriker logical, it need to report the same as you set. Otherwise it will confuse paneldue and DWC

                      wilrikerundefined 1 Reply Last reply Reply Quote 0
                      • wilrikerundefined
                        wilriker @dragonn
                        last edited by

                        @dragonn You are right - also because this could have potentially led to side effects where the fan suddenly runs slower than commanded. So changed this back to logical/commanded speed.

                        Manuel
                        Duet 3 6HC (v0.6) with RPi 4B on a custom Cartesian
                        with probably always latest firmware/DWC (incl. betas or self-compiled)
                        My Tool Collection

                        1 Reply Last reply Reply Quote 0
                        • deckingmanundefined
                          deckingman @wilriker
                          last edited by

                          @wilriker said in M106 Maximum Fan Speed Setting - unproportional:

                          Only one open question: what should the fan status report as the set speed? Physical or logical speed?

                          Optional☺

                          Ian
                          https://somei3deas.wordpress.com/
                          https://www.youtube.com/@deckingman

                          wilrikerundefined 1 Reply Last reply Reply Quote 0
                          • wilrikerundefined
                            wilriker @deckingman
                            last edited by

                            @deckingman said in M106 Maximum Fan Speed Setting - unproportional:

                            Optional☺

                            Seriously? 😁

                            No, but really seriously: that would make things probably a little awkward and confusing. Example: you have the fan set to M106 P2 L0 X0.5 W1 (i.e. min 0%, max 50%, scaling on) and then pull the speed slider in DWC all the way to 100% - once RRF would have executed that command the slider would jump back to 50%.

                            I could add it as a separate information to M106 status output though. 🤔

                            Manuel
                            Duet 3 6HC (v0.6) with RPi 4B on a custom Cartesian
                            with probably always latest firmware/DWC (incl. betas or self-compiled)
                            My Tool Collection

                            deckingmanundefined 1 Reply Last reply Reply Quote 0
                            • deckingmanundefined
                              deckingman
                              last edited by

                              Now what would be cool would be to have fan speed act in proportion to filament volume flow flow rate - I'd settle for extruder speed.☺

                              If you've' ever played around with large nozzles or multiple melt chambers and high speeds, then you'd know that you need much more cooling than for low volume flow rates.

                              Ian
                              https://somei3deas.wordpress.com/
                              https://www.youtube.com/@deckingman

                              wilrikerundefined Phaedruxundefined 2 Replies Last reply Reply Quote 0
                              • deckingmanundefined
                                deckingman @wilriker
                                last edited by

                                @wilriker said in M106 Maximum Fan Speed Setting - unproportional:

                                @deckingman said in M106 Maximum Fan Speed Setting - unproportional:

                                Optional☺

                                Seriously? 😁

                                No, but really seriously: that would make things probably a little awkward and confusing. Example: you have the fan set to M106 P2 L0 X0.5 W1 (i.e. min 0%, max 50%, scaling on) and then pull the speed slider in DWC all the way to 100% - once RRF would have executed that command the slider would jump back to 50%.

                                I could add it as a separate information to M106 status output though. 🤔

                                That's the problem with effectively having two speed ranges. 0 to 100% of what the fan is capable of and 0 to 100% of some range within that range. Which one do you report?

                                Ian
                                https://somei3deas.wordpress.com/
                                https://www.youtube.com/@deckingman

                                1 Reply Last reply Reply Quote 0
                                • wilrikerundefined
                                  wilriker @deckingman
                                  last edited by wilriker

                                  @deckingman said in M106 Maximum Fan Speed Setting - unproportional:

                                  Now what would be cool would be to have fan speed act in proportion to filament volume flow flow rate - I'd settle for extruder speed.☺

                                  Implementation complexity would be the same for both ways since the firmware always knows the flow rate because that will be converted into extruder movement. 😉 But that is the easy part here. 😂

                                  Ref which value to report: I think it is mandatory to internally work with the commanded (logical) value. Otherwise you would have controls that jump around and cannot reach certain values - which is what we already have right now with min and max values... 🤔 The longer I think about it the less of an opinion I have. 🤦

                                  EDIT: I got totally confused so I had to revert back to check: right now it will report whatever the user has commanded. If you tell the fan to run at 100% but set max to 50% it will still report 100% although the fan is turning at 50% speed.

                                  Manuel
                                  Duet 3 6HC (v0.6) with RPi 4B on a custom Cartesian
                                  with probably always latest firmware/DWC (incl. betas or self-compiled)
                                  My Tool Collection

                                  dragonnundefined 1 Reply Last reply Reply Quote 1
                                  • dragonnundefined
                                    dragonn @wilriker
                                    last edited by

                                    @wilriker yeah, this is how it schould work.

                                    1 Reply Last reply Reply Quote 0
                                    • c310undefined
                                      c310
                                      last edited by

                                      @wilriker said in M106 Maximum Fan Speed Setting - unproportional:

                                      RRF would have executed that command the slider would jump back to 50%.

                                      @wilriker i see it this way:

                                      like @dragonn suggested
                                      M106 Laaa Xbbb in config.g or in filaments sets hardware limits.

                                      once limits are set - DWC should treat them as end parts of 0...100% scale.
                                      so, if in DWC I drag fan to 100% physically it it would be set to bbb value from related config.

                                      this "logical scaling" behaviour can be initiated by W1 option, with W0 (no scaling) being default.

                                      Reporting for DWC can show both values (physical and logical)

                                      wilrikerundefined 1 Reply Last reply Reply Quote 0
                                      • wilrikerundefined
                                        wilriker @c310
                                        last edited by wilriker

                                        @c310 I came to that conclusion also now. Since RRF is reporting the commanded value to the outside ever since I won't change that behavior. But I will add the value for physical speed to M106 Pnnn output.

                                        Since there is no good way (I can think of) to permanently show both values in DWC as well as it would tremendously increase complexity of this change I will not even attempt to show both values any other way than described in the paragraph above.

                                        Manuel
                                        Duet 3 6HC (v0.6) with RPi 4B on a custom Cartesian
                                        with probably always latest firmware/DWC (incl. betas or self-compiled)
                                        My Tool Collection

                                        1 Reply Last reply Reply Quote 0
                                        • wilrikerundefined
                                          wilriker
                                          last edited by

                                          I just submitted this pull request. Now it is up to @dc42 to accept or reject it. 🙂

                                          Manuel
                                          Duet 3 6HC (v0.6) with RPi 4B on a custom Cartesian
                                          with probably always latest firmware/DWC (incl. betas or self-compiled)
                                          My Tool Collection

                                          1 Reply Last reply Reply Quote 0
                                          • c310undefined
                                            c310
                                            last edited by

                                            @dc42 said in M106 Maximum Fan Speed Setting - unproportional:

                                            it behave differently from other firmwares.

                                            @dc42 we have the best firmware 🙂 lets add some ⚡ power options to it ☺

                                            1 Reply Last reply Reply Quote 0
                                            • First post
                                              Last post
                                            Unless otherwise noted, all forum content is licensed under CC-BY-SA