Generic ICs with oblong/rectangular pads?

you could start with the svg generator https://werner.rothschopf.net/fritzing/part.html : 36 pins, row distance 20000, pin distance 100 mil. You have to shift the pins GPIO8 to SCL and delete some pins on the other side, but at least it’s a start.

Apparently but I don’t know what :slight_smile: . @steelgoose gave me the formula a few years ago and it works. Using a 20 thou stroke width (at standard scale) a 0.038 hole for a header pin has a pad diameter of 0.078in which in turn is 0.078 - 40 (2 * 20 stroke-width) and creates a 0.038 hole in the gerber output. I actually don’t know why the stroke-width needs to be doubled, but it does. This varies by editor as well, Coral Draw (which @steelgoose uses) calculates the hole size differently and I don’t know how illustrator does it.

Peter

AH! The problem is (I think) mixing of the hole, pad, and svg element circle dimensions.

The pad is 78 mil diameter
The hole is 38 mil diameter
The stroke is 20 mil

But the svg circle element diameter is 58 mil (radius = 29 mil), with half of that 20 mill stroke outside, half inside the circle. Which makes the radius of the hole 29 - 10, and the radius of the pad 29 + 10. 19 * 2 = 38, 39 * 2 = 78, giving the 38 mil hole and 78 mil pad diameters.

The rest is the different ways the editors use information to generate the svg. They might treat the requested circle radius/diamater as (any of) the hole, pad, or svg element radius/diameter, and adjust to match the stroke size.

They are easy enough to do. You basically need an oblong path which contains a standard circular pad (with the connectorxpin label) in it so that the gerber code will find the circle to make the hole. I have not found a way to do that in a path. A circle specified as a path works, but an oblong path with a circle in it has not for me (the gerber code doesn’t find the path.) It is best to remove any translates in the pad because that sometimes breaks things. There are a number of example parts available both in core parts and in the forums.

Peter

I can do the circular hole cut in a path, but that does not help. The Fritzing code does not see it as a hole that needs to be included in the gerber export. It needs to be 2 separate svg elements. An actual circle element to get Fritzing to generate the hole for Gerber, and a path to get the desired pad shape.

I have a python script that will generate a row of them based on parameters. Work in progress. It currently generates valid svg, but only for pads centred over the hole. I want to be able to also offset the pad, so the hole is closer to one end, and generate a second row of pins with the offset the opposite direction. This does use transforms for simplification, but that is x,y translate only.

FZ only accepts circle, so you put that oblong pad under a normal circle pad. I think it’s in my last vid.

@Old_Grey That is what my python program does. Generates an array of circle and path elements.

The current version of my script will be able to generate contiguous sections of the oval connectors, but they will need to be manually merged. Looks like it would need 10 segments.

A future version (may be) able to generate the whole layout at once, but then the parameters to define what is needed are going to be complex. Another possible future version would generate sections (say the dip28), but instead of creating a new file, added the connectors to the file created by previous runs that built and added other sections. That should just need x,y offsets and a reference, to tell it where to insert the new connectors relative to the existing. As a bonus, building the layout up in segments, means each segment could potentially use different size and shape for the pads.

At some point (likely not soon :slight_smile: ) I intend on modifying the parts factory to do this when generating generic ICs and headers (and fix double row headers which are currently broken in breadboard.) I had started this a couple of years ago, and recently went back to it when I discovered there is code to deal with older Fritzing versions which makes this whole process much more complex. I think the way forward here is python as @microMerlin has done to prototype what we want to do more easily than changing the C++ source, and once we have a desirable set of tools modify the parts factory C++ code to implement it. I have a few parts, one example here:

with oblong pins for headers. I think there should be single row version as well although I couldn’t immediately find them. At present to get different sizes you need to edit the underlying svgs though there isn’t yet an automated tool in python.

Peter

Peter

I need a generic ic that has 40 pins, a pitch of 2.54mm and a pin row distance of 700 thousand, I have used the tool SVG Generator 0.2 but it has generated the svg, as I could now turn it into a fzpz?

There are several ways (I’m assuming you have done only pcb or both pcb and breadboard?) You can load a generic 40 pin IC in to the parts editor then select pcb view then File->Load Image for view and feed it your new svg. Then File->save as new part and the fzpz will appear in the mine parts bin. How I would do this is to edit the fzp file directly to add the new svg, the details of this can be found in this tutorial series:

this requires that you understand the underlying file formats for the svgs and the fzp file, if you don’t the parts editor may be easier (but much more limited!)

Peter

this SVG Generator does exactly what it’s named for: it generates a SVG.
Otherwise it would be named “fzpz” generator. :wink:

As Peter told already, start with a generic 40pin IC and change the SVG.