- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi, please I am a beginner in Verilog and Altera FPGAs and I want to implement a lab on FPGA based PID controllers for DC Motor position control.
Please I want to be able to display the P and I gains (both are 4 bits wide)as it is varied from switches, to display the value of the final error which is 8 bit and then to display the value of angle as gotten from quadrature encoder. The other parts of the Verilog code are ready, it only remains to display those parameters on 7 segment displays. Please, how do I write codes that will display the parameters independently? I can supply the other codes on request. ThanksLink Copied
1 Reply
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi
while I'm not into Verilog (doing VHDL), I think the basic approach is identical... You need to have some "lookup" to define which segments need to be activated depending on the number to be shown. In VHDL this might be a case seg1 is when "1" => "0000110" when "2" => "1011011" ... The "problem" is a direct conversion of the byte of the number to the seven segement will show the values as hexadecimals... Otherwise - if e.g. "13" should be "1" "3" and not "0" "D" you first have to convert hexadecimals to binary coded decimals...
Reply
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page