74HC02 - IC Part

74HC02

74HC02.fzpz (8.7 KB)

Hi dbrandsen,

I see two things you need to fix… First: in the Variant, enter the name of each part (74HC00, 74HC02), There can be no duplicate variant names in a family and it is the easiest way to select the parts in a family. Second: In your schematicView .svg, you don’t have any connector#terminals and your connector#terminals are labeled as connector#pins, although, the connector#terminals for schematicView are in your .fcp.

To fix… change the ID names from “connector#pin” to “connector#terminal” (the little hidden squares at the end of the lines) and the corresponding line ID names, label them as “connector#pin”.

Hi Steelgoose,
Running into a problem following your instructions. Using vim I make the changes you outline and then using the parts editor I load the updated svg for the schematic view and then select the connector graphic. This all appears to work however when I then export this part, unzip the file and view the svg again I notice that all the connector#terminal IDs have been changed back to connector#pin and all the IDs for the lines I set to connector#pin have been removed. I tried this process for both versions of Fritzing.
Lastly I tried importing a fzpz I created using the updated svg but, when I examine the part using the parts editor I notice it has no graphic selected for the connectors and a save results in an error message saying no connectors are setup.
While I thought before submitting the part I understood the process for creating a new part but, obviously I’m missing a key step in the process. fwiw, the parts I created all seem to work in both the breadboard and schematic views. I guess at this point all I can say is help. The kids in my homeschool class have been creating parts using the instructions I wrote for them so I want to get this right.
Thanks,
Doug

The part I was trying to fix was the 74hc00 one from my other post not the 74hc02 one associated with this topic.

Both part schematic are the same. I will look into it later and see what is going on… It should work like a charm…

Look at this one… 74HC02_NOR_Gate.fzpz (8.7 KB)

and open this file in notepad++, and look at the structure… http://imgh.us/74HC02_NOR_Gate.svg , I did this with CorelDraw, You may also open it with InkScape… Although, sometimes CorelDraw .svg’s will not open in InkScape.

Hi,
Looked at the schematic svg file you sent. I had done the same in defining connector#pin and connector#terminal as I saw in your file. Using the parts editor I loaded your svg in the schematic view, then selected the terminal graphic, saved the part and then exported the part. I then unzipped this file and viewed the schematic svg file using vi/vim and found the same issue. All the connector#terminal IDs had been changed to connector#pin and the IDs connector#pin had been removed. I did notice another difference in the file you sent, the ones I created had a class attribute with a value of either terminal or pin while you file did not have this attribute.
Bottom line I’m plain confused.

In my class we have made other parts related to the material we are studying that I had hoped to share but, looks like that may not be possible. While I would like to resolve this issue I don’t want to waste other folk’s precious time either. However I am willing to continue working on this as long as others are willing to invest their time.
As previously mentioned I have this behavior with both versions of Fritzing. I’m on a Mac. Also I use Inkscape.

If the terminal graphic already have check mark next to the pin name, then you don’t need to select them. I believe you are selecting the connector#terminal and renaming them to connector#pin. I also don’t know why you are exporting the part then unzipping them…

Fritzing 101:
Instead of exporting and unzipping… that is not necessary. Go the your Fritzing My Parts (not Fritzing Core)… I don’t know where it is in the Mac on the latest Fritzing update… but, it should look something like this to find your .fzp files /Fritzing/parts/user/???.fzp. To find your schematic, breadboard, pcb, and icon, /Fritzing/parts/svg/user/schematic (etc.)/???.svg. These are the same files that you exported then unzipped. Use your .xml editor to view these files instead of export and unzipping.

The .fzp is the file that points to your .svg’s and layers for your schematic, breadboard, and pcb views. It also contains the info for you metadata and connectors that you see in the Parts Editior. Each connector has three views, each view shows the layer that corresponds with the layer in your .svg and the element(s) that corresponds with the elements(s) in the .svg.

i.e. In the schematicView, (layer=“schematic” svgId=“connector0pin” terminalId=“connector0terminal”); svgId=“connector0pin” is what you are selecting in the terminal graphic, and is a required element… terminalId="connector0terminal, is not a necessary element and you will find some .fzp’s that do not have them in the view… but it works a whole lot better when you do have them… The way it works: If you have the pin only in the .svg and not terminal, when you select the pin the wire will connect the the center of the pin… If you that pin and a terminal, then when you drag a wire to the pin, instead of connecting to the center it will jump to the terminal at the end of the pin.

The svgId and the terminalId in the .svg should be the exactly the same as it is in the .fzp… If the svgId in the .svg and the .fzp are the same, then the pin in the Parts Editor, terminal graphic should have a check… if not the same, there will be no check mark… When you select the pin in the terminal graphic, the Parts Editor will change the ID name in the .svg to match the name in the .fzp… In other words, if it is checked and it is correct… do not change it.

I never use the the select terminal graphic, I always label the .svg’s to match the .fzp. I also manually edit the .fzp… this gives me a lot more flexibility.

Initially when I started creating the 74xx parts I found a ‘generic’ IC part with the same number of pins and using a text editor (vim and TextMate) to create all the other parts which sounds like what you are suggesting. I used Inkscape for altering the pin labels. I was then zipping up the 4 files and importing them into Fritzing. I experienced a problem with a part which lead me to exploring the parts editor which it appears where my problems began. Over the past few days I have read more of the documentation related to parts so I feel much more comfortable using a text editor for creating parts. I’ll use Inkscape mainly for object placement. I guess the only questions I have left are:

  • file names for new parts. ie. svg.schematic.prefix0000XXX_schematic.svg. How is the XXX string created or is this not necessary?
  • is just zipping up the 5 files to create the fzpz file the best process to use
  • sharing the part. use the above zip file or one created by exporting part from Fritzing
  • what is the preferred way to submit a number of parts

Hopefully this is the end of my questions and I can get the rest of our parts fixed and submitted.
FYI.
For the kids in my homeschool class this is their first real exposure to open source projects and the community that supports a project so I appreciate the time you have taken to help me work through this item. I want the kids to not only see open source as a viable alternative but, that support is just a “click” away. I also want them to develop an attitude of not only using open source but, to not be afraid to make contributions to a project.
So ‘steelgoose’ you have not only help me with Fritzing parts creation but, provided an example of how an open source community works.
Thanks,
Doug

Some of the instructions on creating parts in Fritzing are outdated… It was written for the original Fritzing. I run across this all the time when I am trying to learn something, then find out the instructions I was reading was from 5 or 6 years ago and no longer apply… frustrating… :confounded:

I never use the xml editor (text editor) to create an .svg for a part. I use notepad++ but any xml editor will work, and I use it to edit the .fzp an .svg. Mostly to see what is going on in the files and edit some names, etc. i.e. The pcb’s on the old Fritzing parts have separate copper0 and copper1 layers… On the updated Fritzing they need to be embedded. This can be easily modified in the editor by deleting one of the layers and moving the ID copper1 or copper0 inside the other. It doesn’t make any difference which way they are embedded, they can be either/or.

I am not familiar with zipping up the 4 files and importing them into Fritzing… To me that sounds like a disaster waiting to happen as there in no error checking. All .svg images should be loaded into the Parts Editor for creating a new part. The Parts Editor, error checks your .svg images and modifies it so the Fritzing can read the file. The Parts Editor also add the “gorn”, that is needed for positioning and for flipping and rotating

Fritzing 102 - How To Create a New Part
Find a part that is close to the one you want to create (I like to use generic parts created by the Fritzing Part-O-Matic or PartFactory when ever possible… because they are property formatted and not using the old Fritzing formats. Most often, generic connectors or generic ICs, but not always… depends on the part. You did it right, you picked a generic IC.

Open the part in the Parts Editor, and then save it with the prefix of your new part name. This new prefix part name is just to make it easy to identify in the folder when you are trying to find the file. I may name it 74HC02_NOR_Gate, If I am creating an updated part and sending it to someone I may call it, 74HC02_NOR_Gate_v2… because if it is named the same Fritzing will not install a duplicate part. When you save it in the Parts Editor, the Editor will generate an underscore and a whole bunch of numbers and letters, an underscore, and a number 1 on the end of your prefix, This is Fritzing’s moduleID number for that part.

All .svg’s will also be name with the same moduleID along with another underscore and the image name (pcb, schematic, breadboard, and icon), every time you edit an .svg image and re-save it, the Editor will create a new .svg file with the same moduleID, except the trailing sequence number (2_schematic) etc. and in the part.fzp, the Editor will also edit the name of the image to the new image .svg name.

To find the image in Fritzing, you can either click on File then “Show in Folder” in the Parts Editor or just go to the folder where it is located. The why I do it… I will open the image in the graphics editor, (InkScape in your case), edit the file, then save it in what I call a master folder. i.e. this folder may be call MyParts/74HC00 and save it with the part name 74HC02_schmatic, You can put all your images in that folder for that series if you like. I then use the Parts Editor, in the menu under File, “Load Image for View”. If all the connectors are checked I will save it. If one of connectors are not checked then I probable misspelled something in the .svg file.

If I need to edit the .svg and correct my spelleing… typo… I will correct it in the graphics editor, save the .svg again and Load the Image for View… again. The parts editor will check for errors… if you don’t have embedded copper layers it will tell you, if you don’t have the droid font it will fix it for you. The reason that most parts don’t work is because they fail to use the Parts Editor to create them.

Now that you have the .svg master file you can edit it for the next part in the series and save it (74HC03_schmatic), etc.

Sometime you need to clean up the .svg’s, delete the old gorn,s and other metadata that can mess up the image on your new part. :grinning: