-
Thread
Wave Simulation DEMUX
std_logic); end demux; architecture behaviour of demux is begin process(S,X) begin case S is when "00"=> Y1 <=X; Y2<= '0'; Y3<= '0'; Y4<= '0'; when "01" => Y2<=X; Y1<='0'; Y3<='0'; Y4<='0'; when "10" => Y3 <=X; Y1 <='0'; Y2 <='0'; Y4 <='0'; when others => Y4<=X; Y1 <='0'; Y2 <=
-
Thread
Easy question about pipeline: Is this code synthesizable?
modules and compare them. for i in 0 to 2 loop case i is when 0 => temp1 <= a*data; when 1 => temp2 <= temp1*b; when 2 => result <= temp2*c; when others => null; end case; end loop;
pipelines regarding the space axis. Conditional synthesis makes sence for those applications only when pipeline lengths and micro cycles have to be dynamically tuned (conditional time axis), which is rarely required. Furthermore I would recommend not to use those *temp" naming since there is nothing
-
Thread
Reset Problem
state_storage: process(reset,clock) begin if reset='1' then state <=IDLE; char_code<=(others=> '0'); char_ready<='0'; elsif (rising_edge(clock)) then state <= next_state; char_ready <= char_ready_next; char_code<=char_code_next; end if; end process state_storage
ins IDLE springen: [c] next_state_func: process (keytrigger_next, state) begin case state is when IDLE => [/c] Der sourcecode ist weit über 100 Zeilen lang, dass will ich euch wirklich nicht zumuten...
-
Thread
counter vhdl
IST 30 MHZ ICH HABE SO GEMACHT ABER KLAPPT NICHT .. ... necsr <= necsr(1 downto 0) & nec when rising_edge(clk); bits <= bits (31 downto 0)& necsig when rising_edge(nec) if (necsr(2 downto 1)= "01") then -- start bit fuer zâhler cnt <= 0; -- bei jeder steigende flanke
aktuellen necsig. bsp: [vhdl] process (clk) begin necsr <= necsr(1 downto 0) & nec when rising_edge(clk); if (necsr(2 downto 1)= "01") then -- start bit fuer zâhler cnt <= 0; -- bei jeder steigende flanke zähler auf null gesetzt bits <= bits (31 downto 0)& necsig ; ELSE
-
Thread
Drehzahlmessung mit Encoderscheibe
wait until rising_edge(clk); cu := '0'; -- lokale Werte cd := '0'; case z is when Z00 => if (e = "01") then z <= Z01; cu := '1'; elsif (e = "10") then z <= Z10; cd := '1'; end if; when Z01 => if (e = "11") then z <= Z11; cu := '1
; elsif (e = "00") then z <= Z00; cd := '1'; end if; when Z11 => if (e = "10") then z <= Z10; cu := '1'; elsif (e = "01") then z <= Z01; cd := '1'; end if; when Z10 => if (e = "00") then z <= Z00; cu := '1
-
Thread
Unsigned und Vergleichsoperator
Du meinst wahrscheinlich numeric_std? Nimm VHDL 2008, dann kannst Du [vhdl] case t is when 8d"1" => i <= i + 1; when 8d"2" => i <= i + 2; ... end case [/vhdl] schreiben. Und wenn dir das nicht gefällt (oder deine Tools kein VHDL2008 können), dann schreib': [vhdl] case to_integer(t) is when 1 => ... end case; [/vhdl]
-
Thread
Erfahrungsbericht Pins hochohmig schalten
Initialisierung mit 'Z': [vhdl] mcb3_dram_dq : inout std_logic_vector(15 downto 0):= (others => 'Z'); [/vhdl] Leider ohne gewünschtes Ergebniss, der FPGA wird verdächtig heiss (Finger unangenehm heiss, gemessen 51°C). Der FPGA ist zu einem prozent ausgelastet. Die Lösung brachte erst
termination resistors will always be present whenever the I/O is 3-stated, and instantly turned off when the output buffer is enabled." MfG,
-
Thread
Verständnisfrage Kombinatorischer Prozess
TRANSITION_LOGIC : process( state , i ) begin next_state <= state ; case( state) is when "00" => if i = ’1’ then next_state <= "01"; else next_state <= "00"; end if; when "01" => if i = ’1’ then next_state <= "10"; else next_state <= "00"; end if; when "10" => if i = ’1’ then next_state <= "10"; else next_state <= "00"; end if; when others => next_state <= "00"; end case; end process;[/code]
-
Thread
Programm läuft nur im Simulator
du anders schreiben: [vhdl] MUX_1: process(MIN_S, c_szeh_int, sec) begin case MIN_S is when '1' => c_szer_int <= sec; when others => c_szer_int <= c_szeh_int; end case; end process MUX_1; [/vhdl] Nämlich so: [vhdl] c_szer_int <= sec when MIN_S='1' else c_szeh_int; [/vhdl]
-
Thread
"Guter Programmierstil" VHDL
- Wenn ich eine Decoderlogik baue, dann steht halt als record-name innerhalb eines 'if' oder 'when' der Gesamtname, z.B. [vhdl] hugo <= hregs.hugo when ..... else tgt1.hugo when ..... else meier.hugo when others; [/vhdl] Auch hier kurze aber aussagefaehige Namen und ich muss
stimme ich zu. So lässt sich das VHDL sicherer bauen. Komisch an dem Buch ist auch der Hinweis, WHEN und WITH nicht zu verwenden.
-
Thread
VHDL, FPGA, RAM, Anfängerfrage
ganz grob so aus: p1: process (CLK) begin if rising_edge(CLK) case COMMAND is when C0 => D0 <= DATA; when C1 => D1 <= DATA; ... end case; end if; end process p1 Soweit kein Problem, auch wenn ich vielleicht einige Syntax-Fehler getippt habe und sicher noch
BUS_UC_WIDTH - 1 downto 0); -- Daten FPGA -> uC : -- Bustreiberumschaltung UC_DATA <= UC_DOUT when UC_WE='0' else (others=>'Z'); UC_DIN <= UC_DATA; [/vhdl] Das asynchrone Umschalten des IO-Treibers ist nötig, weil du sonst immer wieder einen Buskonflikt oder einen offenen Bus hast. Ich
-
Thread
inout Signal und die Simulation
inout STD_LOGIC_VECTOR(7 downto 0); ... ext_rw_data: process(CLK, CLEAR) ... begin DATA <=(others =>'Z'); ............. [pre] if (RW='0') then byte_count := byte_count + 1; if byte_count = 1 then var_start := DATA; end if; if var_start = X"AA" then if byte_count
std_logic_vector(7 downto 0); [/pre] als Concurrent Statement: [pre] DATA <= WriteData when WriteEnable = '1' else (others => 'Z'); ReadData <= DATA; [/pre] Danach nur mehr mit Write/ReadData und WriteEnable arbeiten, so hast du eine saubere Beschreibung des Tri-States. Gibt der Simulator
-
Thread
Hilfe beim lesen von Daten
std_logic_vector(17 downto 0); begin process(rst,clk) begin if(rst = '1') then d_out_1 <= (others => '0'); w_out <= '0'; elsif (clk = '1') and clk'event then if (enable_w = '1' and full = '0') then w_out <= '1'; d_out_1 <= std_logic_vector
Ist der Resetimpuls lang genug? [pre] When reset is implemented, it is synchronized internally to the core with each respective clock domain for setting the internal logic of the FIFO to a known state. [/pre] BTW: bitte die VHDL Tags
-
Thread
Quartus II Clock
-- asynchronous reset (active low) -- s_10khzen <= '0'; -- s_enctr <= (others => '0'); -- elsif clk48'event and clk48 = '1' then -- rising clock edge -- -- Enable signal is inactive per default. -- s_10khzen <= '0'; -- if s_enctr /= C_ENCOUNTVAL then
the counter. -- s_enctr <= unsigned(s_enctr) + conv_unsigned(1,1); -- else -- When the terminal count is reached, set enable flag and reset the -- counter. -- s_enctr <= (others => '0'); -- s_10khzen <= '1'; -- end if; -- end if; --end process
-
Thread
Altera Fitter igoriert Constraint
addr ist der Eingang [vhdl] process(clk50, reset) begin if reset = '0' then addr_x <= (others => '0'); .... elsif rising_edge(clk50) then addr_x <= addr; ... end if; end process; [/vhdl] Ich habe leider schon öfter die Erfahrung gemacht, dass der Fitter von Altera
(Teil eines asnychronen Bus-Interface): [vhdl] -- Tristate the Output-Pin data <= rd_data_q when (OEn = '0' and CSn = '0') else (OTHERS => 'Z'); [/vhdl] Der virtuelle Takt für die externen Signale beträgt 200 Mhz und für den Pfad ist ein Multicycle von 3 constrained. SDC: create_clock
-
Thread
Elektronik-Stammtisch (Attraktor, Hamburg):FPGA/ PSHDL-Workshop
man braucht nicht für jeden Furz einen Prozess: -- Zähler mit asynchronem Reset reg <= (others=>'0') when reset='1' else reg+1 when rising_edge(clk); -- oder: Zähler mit synchronem Reset reg <= reg+1 and (reg'range=>(not reset)) when rising_edge(clk); end; [/vhdl] Fpga Kuechle
-
Thread
EMBEDDED SYSTEM
<= Idle; nr_of_reads <= 0; nr_of_writes <= 0; sum <= (others => '0'); else case state is when Idle => if (FSL_S_Exists = '1') then state <= Read_Inputs; nr_of_reads <= NUMBER_OF_INPUT_WORDS - 1; sum <= (others => '0'); end if; when Read_Inputs => if (FSL_S_Exists = '1') then -- Coprocessor function (Adding) happens here sum <= "
-
Thread
Bekomme Matlab-IIR-Lowpass nicht zum laufen. Timingprobleme?
since it's a logical AND between -- user_r_read_32_empty and has_been_full. has_been_full goes high when the -- FIFO is full, so it's guaranteed that user_r_read_32_empty is low when -- that happens. On the other hand, user_r_read_32_empty is a FIFO's empty -- signal, which naturally meets the requirement
delay_process_section1 : PROCESS (clk, reset) BEGIN IF reset = '1' THEN delay_section1 <= (OTHERS => (OTHERS => '0')); ELSIF clk'event AND clk = '1' THEN IF clk_enable = '1' THEN delay_section1(1) <= delay_section1(0); delay_section1(0) <= typeconvert1; END
-
Thread
Programmieren des LTC2287 Dual 10-Bit ADCs
begin if reset = '1' then enable_out <= '0'; Dout1 <= (others=>'0'); Dout2 <= (others=>'0'); elsif rising_edge (CLK) then Dout1 <= Real_in_from_ADC ; Dout2 <= imag_in_from_ADC;
recommended), use this command: set_property SEVERITY {Warning} [get_drc_checks UCIO-1]. NOTE: When using the Vivado Runs infrastructure (e.g. launch_runs Tcl command), add this command to a .tcl file and add that file as a pre-hook for write_bitstream step for the implementation run. Problem
-
Thread
Input als Array
std_logic := '0'; SIGNAL EN : std_logic := '0'; SIGNAL value : std_logic_vector(0 to 7) := (others=>'0'); --Outputs SIGNAL channel : std_logic_vector(7 downto 0); constant PERIOD : time := 40 ns; constant DUTY_CYCLE : real := 0.5; constant OFFSET : time := 0 ns; BEGIN
"00000000"; END LOOP; else if EN = '1' then case nstate is when STATE0 => channel_int <= "00000000"; value_help(0) <= value_help(0) + 1; if value_help(0) = "11111111" then channel_int(0) <= '0'; end if;
-
Thread
Xilinx ISE: output pad net 'locked_s' has an illegal load:
nun dieses Signal auf den Reset Zweig meines Designs zu geben. Hier der Code: [vhdl] rst_s <= '0' when locked_s = '0' else '1'; [/vhdl] In der Simulation läuft's, aber ISE schmeisst mir die folgende Fehlermeldung raus: ERROR:NgdBuild:462 - output pad net 'locked_s' drives multiple buffers:
warum bastelt das tool inverter in den resetpfad? (3) du kannst statt [vhdl] rst_s <= '0' when locked_s = '0' else '1'; [/vhdl] natürlich auch [vhdl] rst_s <= locked_s; [/vhdl] schreiben, falls die typen passen. (4) Legst du locked_s auch auf ein Ausgangspin des FPGA? vielleicht
-
Thread
Frage zu Cast
] constant c10ms : std_logic_vector(iReactDurS'high downto 0) := (3 downto 0 => "1010", others => '0'); [/vhdl] Du wirst übrigens ein Problem haben bzw. bekommen können, denn uneingeschränkte Vektoren haben die Zählrichtung (0 to x). Du kannst also durchaus Probleme bei der Zuweisung und
: unsigned(vector'high downto 0); begin var <= unsigned(vector); equal <= '1' when var = const else '0'; less <= '1' when var < const else '0'; greater <= '1' when var > const else '0'; end Behavioral; [/vhdl]
-
Thread
Akkutausch Bose Soundlink Mini (Zellen ersetzen)
I can confirm cut off old cell from bms not causing bms locked but you need cut in the rightway : when open box cut b+ , bm, b- when installed b- bm b+ , if you cut random it can cause bms locked For sure when install new cell let bms is free for 2-3 weeks Next problem : The bms for bose mini 1
want to discuss is that where in the bms can connect or read the data on the bms My experiment : when i replace battery first time the bms is not locked but when i reinstall the pack causing airleak and plug out battery and careless cut off wire random, cause bms locked so i have to buy a new one ,
-
Thread
VHDL timing in GMII auf Spartan6
ganzen asynchronen kombinatorischen Resets raus: [vhdl] if counterrx="000" then countertx<=(others=>'0'); : if state_txout = start then tx_paket <= '0'; : [/vhdl] Als Beispiel: countertx glitcht /garantiert/ beim zählen. Und was, wenn der Zähler beim Übergang von 1 nach
Welche Warnungen bekommst du eigentlich für diesen Taktmultiplexer? [vhdl] ether_clk <= phy_rx_clk when gmii_active = '1' else PHY_TX_CLK; [/vhdl] Und ich bin mir gar nicht so sicher, das es die Timing Constraints da drüber schaffen. Du solltest für so eine Taktumschaltung den Taktmanager verwenden.
-
Thread
Case in Top-Entity
folgende Fehlermeldungen raus: Line 98. parse error, unexpected CASE Line 111. parse error, unexpected WHEN Line 122. parse error, unexpected CASE, expecting SEMICOLON Für mich sieht es danach aus, dass die Case- Anweisung an einem falschen Platz innerhalb der Entity steht, bloß weiß ich nicht wo sie
component; for RTC for CAN for MST_AMBA begin Selekt:Process (SLV_SEL) case SLV_SEL is when "000" => --RTC ... when others => --CAN- Controller ... end case; end process selekt; -- RTC - Port Map RTC_test: rtc... ) port map (... ); -- CAN - Port
-
Thread
check columns in a matrix
begin for i in 0 to 7 loop if unsigned(matrix(0 to 7)(i)) > 1 then matrix(0 to 7)(i) <= (others => '0'); end if; end loop; end process control;
funtionality: [vhdl] control : process(matrix) begin for i in 0 to 7 loop matrix(0 to 7)(i) <= (others => '0'); end loop; end process control; [/vhdl]
-
Thread
SPI-Modul(VHDL).bitte um Rat
case State is when Idle => if Ready_i = '1' then SS_o <= '0'; -- Select Slave aktive State <= Data_Transfer; -- Change state else State <=
end if; when Stop => SS_o <= '1'; -- Deselect slave end case; end if; end process; end rtl; [/vhdl]
-
Thread
HMCAD1511 Interface
Byte_Serdes_FCLK; end process; with TwoByte_Serdes_FCLK(7 downto 0) select Shift_val <= 0 when "00001111", 1 when "00011110", 2 when "00111100", 3 when "01111000", 4 when "11110000", 5 when "11100001", 6 when "11000011", 7 when others; Data_shift_0 <= TwoByte_Serdes_0(
connected to all other elements in the circuit. For proper functionality, io_reset has to be deasserted when the clocks to SERDES are stable. Due to this requirement, io_reset must be deasserted after some cycles of clk_reset deassertion. For 8:1 serialization, sixteen cycles delay of I/O clock between
-
Thread
Subtraktionsglied mit "Borrow Out"
end if; end process; to_subst <= signed(not(din(din'high)) & din(din'high-1 downto 0)) when DIN_USGND='1' else signed(din); to_adder <= to_subst - accu_msb; accu_next<= to_adder + accu_reg; dout <= std_logic_vector(to_adder); end RTL; [/vhdl]
<= to_signed(to_integer(to_subst) - to_integer(accu_msb), subst_wc'length); to_adder <= C_MAXINT when subst_wc(subst_wc'high downto subst_wc'high-1) = "01" else C_MININT when subst_wc(subst_wc'high downto subst_wc'high-1) = "10" else subst_wc(subst_wc'high) & subst_wc(subst_wc'high
-
Thread
Wittig(welec) DSO W20xxA Open Source Firmware (Teil3) Gesperrt
of the screen. Anyway I think it is more of a philosophy question that other thing because then when I use my W2022A I have no big problem. So I agree also with Rainer W. when he write: Rainer W. schrieb: >Eigentlich gibt es zwei verschiedene Bedienphilosophien zwischen denen >man umschalten
some spike I say. These glitches are present regardless of the type of filter inserted and also when no filter is inserted, please look at my screenshoot. This is also observed by others? I could be wrong but I never noticed them before now but at the same time I think I read here something about
-
Thread
Zu wenig Makrozellen: Code Optimierung
Zwischensignale erzeugt, die einem das Timing versauen können. [vhdl] case clockCounter is when "00001" => sineOut <= "00001000"; .... when others => sineOut <= "00000000"; end case; [/vhdl] Jörg
-
Thread
State Machine mit "Unterroutinen"
my_register : STD_LOGIC_VECTOR(2 downto 0); ... with my_state select my_register <= "001" when IDLE, "101" when DO_THIS, "110" when DO_THAT, "000" when others; [/vhdl] > WebISE 13.1 Was soll eigentlich WebISE sein? Ich kenne nur das
-
Thread
Mr.MidiPlayer - Spielt alle MIDI-Dateien von einer SD-Karte
unicode as ASCII :-) I will implement a japanese char mapper for the kana (unicode high byte 0x30) when I get the time!
Hello Simon, and others who read this. First I want to thank you and the other contibutors for making this available! I am buzy building a MrMidi2 board for my barrelorgan. Because of the fact that I want to make use
-
Thread
Select auf fallende und steigende Flanke
begin wait until rising_edge(clk); data_sr <= data_sr(0) & data; case (data_sr) is when "01" => -- Steigende Flanke ... when "10" => -- Fallende Flanke ... when others => -- keine Flanke null; end case; end process; [/vhdl]
-
Thread
BMA020 Beschleunigungssensor über SPI auslesen
die Verbindung zum ATMega: [c]void SPI_MasterInit(void) { /* Set MOSI and SCK output, all others input */ DDR_SPI |= (1<<DD_MOSI)|(1<<DD_SCK); /* Enable SPI, Master, set clock rate fck/16 */ SPCR = (1<<SPE)|(1<<MSTR)|(1<<SPR0); } void SPI_MasterTransmit(char cData) { /* Start
LSB are read out. This avoids a potential mixing of LSB and MSB of successive conversion cycles. When this bit (address 15h, bit 3) is at 1, the blocking procedure for MSB is not realized and MSB only reading is possible.
-
Thread
Kann mir jemand helfen und etwas zu meinen Warnungen der ISE 9.2.04i sagen? Bin Ratlos.
Tristate-Buffer können einfach so im VHDL-Text beschrieben werden: [vhdl] input <= pins; pins <= output when richtung='1' else (others=>'z'); [/vhdl] Beim CLK hast du ja auch keinen CLK-Buffer eingefügt... Du solltest keine so langen if-elsif-Konstrukte beschreiben. Das sind hintereinandergeschaltete
Constraint (CLK=33ns) nur für die FFS angewendet wird. Eine kleine Schreiberleichterung: > when B"1110" ist genau gleich wie > when "1110" Der Prefix B ist default.
-
Thread
Vector mit einem ENABLE Signal verUNDen
dann soll der Vektor "00...00" sein? Dann geht es so: [vhdl] Ausgangsvektor <= Eingangsvektor when DasSignal = '1' else "000000000"; [/vhdl]
#1801142: > Da muss man dann auch keine Nullen abzählen. [vhdl] Ausgangsvektor <= Eingangsvektor when DasSignal = '1' else (others => '0'); [/vhdl] So auch nicht. :)
-
Thread
Thermomix Rezeptchips
> I created a small Linux shell script named tm5.sh (see attachment) that >> might be useful to others. To use it: > > Well done! > > On my side, I'm stuck. > It seems that when netlink is called (because a recipe chip has been > attached), the stick has already been read and netlink check
> I created a small Linux shell script named tm5.sh (see attachment) that >> might be useful to others. To use it: > > Well done! > > On my side, I'm stuck. > It seems that when netlink is called (because a recipe chip has been > attached), the stick has already been read and netlink check
-
Thread
Qt for MCUs: Grafiktoolkit für Mikrocontroller
www.qt.io/download steht: "Rights & Obligations - An obligation to share changes to Qt source code “When we speak of free software, we are referring to freedom, not price (… ) To protect your rights, we need to prevent others from denying you these rights or asking you to surrender the rights. Therefore
devices For Digital Rights Management please see: FAQ Special consideration should be taken when attempting to enforce software patents" Dh. der Nutzer muß die Software gegen neue Qt libs linken können. Und was mit 'Must make “open” consumer devices' gemeint ist wüßte ich dann auch gerne.
-
Thread
Textanalyse mit VHDL?!
readline(IN_DATA,LINE); read(LINE, marker); case marker is when 'S' => read (LINE, SATZ); stimuli <= SATZ; when '#' => -- process comment when others => null;
-
Thread
State Machine startet ohne Event
rising_edge(sys_clk) then ready <= ready_falling_s; case stm_eeprom_wrap is when eeprom_idle => if read_mode_i /= Idle_e then start_write_s <= '1'; stm_eeprom_wrap <= eeprom_send_slave_adr_read; else start_write_s
stm_eeprom_wrap <= eeprom_ack_poll; end if; . . . when others => null; end case; end if; [/vhdl] Wenn ich dann dem Signal read_mode_i z.B. RandomRead_e zuweise (also read_mode_i /= Idle_e), sollte die Statemachine eigentlich über
-
Thread
multi-cycle aber nicht für einen path sondern ein signal angeben
Sprich sowas wie: if Simulation = '1' then signal Reg_Write_Timeout: unsigned(10 downto 0):=(others => '0'); else signal Reg_Write_Timeout: unsigned(16 downto 0):=(others => '0'); end if; Gibt es so eine Möglichkeit?
damit Sicherheit. In den Eröterungen zu DO-254 findet sich dazu: "Dead code can be detrimental when a design is reused and the dead code is inadvertently activated during the code base port. Dead code effects on safety-critical design assurance is not predictable nor insured to be consistent across
-
Thread
[VHDL] Komplexität von Prozessen
counter_process : process(clk50mhz, reset_n) begin if reset_n = '0' then r_counter <= (others => '0'); elsif rising_edge(clk50mhz) then r_counter <= r_counter + 1; end if; end process; valid_process : process(clk50mhz, reset_n) begin if reset_n = '0' then
else valid <= '1'; end if; if reset_n = '0' then r_counter <= (others => '0'); end if; end process;[/vhdl]
-
Thread
Top-down-Entwurf: umdenken lernen (für Softwerker)?
wait until rising_edge(clk); if wr = '1' then case id_port is when x"00" => led <= output_port; when x"01" => pwm_compare <= output_port; when others => null; end case;
Problem des gleichzeitigen Schreibzugriffs auf den globalen Speicher gelöst. [vhdl]Dout <= D0 when Addresse = '0' else D1;[/vhdl] Die Anzahl der Eingabegeräte kann man natürlich auch noch beliebig erhöhen mit nur kleinen Änderungen am Mux.
-
Thread
XST und File I/O
for i in RESULT'range loop --- 'RANGE case xs(i) is when '0' | 'L' => RESULT(i):='0'; when '1' | 'H' => RESULT(i):='1'; when others => bad_element := TRUE; end case; end loop; if bad_element then assert NO_WARNING
-
Thread
Verbindung mit Component von Grafikentwurf zum VHDL
Schau dir bitte mal die rs232_rx.vhd ganz unten an: when ready => rx_data <= rxsr; rx_state <= idle; rx_en <= '1'; end case; Ich möchte gerne erst die Daten an die LED geben, wenn ich geprüft habe ob rx_en <='1' ist.
); end mux; architecture behv1 of mux is begin process(i0,s) begin case s is when "0" => x <= i0; when "1" => x <= "11111111"; when others => x <= "ZZZZZZZZ"; end case; end process; end behv1; ----------------------------------------
-
Thread
Gyroskopsteuerung
yaw/pitch/roll container and gravity vector // relative ypr[x] usage based on sensor orientation when mounted, e.g. ypr[PITCH] #define PITCH 1 // defines the position within ypr[x] variable for PITCH; may vary due to sensor orientation when mounted #define ROLL 2 // defines the position within ypr[x] variable for ROLL; may vary due to sensor orientation when mounted #define YAW 0 // defines the position within ypr[x] variable for YAW; may vary due to sensor orientation when mounted // ===========================================================
-
Thread
Takt abschalten bzw. unterbrechen mit dem Spartan II E
begin if (CLK_IN'event and CLK_IN = '1') then case W_CLK_DLX_EN is when '1' => W_CLK_DLX <= CLK_IN; when others => W_CLK_DLX <= '0'; end case; end if; end process; -- buf_clk Ich weiß, so Zeug sollte man schon wg. des Clock-Skews nicht machen
-
Thread
BlackRAM mit generate vervielfachen
std_logic_vector(15 downto 0); variable INT: integer range 0 to 15; begin ENABLE_VAR := (others => '0'); INT := conv_integer(HADR); ENABLE_VAR(INT) := '1'; ENABLE <= ENABLE_VAR; end process Decoder; -- <-----Cut code below this line and paste into the architecture body---->
hat der Spartan2 aber interne Tristate-Puffer. Die kannst Du wie folgt benutzen: DOUT_TS <= DOUT when OE = '0' else (others => 'Z'); Die Tristate-Ausgänge können dann problemlos parallelgeschaltet werden. ciao, Stefan.
-
Thread
VHDL FSM
WHEN starting => IF (engine = '1') THEN nextfsmstate <= starting; ELSE nextfsmstate <= stop; END IF; detection <= '1'; WHEN OTHERS => detection <= '0'; END CASE; END PROCESS ; END myEntityArch; Danke