diff options
author | gatecat <gatecat@ds0.me> | 2021-02-15 09:39:56 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-02-15 09:39:56 +0000 |
commit | 065f46daeb05a8b12cc663a44410b6da27a8d9e3 (patch) | |
tree | ca538791141e442c105c47f836069f95ce2f988d /machxo2/examples/blinky_ext.v | |
parent | 1b6cdce9251d42236a3db0314e84d6a3e3f06408 (diff) | |
parent | 9c9a02628d60dca9c9a566b0fcf3bf3dd2c68076 (diff) | |
download | nextpnr-065f46daeb05a8b12cc663a44410b6da27a8d9e3.tar.gz nextpnr-065f46daeb05a8b12cc663a44410b6da27a8d9e3.tar.bz2 nextpnr-065f46daeb05a8b12cc663a44410b6da27a8d9e3.zip |
Merge pull request #578 from YosysHQ/machxo2-rebase
machxo2, rebased and updated
Diffstat (limited to 'machxo2/examples/blinky_ext.v')
-rw-r--r-- | machxo2/examples/blinky_ext.v | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/machxo2/examples/blinky_ext.v b/machxo2/examples/blinky_ext.v new file mode 100644 index 00000000..a8bdd588 --- /dev/null +++ b/machxo2/examples/blinky_ext.v @@ -0,0 +1,19 @@ +// Modified from: +// https://github.com/tinyfpga/TinyFPGA-A-Series/tree/master/template_a2 + +module top ( + (* LOC="13" *) + output pin1, + (* LOC="21" *) + input clk +); + + reg [23:0] led_timer; + + always @(posedge clk) begin + led_timer <= led_timer + 1; + end + + // left side of board + assign pin1 = led_timer[23]; +endmodule |