Metric Units in schematic components

Hello dear peoples!

I don’t use standard libraries, I can create my own libraries with components that needed.
BUT! I can’t use metric units in schematic diagrams!

Open “LibrePCB Control Panel”, then “Library Manager”. Workspace library manager open, it’s OK still yet. Then I choose a “Create New Library”, or open existing library that I create ago. Open “Library Editor” with 6 rectangle areas. Symbol - New (or Edit existing). Symbol image editor opened. I draw lines, place pins… In METRIC units, change grid 2.54mm to 2.50mm. All lines and pins positionized to METRIC coordinates, for ex. (X:Y 0.000 : 5.000). But! After editing warning message appears: " WARNING: This library element contains errors, see exact messages below. You shound fix these errors before saving it, otherwise the library element may not work properly. " In Message rectangle shows “Pin not on 2.54mm grid”

But I don’t want to use a mils/inches grids! This is obsolete! I want use a METRIC grid in all units, schematic, symbol images, etc.

1 Like

Hi @Lantcoder,

Did you already try to just ignore this message? Basically the library element check (which shows this warning) is just a help to follow best practices and our library conventions. You can still ignore (some of) these warnings, save the symbol and use it in your schematics.

I think if you also use a metric grid in your schematics, everything should work fine as long as all pins are located on the same grid interval. But I didn’t test it, so please correct me if I’m wrong :slight_smile:

O yeah, I can ignore this warning. But really is this an exit, is there a solve of problem? Of course NO.
Ability to use metric units without stupid warnings… there must be a major feature, choosing measurements system (metric/imperial), please, make this!

Library conventions… Why are you use a “stone age” grid of 2.54 mm? All world came to metric units, even computer dimensions have migrate from Inches to Millimeters tens years ago (5’ floppy disc was in Inches, but 3’ floppys was in millimeters). Use this past-century grid in THEIR libraries, give us ability to use other grids! For example, P-CAD and Altium CADs give ability to use own grids for 20 years (I don’t remember exactly). But in a good way would be to convert your libraries to modern metric measurement units, there are two libraries sets, old and new, with gradually finishing of support old libraries.

I propose slightly correct a grid dialog window. Measurement units: Millimeters, micrometers, nanometers (OMG), inches, mils. Why you add nanometers? For nanocircuits? These units nobody to use.

Instead of “Interval” dialog make a dual choose of type units (Imperial / Metric), where Imperial is a Inch, Metric is a Meter. Next choose is a MULTIPLIER list, where are a list with multipliers: 1000,100, 10, 1, 0.1, 0.01, 0.001, 0.0001, 0.00001, 0.000001. Defaut values is a 0.001 in Metric and 0.1 in Imperial units. Next text input field where we can manually set a grid, default values is a 2.50000 in metric and 1.0000 in imperial

In file formats (*.lp) add parameter with measuring system (metric/imperial) and multiplier

Library conventions… Why are you use a “stone age” grid of 2.54 mm?

I’m a big fan of using SI units as much as possible. And @ubruhin is too. For example for the SMD resistor components in the base library, we use names like “3216 (1206)”, not “1206 (3216)”.

However, real-world packages/footprints usually use inch-based pin spacing. This means that the only sensible grid default for the board editor is inches (2.54 mm in this case).

And having different grid defaults for the board editor and the schematic editor would be inconsistent, therefore we also use a 2.54 mm grid by default in the schematic editor.

You are of course free to use any grid you want. But as of right now, the warning is still relevant because of missing snapping functionality in the schematic editor. IIRC if you mix different grid intervals, pins outside of the grid lines currently cannot be connected to. Definitely a bug that needs to be fixed, but adding a warning was a quicker (temporary!) solution than implementing grid snapping. Pull requests with fixes are welcome!