Skip to content

Commit

Permalink
Merge pull request #26 from TACIXAT/hx8k
Browse files Browse the repository at this point in the history
Tutorials 2-5 for the hx8k.
  • Loading branch information
Obijuan committed Mar 18, 2020
2 parents dfbde7b + 2af048a commit dcc138c
Show file tree
Hide file tree
Showing 36 changed files with 843 additions and 919 deletions.
16 changes: 8 additions & 8 deletions tutorial/ICE40-HX8K_Breakout_Board/T01-setbit/T01-setbit.v
Expand Up @@ -30,14 +30,14 @@ module setbit(
output LED8
);

wire LED1;
wire LED2;
wire LED3;
wire LED4;
wire LED5;
wire LED6;
wire LED7;
wire LED8;
wire LED1;
wire LED2;
wire LED3;
wire LED4;
wire LED5;
wire LED6;
wire LED7;
wire LED8;

//-- Implementacion: el pin deseado esta cableado a '1'
// los demas estan cableados a '0'
Expand Down
18 changes: 9 additions & 9 deletions tutorial/ICE40-HX8K_Breakout_Board/T01-setbit/T01-setbit_tb.v
Expand Up @@ -26,25 +26,25 @@ setbit SB1 (
//-- Comenzamos las pruebas
initial begin

//-- Definir el fichero donde volvar los datos
//-- Definir el fichero donde volvar los datos
//-- para ver graficamente la salida
$dumpfile("T01-setbit_tb.vcd");
$dumpfile("T01-setbit_tb.vcd");

//-- Volcar todos los datos a ese fichero
$dumpvars(0, setbit_tb);
//-- Volcar todos los datos a ese fichero
$dumpvars(0, setbit_tb);

//-- Pasadas 10 unidades de tiempo comprobamos
//-- Pasadas 10 unidades de tiempo comprobamos
//-- si el cable esta a 1
//-- En caso de no estar a 1, se informa del problema, pero la
//-- simulacion no se detiene
# 10 if (LED1 != 1)
$display("---->¡ERROR! Salida no esta a 1");
else
$display("Componente ok!");
$display("---->¡ERROR! Salida no esta a 1");
else
$display("Componente ok!");

//-- Terminar la simulacion 10 unidades de tiempo
//-- despues
# 10 $finish;
# 10 $finish;
end


Expand Down
Binary file not shown.

This file was deleted.

Binary file not shown.
Binary file not shown.
Binary file not shown.
125 changes: 0 additions & 125 deletions tutorial/ICE40-HX8K_Breakout_Board/T01-setbit/images/setbit-1.svg

This file was deleted.

Binary file not shown.

0 comments on commit dcc138c

Please sign in to comment.