- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
In my architecture I put a loop for, and I want when my index = 1, switch on my led 1,
but for others switch them off, maybe this is a stupid error, but myfollowing code is wrong the error comes from line : if (i = 1) then, please anyone could help me ? gene_led: for i in 4 downto 1 generate process(init,opg_clk) begin if (i = 1) then led(i) <= '0'; else led(i) <= '1'; end if; end process; end gene_led;Link Copied
2 Replies
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
please be so kind to say something more about the error and what you intend to do...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I didn't defined led as a signal but as a variable that's why it couldn't work :p
thanks to have answered me
Reply
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page