Coder Social home page Coder Social logo

momu / kiri Goto Github PK

View Code? Open in Web Editor NEW

This project forked from leoheck/kiri

0.0 0.0 0.0 4.52 MB

Kiri is a visual tool designed for reviewing schematics and layouts of KiCad projects that are version-controlled with Git.

License: MIT License

Shell 57.53% JavaScript 24.03% Python 7.44% CSS 2.92% Makefile 0.49% HTML 7.58%

kiri's Introduction

Kicad Revision Inspector (KiRI)

KiRI started as a script to experiment having a visual diff tool for Kicad projects. After some time, it became an interesting and it is still being updated.

Currently projects made with Kicad 5, 6 and 7 are supported.

KiRi uses internally existing tools to export schematics and layout to SVG images that can be later compared.

So, when exporting schematics pages to SVG images:

  • if Kicad 7 is installed, the new kicad-cli is used for both projects made with Kicad 6 and 7
  • if Kicad 6 is installed, schematics are exported using xdotool on Linux/Windows and cliclick on macOS, using the GUI.
  • if Kicad 5 is installed, Plotgitsch and plotgitsch are used to export the schematics

When exporting the layout layers in SVG images:

  • Kicad-Diff is used for all supported Kicad versions using pcbnew library available in python. kicad-cli is not used on Kicad 6 and 7 projects because it is slower than the python script since each layer has to be exported individually and this tool cannot do that at once.

KiRI Installation

Check the Installation instructions, here.

Using KiRI

KiRI can be launched with the following command, anywhere, inside or outside of the repository of the project.

kiri [OPTIONS] [KICAD_PROJECT_FILE]

KICAD_PROJECT_FILE can be passed, but it can also be omitted. If running from inside the repo, it will use the .pro or .kicad_pro available. If both are present (which is not good), it will ask your choice. The same happens is running outside of the repository without passing the KICAD_PROJECT_FILE.

Command line options (aka Help)

Command line flags can be seen using the -h flag

kiri -h

Archiving generated files

There is a possibility to archive generated files (check the help above).

To visualize generated files it is not necessary to have kiri installed. You just have to unpack the generated package and then execute the webserver script (./kiri-server) inside of the folder, as shown below:

tar -xvzf kiri-2021.11.18-16h39.tgz
cd kiri
./kiri-server .

Kicad Integration

It is possible to integrate KiRI with PCBNew by adding a button to its toolbar with the following command:

# Create folder if it does not exist
mkdir -p "~/.kicad/scripting/plugins"

# Copy the plugin there
cd ./kiri
cp -r "./kicad/plugin/kiri_v6/" "~/.kicad/scripting/plugins/kiri"

KiRI Screenshots

Browsing the schematic view walking through and comparing each page of the schematics, individually.

Schematic View

Browsing the layout view walking through and comparing each layer of the layout, individually.

Layout View

Here is the comparison of the schematics when the project is updated from using Kicad 5 (.sch) to Kicad 6 (.kicad_sch).

Layout View

Shortcuts are a really good way of walking through the commits, pages and layers quickly. Check the available shortcuts by hitting the shortcut i.

Layout View

A quick and old demo on the Youtube.

Kicad Revision Inspector Demo


Are you enjoying using this tool, feel free to pay me a beer :). Cheers!

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.