Maslow4 Technical Wiki

I would like to consolidate a technical description of how Maslow4 works in one place and I think that the best option is to create a wiki. Feel free to add topics that you are interested in and I will attempt to fill them out with technical details when I have time. I’m just getting it started so I don’t forget things that I want to cover.

Note that this post is a wiki and anyone can edit it.


Software structure overview:



Belt length calculations:

The belt length calculations are performed in the Maslow.cpp file by functions like:

float Maslow_::computeTL(float x, float y, float z){
    //Move from lower left corner coordinates to centered coordinates
    x = x + centerX;
    y = y + centerY;
    float a = tlX - x;
    float b = tlY - y;
    float c = 0.0 - (z + tlZ);
    return sqrt(a*a+b*b+c*c) - (_beltEndExtension+_armLength);

Basically what this is computing is the 3D version of pythagorean theorem where the 3rd axis is the height of the Z axis. The height of the Z axis is computed by the current position z plus the tlZ offset which is how high above the base of the sled the top left arm is when the z-axis is at height zero.

Belt physical properties:

PU-Steel reinforced
0-70c Rated temperature
Max Load: 985N (221lbs)
Tensile Strength: 52Mpa
Elongation percentage at breaking: 36.5%

Calibration process:

Feeback control system:

PID tuning:

The machine’s PID tuning is set at the top of the file MotorUnit.cpp with the lines

// PID controller tuning
#define P 300
#define I 0
#define D 0

This is obviously not well tuned. It works remarkably well given that it hasn’t been tuned at all yet, but there is some overshooting in right angles and we have the acceleration profile tuned way down to compensate for that. Tuning the PID controller should be a high priority.



Main control board:




Don’t forget that we started a Maslow 4 Manual last August at The Belt Maslow (a.k.a Maslow 4) Manual. Of course if you wanted something separate, (a general Maslow 4 wiki and a technical Maslow 4 wiki) that’s fine too.

1 Like

That’s a great point. I’m thinking of this one as more of a deep dive into the technical details that 90% of folks don’t want to know about (which line of code in the firmware does what kind of thing)

Fair enough. I would suggest a bit of cross-linking to lead the brave from the grassy meadow (general wiki) into the dense forest (technical wiki).

1 Like

I’m lost, where’s the chainsaw?

1 Like

You don’t unlock the chainsaw until you finish “Obstacle Clearance” in Tier 2. :slight_smile:


Found the chainsaw


Now that’s a chainsaw!

What is the sign for Z? Does a positive move in Z move the router towards the workpiece? That is what it seems to me because of the way c is calculated.

Z moves away from the work piece…did I get it wrong :grimacing:

Assuming that we are not talking ‘relative’ movements, then:

  • Z0 is at the surface of the material
  • Z-ve is ‘below’ the surface of the material - so what you would normally expect to see when cutting
  • Z+ve is ‘above’ the material’s surface - so normally moving from one cutting path to another
1 Like

So, let’s see if I understand this correctly -

Z= 0 is somewhere in the middle of the Z range of travel, not at either endpoint.

Z=0 is nominally the position at which the router bit touches the surface of the workpiece.

Z<0 → the end of the bit is below the surface and you are cutting.
Z>0 → the bit is above the surface and you are traversing.

If all the above is true then for the equation that corrects for z travel to be correct, then the mounting of the end of each belt must be such that the belt is parallel to the top of the worksurface at Z=0. Since the workpiece will have different thicknesses from time to time there will be an error induced but it shouldn’t be more than a few thou if you set the anchors for a workpiece thickness in the middle of the range of likely thicknesses. I suspect most of the time I will be using no more than 3/4" plywood so setting the belts parallel when the workpiece thickness is 3/8" might be a good compromise.

Does this seem right?

Yes, exactly. Right now it’s arbitrarily defined as 28mm up off the lower limit. The user is of course free to define “zero” at the surface of the wood (or anywhere else), but for the internal math the zero point is arbitrarily defined as 28mm right now.

I think that to really understand this we need to talk about the two different coordinate systems. The machine coordinates are defined relative to the machine itself. x,y = (0,0) is always the center of the sheet of plywood. This is the coordinate system used for the internal math. There is a second coordinate system called WCO or “work coordinate offset” which is what the user sees. That coordinate system can be moved anywhere on the sheet so say you wanted to cut something on the lower left part of the sheet you could declare it to be (0,0) there. Similarly you can define “zero” in the WCO system to be the top surface of the wood, but internally the machine still remembers where it is in real world coordinates too and those are used for the math.

The machine coordinates are defined relative to the machine itself. x,y = (0,0) is always the center of the sheet of plywood.

mild correction, machine 0,0 is the center of the anchors, not necessarily the center of the workpiece

1 Like

Great point, that is absolutely true.

1 Like