The angle about antenna can convert into pulse in the encoder by transforming light into voltage. FPGA receives A、 B、 Z pulse which the encoder exports and collects the angle. According to the character of the A、 B pulse, create the signal of direction and pulse by detecting the A、 B pulse and the FSM. The method avoids the influence of the interference pulse and the dithering; The reversible counter achieves accumulation about the pulse; A parallel-to-serial converter capable of communicating with serial port is designed; The latch makes the data conversion correct. The anti-interference proves to be high by the simulation.%利用编码器的光电信号转换功能,能够将天线角度信息转换为脉冲信号;编码器输出A、B、Z三相脉冲信号,用FPGA对三相信号进行接收,实现角度信息的采集;根据A、B相脉冲的特点,通过检测A、B相信号的电平变化,采用有限状态机的方法,产生辨向信号和计数脉冲信号,这种方法克服了由于脉冲干扰和天线抖动带来的影响;通过设计可逆计数器,实现对脉冲的积累计数;同时设计能够与串口进行通信的并行-串行数据转换电路,便于进行数据处理;设计锁存器,保证数据转换不发生错误;仿真结果证明电路有较强的抗干扰性.
展开▼