Operácie

Schaeffler FPGA

Z SensorWiki

Verzia z 08:57, 27. november 2023, ktorú vytvoril Admin (diskusia | príspevky)

Takto sa sem píše obyčajný text.

Takto tučný, takto kurzíva.

Linky:


Obrázok vložíš takto:

 Súbor:FPGAchip.jpg  

všimni si, že je nektívny a treba ho potom nahrať kliknutím na odkaz.

Takto sa vkladajú zdrojáky:

 Q <= tmp;
 QBAR <= not tmp;
library ieee;
use ieee. std_logic_1164.all;
use ieee. std_logic_arith.all;
use ieee. std_logic_unsigned.all;
 
entity SR_FF is
  PORT( S,R,CLOCK: in std_logic;
  Q, QBAR: out std_logic);
end SR_FF;
 
Architecture behavioral of SR_FF is

begin
 PROCESS(CLOCK)
 variable tmp: std_logic;
 begin
  if(CLOCK='1' and CLOCK'EVENT) then
  if(S='0' and R='0')then
  tmp:=tmp;
  elsif(S='1' and R='1')then
  tmp:='Z';
  elsif(S='0' and R='1')then
  tmp:='0';
  else
  tmp:='1';
  end if;
  end if;

  Q <= tmp;
  QBAR <= not tmp;

end PROCESS;

end behavioral;
from microbit import *

uart.init(baudrate=115200, bits=8, parity=None, stop=1)

while True:
    accX = accelerometer.get_x()
    
    uart.write('%d\r\n' % (accX))

    sleep(100)
    display.set_pixel(1,1,5)
    sleep(100)
    display.set_pixel(1,1,0)



A takto kľučové slová