FPGA Center



GROUP

This VHDL structure is used to group entities. Atributes are used in entities. User defined attributes can be linked to every entities independently. Thus each entity has its own atribute. If you need to get information from more than one entities, you have to use group and an attribute for each group.

group group_template_name is ( entity_class_list ) ;
group group_name : group_template_name ( group_constituent_list );

NOTE: Groups can be used as nested.

Group Temp Declaration

In order to declare temp group, groups which are linked to entities in a certain class. These classes can contain entity, architecture, configuration, procedure, function, package, type, subtype, constant, signal, variable, component, label, literal, units, group or file. Each entity class represents an entity class in a group. (Example 1)

<> symbol can be used together with entity class name. This expression should be at the end of the list. (Example 2)

Group Declaration

Entities are connected with their properties in group declaration. This section consists of identifiers, group temp name and group list. Identifier represents a group, group temp name represents task declaration of group, group list represents entities wich belong to this group. (Example 3)

Attributes of Groups

The attribute specification of a group is realized in a similar way to other attribute specifications. First, the attribute of a given type is declared and it is specified for the given group in its declaration part which contains declaration of the particular group (Example 4).

In order to use attributes ing groups, group is declared first, then attribute is declared for the group that will be connected.

Example 1

group Variable_group is ( variable, variable );

Group templete called Varible_group is created two variables which belong to this group.

Example 2

group Component_group is ( component <> );

In this example, a group called Component_group is declared. So groups are created with indefinite length of components..

Example 3:

group Input_pair : Variable_group ( A1, A2 );

In this example, a group called Input_pair has two variables, A1 and A2. Remember group templete Variable_group was created in Example 1.

Example 4:

function Compute_Values (A, B:Integer) return BOOLEAN is
variable A1, A2: Integer;
group Variable_group is ( variable, variable );
group Input_pair : Variable_group ( A1, A2 );
attribute Input_name: String;
attribute Input_name of Input_pair : group is "Input variables";
begin
  .......
end function;

In this example, the value of Input_name attribute of Input_pair group is assigned as Input variables.

                                                                                                           

    

                                                                                                                                    

 

                                                                                                                                                                                                                                                                   

Home | Fpga | VHDL | VHDL Dictionary | Digital Design | Simulation | PCB | Examples | Contact Us
Copyright © 2010 - 2013 FPGAcenter. All Rights Reserved.