Skip to content

QFN_packages: fix calculation of circular pin 1 marker position/size

For circular pin 1 markers the fp_r parameter is documented as being the radius but was actually taken as diameter. In addition the distance from package edge to circumference of the marker was fp_d + fp_r/2, not fp_d (or fp_d - fp_r if fp_d were meant to measure from package edge to center of the marker).

Most of the datasheets don't give any information about pin 1 marker location and size. Out of the few that do, only Analog_LFCSP-UQ-10_1.3x1.6mm_P0.4mm had a value matching the datasheet and it used the specified diameter as fp_r value. For this reason I'm assuming that the previous fp_r values were actually meant to be the diameter, not the radius.

Fix the calculation and at the same time adjust the fp_r and fp_d values so that the output remains the same.

The alternative would be to fix the documentation to state that fp_r is the diameter rather than the radius. However that would be rather confusing given the r (for radius) in the name and that a parameter fp_d (meant as distance, could be mistaken for diameter) exists.

Fixes #10.

Verified using git diff --ignore-matching-lines='/. time_stamp ./ ' --no-index that the output from the QFN_packages generator is unchanged (except for the time_stamp lines which change with every invocation).


One-off conversion script from fp_r / fp_d* to marker_diameter / marker_distance_from_edge*: convert-QFN_packages-marker-params.py

Edited by Sascha Silbe

Merge request reports