Hallo Leute, ich möchte wie der Titel schon sagt einen Counter mit einem Wert laden. Hier der Ausschnitt der mir Kopfzerbrechen bereitet. library IEEE; use IEEE.std_logic_1164.all; use IEEE.numeric_std.all; architecture Behavioral of LCD_Display is constant CLOCK_PERIOD :positive := 16 ; constant test : positive := 60; constant test_CYCLES : positive := tCRP / CLOCK_PERIOD; signal Counterabc :unsigned(7 downto 0):="00000000"; Counterabc <= to_unsigned(test_CYCLES); IN mode Formal SIZE of to_unsigned with no default value must be associated with an actual value. Mfg Commtel
Gast
#1661092
du musst bei to_unsigned die Bitbreite angeben
> du musst bei to_unsigned die Bitbreite angeben
Etwa so:
Counterabc <= to_unsigned(test_CYCLES,Counterabc'width);
Aber warum machst du aus deinem Counter nicht auch gleich einen Integer?
Vielen Dank D. I. und Lothar Miller ich werd den Zähler auf Integer umstellen. Frohe Ostern
Antwort schreiben
Bitte melde dich an, um einen Beitrag zu schreiben.