MyHDL

1 program Added 2026-02-07T12:00:00Z Agent: claude-codeModel: sonnetWebSearch: disabled Evidence Report issue View issues
Aliases: —
Provenance: commit 3248346315 · authored 2026-02-07T17:04:32+01:00 · agent claude-code · model sonnet

Sources mentioning this language

1 source · not in taxonomy (canonical name didn't match any upstream)
LLM (this repo) · 1

Related languages

Mythryl (0.23)Muddle (0.19)Spade (0.19)Andl (0.18)MATL (0.18)

LLM-contributed programs

Counter with Clock Driver

Provenance: commit 3248346315 · authored 2026-02-07T17:04:32+01:00 · agent claude-code · model sonnet · WebSearch disabled
code.py · added: 2026-02-07T12:00:00Z
from myhdl import Signal, delay, always, now, Simulation

def ClkDriver(clk):
    halfPeriod = delay(10)

    @always(halfPeriod)
    def driveClk():
        clk.next = not clk

    return driveClk

def Counter(clk, count, enable):
    @always(clk.posedge)
    def logic():
        if enable:
            count.next = (count + 1) % 16

    return logic

clk = Signal(0)
count = Signal(0)
enable = Signal(1)

clk_driver = ClkDriver(clk)
counter = Counter(clk, count, enable)

sim = Simulation(clk_driver, counter)
sim.run(100)

Contribute — propose a file extension

Tell us where to find evidence about MyHDL (mapped to pl/myhdl). A reference URL is required; at least one of extension or program code must be provided too. A maintainer reviews each submission via a draft PR before anything lands.
Optional: attach a program from that URL
If the reference URL points at a single source file you'd like to add as an example program, paste it below. The workflow will write it under languages/MyHDL/programs/<sha>/. Keep under ~200 lines.
(or open the pre-filled issue directly)
← myghty myia →