VHDL语法学习笔记

原创 2006年05月18日 15:36:00
1/
   port's direction:
<               in
>               out
>               inout
>               buffer
>               linkage      (no confirmed direction, can link with any direction's signal.)
2/
   data type:
>        there's 10 typies of a data.but always use this one:
>               bit  (can be '1' or '0') and this type often be declared in 'std_logic' and 'std_logic_vector'
>              
3/
    block  usage:
>       [blockname]:
>        block
>        begin
>               .......
>        end block [blockname];
[ftc=#F68E54]block is a structure of VHDL expressions in block are collateral,which are different from process [/ft]
4/
   subprogram
>      there are two kinds of subprogram: function and procedure.And their usage:
>            function [function name] (<argument list>) is
>               return  [data name] is
>               [declaring expressiong]
>            begin
>               [access expression];
>                return [variable name];
>            end [function name];
>       ---------------------------------------------------------
>            procedure [procedure name] (<arguement list>) is
>            begin
>                [access expression];
>            end [procedure name];
And something should be noted is  [ftc=#F68E54]Expressions in function and procedure are ordinal  accessed[/ft]
5/
   package usage:
>      package [package name] is
>          {construction expression];
>      end [package name];
>      package body [package name] is
>                [construction statement];
>      end body;
[B] So you see , package's usage somewhat like Entity,but a little different: there isn't an 'of' in before 'is'.[/B]
[ftc=#f68e54]package is used to list out signals,constant,datatype,component,function,procedure 's defintion.Which ate exprected to be used.[/ft]
6/
   configuration
>     configuration [configuration name] of [entity name] is
>           [construction statement];
>     end [configuration name];
>     configuration [configuration name] of [entity name] is
?         for [config architecture name]
>        end for;
>      end [configuration name];
[ftc=#F597e9]this configuration didn't include block and component.and use to link different level's entity structure.[/ft]
7/
   custom datatype
      a.type usage:
             1) type [typename] is [type construction] of [base datatype];
             2) type [typename] is (enumerate list];
8/
type [array name] is array ([area]) of data type;
type [array name] is array ([flag type] range<>);
    example: type bit_vector is array(natural range<>);
  variable var : bit_vector(0 to 1);
to_stdlogicvecter(a);    change a from bit_vector to std_logic_vector.
to_bitvector(a); change a fron std_logic_vector to bit_vector.
to_stdlogic(a);
to_bit(a);
[ftc=#f68e54]this four functions are includeed in std_logic_1164 package.[/ft]

9/
  wait.
            wait ;
                     wait on [signal list];
                     wait for [time];
                     wait until [condition expession];
10/
 loop
                     example:
                        l2: loop
                          a:=a+1;
                           exit l2 when a>10;
                           end loop l2;
 and it's meaning is obvious.
11/
 while loop
                            [ loop flag:] ehile <condition> loop
                                <ordinal statement>
                                   end loop [loop flag];
版权声明:本文为博主原创文章,未经博主允许不得转载。

相关文章推荐

FPGA学习笔记4-VHDL

VHDL基础(veryhigh speed IC hardware description language)--超高速集成电路语言 -IEEE业界标准硬件描述语言(IEEE 1076) -用于仿...

linq to sql 语法 学习笔记

  • 2014年09月05日 18:14
  • 69KB
  • 下载

C++学习笔记:异常的基本语法

1)若有异常 则通过throw 操作 创建一个异常对象 并抛出。 2)将可能抛出异常的程序段嵌在try块之中。控制通过正常的顺序执行到达try语句。然后执行try块内的保护段 3)如果在保护段执行期间...

C++语法学习笔记(至六十一)

  • 2015年12月04日 02:24
  • 1.35MB
  • 下载

C++语法学习笔记(到四十四)

  • 2015年11月23日 15:10
  • 567KB
  • 下载

Xml学习笔记(一):xml语法格式

一.xml语法 一个完整的xml文档包括:文档声明、元素、属性、注释、CDATA区、处理指令;  1.文档声明   用来声明xml的基本属性,用来指挥解析引擎如何解析xml文件;   要求:一...

MATLAB学习笔记以及基本语法

  • 2017年01月19日 14:30
  • 454KB
  • 下载

C# 语法学习笔记

  • 2008年05月20日 18:37
  • 19KB
  • 下载

【Objective-C学习笔记】基本语法、类与对象

第一部分 基本语法 一、与C语言的区别 1、Objecttive-C是在C语言的基础上添加了面向对象的语法,可以完全兼容C语言语法,源文件为.m文件,在编写代码的时候可以混入C语言。 2、语法预览: ...
内容举报
返回顶部
收藏助手
不良信息举报
您举报文章:VHDL语法学习笔记
举报原因:
原因补充:

(最多只允许输入30个字)