Grids, Origins, Offsets, and Pitch

Editing the “User Grid” dimensions in that dialog box does not select the user grid, it only sets it’s dimensions. You then need to select “User Grid” as @Rene_Poschl illustrated above.

1 Like

Ah-HA!
OK, I get it now. I didn’t properly understand the instructions, and up until now I had not noticed that User Grid was in fact one of many choices from within the {right mouse-click menu} Grid Select menu. I think this screen shot (with captions) illustrates this succinctly:

The user defined origin works for any grid. Including “KiCad’s predefined, square grids”

Thanks for that clarification.
The dialog box for the User Defined Grid includes a dialog for setting the Origin. So, it seemed that this origin would be linked only to the User Defined Grid, and that all others would be keyed to some ‘universal’ origin.
I can now see that, not only is the Origin not linked to the User Defined grid but that the Origin can be set on-the-fly by choosing Place…Grid Origin from the drop-down toolbar. So the Origin dialog within the User Defined Grid menu is merely a shortcut.
I should note that I’ve also discovered that there can only be one Origin: If you are using one of the non-User-Defined grid systems and alter the Origin, it changes the setting previously made within the User Defined grid dialog. From that perspective, it’s a bit confusing to have that origin-setting shortcut within the User Defined Grid dialog box.

I observe that moving the Origin doesn’t appear to affect the X, Y and dx, dy readouts at the bottom of the windowPcbNew%20grid%20dialog_5. I was expecting that shifting the origin would have precisely that effect.
So, that begs the question: How does shifting the Origin affect the process of laying out the board? Or, posed another way, When and why would I want to shift the Origin? Does it affect the Gerber-file outputs??

Yes the readout is relative to the file format origin (the X and Y values)

The dx and dy readouts are relative to yet another origin. That one is set using the spacebar. (It does not leave a visible mark)

1 Like

I think it’s a misnomer to call that an “origin”, it’s simply a reference point for the measuring tool.

2 Likes

I see that the file-format Origin is permanently in the upper-left corner.

Your mention of using the spacebar to set an (invisible) origin would seem to answer another question I had in mind, being: How do you perform measurements from point-to-point in KiCad (in Solidworks, for example, there is the Evaluate >> Measure function).

So what useful function does setting of the (visible as a bullseye) Origin have?

Don’t worry, you’re not the only one who has been confused about the “grid origin”. It’s actually not an origin at all in the sense of some coordinate system origin. It’s just the point in KiCad coordinate system which is always exactly in a grid point. It kind of sets the grid offset. “Grid offset reference point” could be the most descriptive short phrase for it. But it can be thought of as an “origin” because when you change the grid, you could use the grid origin as the one point from which you could start drawing grid points (or lines).

Ahhhhhhhhh.
Thanks, that’s a much more sensible explanation. And, it’s helpful to know that I am not in the same league as Homer Simpson.
Now, this leads to another question:
If, for example, I’ve dropped in a component Footprint that has a circular feature, and I want to use the center of that circular feature as the “origin” of my grid, are there selection filters that allow for choosing the center of a circle? Or, the midpoint of a line? (etc)

If you mean the one in KiCad v4 Place->Drill and Place Offset, not much. There was a developer discussion about different origins and at least some thought the this “auxiliary origin”, used for some output files, isn’t needed.

@von_Whimhurst Glad to kown you have understood from other users how the grid works.

In some cases it is possible. I use frequently this feature. If the circle is a pad (through-hole or smd) I set the grid origin (the “Grid offset reference point” as @eelik points out) on that pad to make measurements or create zones and place other footprints at a given distance from that pad.

To snap the cursor on the center of the pad I set the magnetic pads under general settings to always. Then I change the grid to a more comfortable user grid for my purposes.

It also works on a rectangular pad or a via.

Eelik:

No, sorry…I didn’t mean the origin associated with the Drill-and-Place Offset. I was referring to the Origin that is set via the drop-down menu, Place >> Grid Origin

  • The former appears (in default colours, at least…) as a red circle with vertical crosshairs
  • The latter appears (default colours) as white with inclined crosshairs that extend outside the circle:
    image

Pedro:

Ah-ha.
Thanks for pointing out the function of the “Magnetic” settings (that is, it operates as a snap-to Filter)

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.