Duet3D Logo Duet3D
    • Tags
    • Documentation
    • Order
    • Register
    • Login
    1. Home
    2. Paski
    3. Posts
    • Profile
    • Following 0
    • Followers 0
    • Topics 4
    • Posts 11
    • Best 0
    • Controversial 0
    • Groups 0

    Posts made by Paski

    • RE: moving average, issue with types

      @dc42 Will try. Thanks David

      posted in Gcode meta commands
      Paskiundefined
      Paski
    • RE: DWC - GUI Color Change?

      @jay_s_uk That's super awesome.
      Thanks!

      posted in Duet Web Control
      Paskiundefined
      Paski
    • RE: DWC - GUI Color Change?

      Hi @T3P3Tony,

      Would you mind sharing a quick and simple guide on how to change the color of the header in Duet Web Control? I'm not very experienced with web development, but I’d love to customize it a bit.

      From what I’ve gathered, the styles seem to be in the app.*.css file in the DWC files. Can I just modify that directly to change the header color?

      Or is there a better way to do it? I imagine that file is auto-generated, so maybe any updates would overwrite my changes? I guess that the
      src/App.vue on the DuetWebControl repo could be the one?

      Thanks in advance for your help!

      posted in Duet Web Control
      Paskiundefined
      Paski
    • RE: moving average, issue with types

      @dc42 RRF 3,5.4

      posted in Gcode meta commands
      Paskiundefined
      Paski
    • moving average, issue with types

      Hi,
      I'm planning on adding a moving average function to average an analog input and trigger some actions if that decreases too much.
      for that, i'm declaring an array of the tension in the config.g

      global TensionAverage = {0,0,0,0,0,0} ;list of 6 tension to average the tension in a moving average
      

      And in a macro called by deamon.g is the following. with parameter P being the analog senor reading

      ;Tension WatchDog
      
      ;tension average: list of 1 elements, move element i to i+1. scrap element 5. add current to element 0
      var i = 5
      var average = 0
      while var.i>0
          set global.TensionAverage[var.i] = global.TensionAverage[var.i-1]
          set var.average = var.average + global.TensionAverage[var.i]
          set var.i = var.i -1
      set global.TensionAverage[0]=param.P
      set var.average = var.average + global.TensionAverage[0]
      
      set var.average = var.average /6
      echo "average: "^{var.average}
      
      if var.average < global.TensTreshold*0.5
          m98 P"/sys/tension-error.g"
      

      But in line 7, i got this error:
      "error: in file macro line 7 column 70: meta command: Cannot index into variable or parameter 'TensionAverage^' of non-array type"

      so, my question is, is there a more efficient way to get the moving average with Gcode/metacomands?
      how can i cast it to an array?
      Thanks!

      posted in Gcode meta commands
      Paskiundefined
      Paski
    • Read values from .txt

      Hi
      I’m working on a project where I need to store some calibration parameters in a file within a /calib/ directory on the SD card. I was wondering if there’s a way to access the data from that file and load it into an array variable for further use. Any guidance or suggestions would be greatly appreciated. Thanks in advance!

      posted in Gcode meta commands
      Paskiundefined
      Paski
    • [3.6.0beta.2] Errors in Close loop tuning

      Hi,

      I’m experiencing issues with axis tuning. The mechanical setup is as follows:

      A motor with an integrated brake and quadrature encoder.
      A coupling connects the motor to a leadscrew.
      A magnetic encoder is mounted on the opposite end of the motor due to limited access to the axis.
      The calibration fails, likely due to backlash or counts/step mismatch. Here are the errors I’m seeing:

      Power up + 00:00:29 [warn] Error: Driver 122.0 calibration failed, measured backlash (0.639 step) is too high.
      Power up + 00:00:29 [warn] Warning: Driver 122.0 failed to maintain position, tuning/calibration failed.
      Power up + 00:00:25 [warn] Error: Driver 122.0 calibration failed, the measured motion was less than expected, measured counts/step is about 66.8.

      Is there a way to use only the quadrature encoder for calibration to bypass the backlash issue?
      How can I resolve those problems?

      BR.

      posted in Beta Firmware
      Paskiundefined
      Paski
    • RE: [3.6.0beta.2] Unable to Access Object for positionError

      Hi @dc42,

      I was running in standalone mode.
      Thanks for the "M409 K"boards[1].drivers[0].closedLoop" command; it revealed an incompatibility with the DWC, which was resolved after an update.

      BR.

      posted in Beta Firmware
      Paskiundefined
      Paski
    • RE: [3.6.0beta.2] Unable to Access Object for positionError

      @dc42
      It's curious that when accessing the average error (boards[1].drivers[0].closedLoop.currentFraction.avg), the output is a value. However, for positionError, it seems to return an object.

      Interestingly, both are specified as value in the object model of the DWC.

      Am I correct in assuming that the real-time PID error is part of the positionError? How can i acess that?

      Thanks!

      posted in Beta Firmware
      Paskiundefined
      Paski
    • RE: [3.6.0beta.2] Unable to Access Object for positionError

      Thanks in advance!

      posted in Beta Firmware
      Paskiundefined
      Paski
    • [3.6.0beta.2] Unable to Access Object for positionError

      I'm attempting to calibrate an axis using the encoder position error(with 1HCL board). To achieve this, I need to access the boards[].drivers[].closedLoop.positionError parameter.

      Initially, I found it located at:
      boards[1].drivers[0].closedLoop.currentFraction.positionError

      However, when I try to retrieve its value using boards[1].drivers[0].closedLoop.currentFraction.positionError.value with echo, it doesn't return anything.

      Could someone guide me on how to properly access and read the encoder error value?

      posted in Beta Firmware
      Paskiundefined
      Paski