作者jason543 (时间的眼泪)
看板Electronics
标题[问题] vhdl要如何表示负1
时间Thu Nov 20 15:35:44 2008
现在小弟想要写BPSK一个小程式~
输入端是0.1 输出是+1.-1
现在1->(+1)没问题 可是不知道要怎麽要让程式把0->(-1)
entity bpsk is
port (
clk : IN STD_LOGIC;
reset : IN STD_LOGIC;
BPSK_IN : IN STD_LOGIC;
Modulation_Iaxis_out : OUT STD_LOGIC;
Modulation_Qaxis_out : OUT STD_LOGIC
);
end bpsk;
architecture Behavioral of bpsk is
begin
process (clk,reset)
begin
if (reset = '0') then
Modulation_Iaxis_out <= '0' ;
Modulation_Qaxis_out <= '0' ;
elsif ( reset = '1' and clk 'event and clk = '0') then
Modulation_Iaxis_out <= BPSK_IN;
Modulation_Qaxis_out<= '0';
end if;
end process;
end Behavioral;
这是我自己写的CODE
请版上的高手帮帮忙吧 谢谢喔
补充一点 因为我是用MATLAB来跑XILINX的BLOCK
所以要设 I 跟 Q 轴 不然後面接的SCOPE没办法跑
--
※ 发信站: 批踢踢实业坊(ptt.cc)
◆ From: 140.126.131.62
1F:推 mouein:先弄清楚浮点数跟有号数表示方式! K一下计算机组织吧! 11/20 22:22