Code error

L

Luiz Gustavo

Guest
why when I try to do something like this:


reg channel1status [15:0];
reg channel1auxstatus [15:0];

always @(reset)
begin
//channel 1
channel1status = 16'h0104;
channel1auxstatus = 16'h0000;
end

The Quartus II give me a error:
"values cannot be assigned directly to memory channel1status"
"values cannot be assigned directly to memory channel1auxstatus"

???
 
On Apr 10, 8:55 am, "Luiz Gustavo" <luizval...@gmail.com> wrote:
why when I try to do something like this:

reg channel1status [15:0];
reg channel1auxstatus [15:0];

always @(reset)
begin
//channel 1
channel1status = 16'h0104;
channel1auxstatus = 16'h0000;
end

The Quartus II give me a error:
"values cannot be assigned directly to memory channel1status"
"values cannot be assigned directly to memory channel1auxstatus"

???
try:

reg [15:0] channel1status;
reg [15:0] channel1auxstatus;

HTH,
Gabor
 

Welcome to EDABoard.com

Sponsor

Back
Top