Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

signal in an array

Status
Not open for further replies.

dorack

Technical User
Jun 10, 2008
3
US
Hi all !!

I will try to be as clear as possible.

I would like to put some signals names in an array and then to use it in a process.

--Declaration array :

TYPE Data_NCL IS ARRAY (0 to 12) of dual_rail_logic;

--in the process before the begin:

variable Ci : Data_NCL;

--after the begin :

Ci(0):=CNi00;

--And then use it like that:

Ci(0) <= to_DR('1');--mean give value data "1" to signal CNi00

but I have this error : Target of signal assignment is not a signal.

I hope I was clear so if you have any idea ...
(I need that to be able to make a loop for saving line of code (same code quite long for many signal))

Thanks,

David.


 
I forgot to say that this code is used in a testbench. It may does matter ...

thanks you,

David.
 
you have declared Ci as a variable, but then tried to use signal assignment (<=). You need to use variable assignement :)=);

Barry
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top