Import previous KiCAD projects after system reinstallation

Recently, for some reasons, ubuntu needs to be reinstalled, and then kicad must be reinstalled. There are version compatibility issues, and there are also problems with importing custom libraries. Make a note here.

Original version: Ubuntu 16.04 KiCAD 5.1.

The new system is Ubuntu 18.04, and the default installation is KiCAD4.0, which is obviously too old to open the 5.1 project file. The PPA on the KiCAD website only provides 6.0.

Install on Ubuntu | KiCad EDA

I followed the command of that website and changed the version number a little bit.

sudo add-apt-repository --yes ppa:kicad/kicad-5.1-releases
sudo apt update
sudo apt install --install-recommends kicad

This will install it.

After installation, you can open the pro file of the original project, and it will prompt a bunch of things that cannot be found. At this point you need to add 3 things.

All in the Preference above.

1. Configure Paths, to set the environment variable, an important environment variable of the portapack project is KISBLIB, which should be set to the library-kicad folder in the current project directory.

2. Manage Symbol Libraries, which is the symbol library, create a new item in the Project Specific Libraries on the second page, and fill in the corresponding position.

3. Manage Footprint Libraries, which contains the packaging library, similar to the above, but also add an item to the Project Specific Libraries, and then fill in the location of the local packaging library.

 After completing the above operations, you can verify it, first open the schematic diagram and PCB to see if there is still an error, and update the PCB with the schematic diagram to see if there is any problem.

Then add a self-designed chip symbol in the schematic diagram, and specify the package to see if it goes well.

Adding a symbol is very simple. In the schematic editor, there is a Place symbol icon on the right, and then enter the device model to be added.

After confirming, point the mouse to the device, and press the E key on the keyboard. The following dialog box will appear. Find Footprint, press the small gray icon on the right.

Then find the package corresponding to this model. This package should be under the newly added package library. If the correct shape can appear, there is no problem. If there is a problem, there will be a prompt.

Then press Enter to specify the package.

So far, KiCAD is almost configured.

There is another problem later, KiCAD needs plug-ins to generate files for production, such as Gerber BOM and PickandPlace. This requires a third-party plug-in. The plugin needs to be reinstalled. (Gerber does not need a plugin, but I still like to use a plugin to generate it in one go.)

Plug-in download address:

GitHub - xtoolbox/kicad_tools: Manufacture document generate tool for kicad.

Instructions:

1. Download kicad_tools-master.zip directly with the browser to the local.

2. Find the /usr/share/kicad/scripting/plugings folder and create a new folder kicad_tools

sudo mkdir kicad_tools

3. After decompressing the previously downloaded zip package, enter the following command

sudo cp *.py /usr/share/kicad/scripting/plugins/kicad_tools/

4. Open the pro file of your project with kicad, find the PCB, and then execute the Gen Manufacture Docs command under [Tools]->[External Tools].

 5. Select the appropriate option in the pop-up window, and then click Generate. For the meaning of different options, see several png images in github.

6. You can find several files you need according to the information in the generated results, such as BOM.csv POS.csv and gerber.zip.

I recommend that you use the gerber that comes with kicad to generate the file before using this script, because it will automatically lay copper and detect DRC for you.

The Github program has a hint worth noting:

GenMFDoc() will change the drill origin of the board. It is recommended to use GenMFDoc() to generate the BOM file and position file first, and then generate the Gerber file.

I used kicad's GerbView tool to view the newly exported and previously used files for production, and found that the BOM and POS are exactly the same, but there is a little difference when comparing gerber.zip, what is the difference in the circuit, mainly because the location is different.

 

Top left is newly exported, bottom right is old. But I also compared the position of the mouse with the POS. On the contrary, the newly exported gerber.zip is more consistent with the original position in the POS (the x is consistent, and the y symbol is reversed). Maybe there is no problem with the newly exported file.

Guess you like

Origin blog.csdn.net/shukebeta008/article/details/124711015