Skip to content
breadkit

Breadboard circuits, written in Ruby

Make every connection clear.

Describe holes, components, and wires. Breadkit resolves the connections so you can render a diagram and check the same circuit for mistakes.

From the button and LED example

board :half
button :SW1, at: "e10"
resistor :R1, "330", pins: %w[a12 a16]
led :D1, color: :red, anode: "b16", cathode: "b17"
Generated half-size breadboard diagram with a switch, resistor, and LED
SVG generated from the complete example See code and output

One circuit file, three tools

  1. 1. Describe

    breadkit

    Write board holes, parts, wires, and expected connections in Ruby.

  2. 2. Render

    breadkit-render

    Generate SVG or PNG diagrams from the same file.

  3. 3. Check

    breadkit-lint

    Check placement, electrical connections, and design intent.

Start with a working example

The guide pairs real Ruby files with their generated diagrams. Start with a button and LED, then move on to an offboard module.

Open the user guide

Install and run

gem install breadkit breadkit-render breadkit-lint
bkrender circuit.bk.rb -o circuit.svg
bklint circuit.bk.rb

This site documents 0.2.0 on main. If RubyGems is still at 0.1.0, use the source checkouts for newer features. Check breadkit --version after installing.

DSL files run as Ruby. Only load files you trust.