Ug Scicos HDL
Ug Scicos HDL
1 About Scicos-HDL
1.1 Features
● Links The Scilab/Scicos with the Digital circuit design(EDA).
● Integrates the hardware circuit, algorithm and Scilab/Scicos environment as a plat for digital circuit
design, simulation and Hardware Description Language generation.
● Inside libraries: Sequential logic library, Combinational logic library, Ipcore library, simulation library.
● You can specify most values in the block parameter dialog boxes using Scicos workspace.
2. Simulate the model in Scicos using a Scope block to monitor the results(inside Ghdl—VHDL
simulator).
3. Use the VHDL or Verilog HDL Compiler block to analyze your design and generate HDL language.
2.1 Introduction
This tutorial uses an example full adder design, fulladder.cos, to demonstrate the Scicos-HDL design flow.
The full adder is composed of some AND gate blocks, NOR gate blocks and NOT gate blocks as its entity
blocks, these blocks belong to combinational logic library(HDL_Combinational_Lib); some other blocks
including I/O port blocks(IN and OUT), HDL I/O ports blocks(HDL IN and HDL OUT) , simulation
blocks(Square wave generator), displayer(Mscope) and VHDL and Verilog HDL Compilers, these blocks belong
to simulation library(HDL_Simulation_Lib) and clock blocks from Scicos Sources palette. .
After finished the design and simulation, run Scicos-HDL Compilers to generate VHDL / Verilog HDL code of
your design. By this example you will know the whole flow of using Scicos-HDL to design circuit and generate
VHDL / Verilog code.
The following rules are used:
>> This sign will guide you to get into the subdirectories and select the final operation. For example:
Palette>>Palettes>>HDL_Sequential_Lib, it means that please select the palette menu,click
palettes, and then click HDL_Sequential_Lib.
This sign is a prompt, means there is significant information for you.
Bold-face It means the name of menu, the option of dialog box and so on, which you can click or select.
● Browse to the directory in which you want to save the file. This directory becomes your working
directory, This tutorial uses the working directory <D:/test/>.
● Type the file name into the File name box. This tutorial uses the name fulladder.cos.
● Click Save.
● Click the Palette menu in the menu bar and select the library, we need HDL_Combinational_Lib ,
HDL_Simulation_Lib and Sources.
The following sections describe how to add blocks to your model and simulate the model in Scicos.
Perform the following steps to add the I/O port blocks block:
● In the Palette>>Palettes, click HDL_Simulation_Lib to view the blocks .
● Double-click or drag I/O port blocks block into your model (3 IN blocks and 2 OUT blocks).
See the following picture:
2.2.5 Add the HDL I/O ports blocks(HDL IN and HDL OUT)
Perform the following steps to add the NOR gate block:
● In the Palette>>Palettes, click HDL_Simulation_Lib to view the blocks .
● Double-click or drag HDL IN and HDL OUT block into your model (1 HDL IN and 1HDL OUT).
● Double-click the HDL IN block to display the Parameters dialog box, see figure 15.
● Change the input port number to “3”.
● Click “OK”.
You will see the the HDL IN block's input port number has been changed, change HDL OUT as well, see
Figure 23 Compilers
● Choose "Simulate>>Setup" (top menu) to display the Configuration dialog box (Figure ).
Some rules
● Make sure you have put the block Scicos-HDL IN as the input ports.
● Make sure you have put the block Scicos-HDL OUT as the output ports.
● Self-connected is not allowed in every block.
● Make sure the path and name of model file are correct.
● Make sure the directory of saving VHDL / Verilog code file is correct.
3 Summarize
You can use the blocks in Scicos-HDL to create and simulate a hardware implementation of a system model in
Scicos in a short time. The Scicos-HDL Compiler blocks generates VHDL / Verilog HDL code. Scicos-HDL
makes Scicos have hardware design and simulation function. It set up a bridge between Scilab and EDA.
***************************************************************************************
THE END
Scicos-HDL Group 2008-04