Skip to content

Instantly share code, notes, and snippets.

View gustavohleal's full-sized avatar

Gustavo Henrique Leal gustavohleal

View GitHub Profile
@gustavohleal
gustavohleal / download-buidl-and-install-ghdl.sh
Created October 20, 2018 14:37 — forked from mathieucaroff/download-buidl-and-install-ghdl.sh
Download build and install GHDL on Ubuntu 18.04 (tested 2018-09-28)
#!/bin/sh
#
# download-buidl-and-install-ghdl.sh
#
# It took about 5 minutes on my laptop (2018-09-28).
sudo apt update
sudo apt install -y git make gnat zlib1g-dev
git clone https://github.com/ghdl/ghdl
cd ghdl
@gustavohleal
gustavohleal / run.sh
Created October 23, 2018 23:41 — forked from debemdeboas/run.sh
VHDL Compiler and Simulator
#!/bin/bash
echo "Checking syntax..."
ghdl -s --ieee=synopsys full_adder.vhd cla_4bits.vhd sum_cla_8b.vhd sub_cla_8b.vhd cod.vhd ULA.vhd ULA_tb.vhd
ghdl -a --ieee=synopsys full_adder.vhd cla_4bits.vhd sum_cla_8b.vhd sub_cla_8b.vhd cod.vhd ULA.vhd ULA_tb.vhd
echo "Generating executable file..."
ghdl -e --ieee=synopsys ulatb
ghdl -r --ieee=synopsys ulatb --vcd=ulatbwave.vcd
echo "Opening gtkwave..."
gtkwave -o -g ulatbwave.vcd