Metric vs Imperial Layout - Page 1
Forum section: electronics / general

author: yanir
author_rank: Regular Contributor
timestamp: March 12, 2016, 02:22:17 am
content: I've been designing PCB's professionally for a number of years, and have been predominantly using imperial. My main grid is imperial; traces; vias; etc. I use metric grids for BGAs (localized to the the area under and around the bga) and other specific circumstances. All of the fab houses I deal with spec their capabilities in mils. I do occasionally encounter designers that work in metric, but I can count them on one hand.I'm curious what other people do. I'm based in the US but from what I hear imperial is still in use for pcb design internationally as well, though I'm assume metric is more prevalent.What do you do?Should I switch to metric? Modern IC's are metric, but the fab houses I work with aren't. I can see using a metric grid, but sticking to imperial trace/space.Has anyone encountered fab issues due to conversion error (from metric to imperial or vice versa)?Thoughts?

author: uncle_bob
author_rank: Unknown
timestamp: March 12, 2016, 02:30:52 am
content: Quote from: yanir on March 12, 2016, 02:22:17 amHiIt can be dependent on the package you layout with. Some are "native imperial" and do silly conversions to get to metric. Ultimately the result is unexpected roundoff errors. They may or may not make a difference on the board, but they look ugly.When you go to fab, the "destination" knows the precision of their gear. Converting one to the other at a level where "it makes no difference" is easily done in that case.Bob

author: uncle_bob
author_rank: Unknown
timestamp: March 12, 2016, 02:44:14 am
content: Quote from: blueskull on March 12, 2016, 02:40:45 amHi.. and when you have a connector with a hundred pins in a row, the last one still does not line up between metric and imperial....Bob

author: yanir
author_rank: Regular Contributor
timestamp: March 12, 2016, 02:47:17 am
content: It looks like Altium (which I use) is imperial based, and does produce rounding errors. Nice.

author: yanir
author_rank: Regular Contributor
timestamp: March 12, 2016, 02:51:59 am
content: Quote from: blueskull on March 12, 2016, 02:48:29 amI found this:https://techdocs.altium.com/display/ADOH/Tutorial+-+Integrating+MCAD+Objects+and+PCB+DesignsSearch for rounding in the page, and it will give you an example. It's for stepfiles, but still an issue.Quote from: blueskull on March 12, 2016, 02:48:29 amThats interesting, I'll check those settings.

author: exmadscientist
author_rank: Frequent Contributor
timestamp: March 12, 2016, 03:22:14 am
content: Quote from: blueskull on March 12, 2016, 02:48:29 amAltium has plenty of rounding errors. They usually only show up in the fourth decimal place (in mm), and so they're all-but-inconsequential, but they most certainlyarethere.I don't think it matters what units a given library or .PcbDoc is currently using. The file formats seem to save everything (or almost everything) internally as imperial, and convert on display. This is of course insane. If they had stored metric units instead, with very high precision (say, using 64-bit integers to represent distances in nanometers), they could store imperial dimensions with no roundoff -- but the reverse is not true. (×2.54 is a straightforward, exact conversion factor; ÷2.54 = ×1/2.54 = ×0.3937..., is not.)I notice this fairly often as I, too, do all my layout in metric these days, and sometimes a save-and-reopen causes things to shift around a tiny amount. It's bothersome but not exactly a roadblock.

author: uncle_bob
author_rank: Unknown
timestamp: March 12, 2016, 03:25:34 am
content: Quote from: exmadscientist on March 12, 2016, 03:22:14 amHiMentor is pretty much the same way. You get these fiddly little offsets that are indeed below what likely ever matters. For those that do look deep at this or that ... they are indeed there.Bob

author: Feynman
author_rank: Regular Contributor
timestamp: March 12, 2016, 05:57:29 pm
content: Metric all the way.

author: Fred27
author_rank: Unknown
timestamp: March 12, 2016, 06:12:49 pm
content: I've always stuck with imperial, but mainly because of the standard 0.1" pitch thorough hole stuff - headers, etc. It hasn't really dawned on me that for all the surface mount stuff I do now it doesn't really matter. I might try a metric grid for the next one and see how that goes.Sent from my Nexus 6 using Tapatalk

author: nctnico
author_rank: Super Contributor
timestamp: March 12, 2016, 06:43:57 pm
content: Quote from: uncle_bob on March 12, 2016, 02:44:14 amThat is not possible. 1 inch is defined as 25.4mm so an inch is metric as well. Back in the old days I used to work with inches and mils because all the components where specified that way. Nowadays I use metric exclusively because all the components are metric.

author: kendalll
author_rank: Contributor
timestamp: March 12, 2016, 07:10:19 pm
content: I still know most of the rules of thumb in imperial, but with all the metric parts, I hit "Q" in Altium to flip back and forth constantly while doing layout. Would be easier if I was all metric.

author: Karel
author_rank: Super Contributor
timestamp: March 12, 2016, 07:31:14 pm
content: I use metric as default but switch temporary to imperial when creating footprints for devices/connectors that use imperial basedpitch between pins. EAGLE performs its internal calculations using a basic grid size of 0.00325 um so, no conversion problems here.

author: T3sl4co1l
author_rank: Super Contributor
timestamp: March 12, 2016, 08:03:47 pm
content: For everything except pin pitch, it is sufficient to take inches, halve it twice (i.e., x 0.25), and shift the decimal twice (i.e., x 100) to get mm. (Or if it's mils, shift decimal once in the other direction.) And vice versa for mm to inches (x 4, / 100). Very easily done in the head.The main difference is what grids feel right. 0.1mm is too fine (~4 mil) for general use. 10 mil is about right, except for fine traces and small scales, where something smaller (like 5 mil or 0.1mm) does better, especially around corners (and anyway, there's no good grid size where diagonals will line up with equal spacing*).*This is actually a mathematical fact, because a 45 degree diagonal needs to be offset by sqrt(2)/2 on each axis, and there is no rational ratio (of grid steps) that can equal an irrational number. Moreover, approximations converge slowly, as seen by the series produced by repeatedly taking the reciprocal and subtracting the integer part (i.e., 0.707.., 1/x --> 1.414.., -1 = 0.414.., 1/x = 2.414.., -2 = 0.414.., 1/x = .....). The small integer values in this series (a continued fraction) mean nothing is converging very quickly.Trace widths feel nicer in mils. 7, 10, 15, 20, 30, 40, 60, 80... The mm fractions/decimals are a bit unwieldy until you get into the larger ones.Disclaimer: I obviously have a cultural bias towards inches/mils.Tim

author: uncle_bob
author_rank: Unknown
timestamp: March 14, 2016, 01:55:30 am
content: Quote from: T3sl4co1l on March 12, 2016, 08:03:47 pmHiSo I have an enclosure that is 100 inches by 100 inches by 100 inches. I halve that twice and get 25 inches. I move the decimal to get mm .... errr ... ok so I got confused.Ok so I start with mils. The enclosure is 100,000 by 100,000 by 100,000. I halve that twice and get 25,000. Then I do the decimal move thing and I've got 25,250 mm.I grab my trusty metric tape measure and check my enclosureTrick works for "normal PCB" dimensions. Not quite as well for larger parts. At some point you need to get out the calculator and use 25.4.Bob

author: T3sl4co1l
author_rank: Super Contributor
timestamp: March 14, 2016, 04:08:47 am
content: What does scale matter? 2.5 meters is pretty damn close to what you'd measure, and way more than good enough for eyeballing!Obviously, for anything that needs accuracy, you reach for the rule or calculator. I wasn't claiming an obvious approximation as a substitute for accurate methods!Tim

author: m98
author_rank: Frequent Contributor
timestamp: March 14, 2016, 07:34:44 pm
content: Everything strictly SI-metric here. From system design to pcb-layout I won't use any non-SI units.Dates back to a project where I worked with pressure sensors, in their specifications the manufacturers give you anything from mmHg over PSI to cmKingLouisIV'sPiss. Well, at least not the last one. Lead me to use a sensor with an order of magnitude lower range than required.It's just very error prone to mix SI-units with anything else. If someone wants to use all imperial units, than that's fine too. But it just has to be consistent.For PCB layout, there's also no problem to stick with metric units, because almost all smd components are specified in them.

author: nctnico
author_rank: Super Contributor
timestamp: March 14, 2016, 09:28:43 pm
content: Quote from: T3sl4co1l on March 14, 2016, 04:08:47 amWell, a 5mm capacitor doesn't fit very well in a 0.2" pitched footprint even though the difference is 0.08mm.

author: T3sl4co1l
author_rank: Super Contributor
timestamp: March 14, 2016, 09:32:07 pm
content: Quote from: nctnico on March 14, 2016, 09:28:43 pmCan you people not read?...Quote from: T3sl4co1l on March 12, 2016, 08:03:47 pmI suppose I shouldn't be so snippy, schools don't teach anyone a lick of familiarity with approximations or when to use them. But really, most people here should be well beyond primary school, and should have some feel for these things.Tim

author: uncle_bob
author_rank: Unknown
timestamp: March 14, 2016, 09:47:03 pm
content: HiPossibly people who use terms like "for everything except pin pitch" when discussing an approximation should be a bit less sensitive when the very obvious limits of the approximation "everything" also includes are pointed out.Bob

author: donotdespisethesnake
author_rank: Super Contributor
timestamp: March 17, 2016, 11:25:20 pm
content: I'm using a metric grid about 70% of the time (for those using imperial, that's about 11/16).

author: vzoole
author_rank: Regular Contributor
timestamp: March 18, 2016, 06:36:32 pm
content: I use metric.

author: DutchGert
author_rank: Frequent Contributor
timestamp: March 18, 2016, 10:19:13 pm
content: Doenst the whole world except the US of A use metric?

author: obiwanjacobi
author_rank: Super Contributor
timestamp: March 29, 2016, 06:33:16 am
content: (Disclaimer: Hobbyist)I find myself switching between them for different things. Drill sizes in mm, but through-hole stuff in thou's etc. I got really annoyed that most dialogs that deal with measurements do not have a selection button for this (KiCad).After laying out a board recently, I may try to use a grid for component layout (mm for smd, thou's for thru-hole) and simply free-route based on clearances after that for the next one...(some people are probably cringing now)

author: Michaelbradford
author_rank: Contributor
timestamp: April 18, 2016, 12:12:19 am
content: I'm in uk and metric is the way to go seems a lot easier than imp