Home    Bloggers    Messages    Webinars    Resources   
Tw  |  Fb  |  In  |  Rss
Duane Benson

Discovering FPGAs: Playing With LEDs & Switches

Duane Benson
Page 1 / 2 Next >
<<   <   Page 2 / 7   >   >>
Duane Benson
Duane Benson
7/30/2012 2:04:38 PM
User Rank
Blogger
Communications
This has been a very interesting discussion around RS232. I expect that conceptially it will help with the implementation of a few other protocols that I'll need to figure out at some point.

50%
50%
SimonC
SimonC
7/30/2012 9:00:11 AM
User Rank
Beginner
Re: RS 232 and LEDS
Very interesting code. Just assigned some LEDs as output and tested it. Works very good ;)

I'll keep in mind that a testbench is indeed a powerfull tool to check your design. I didn't use it that much untill now.

Would I be able to use the same principles to light some LEDs with a keyboard on my FPGA?

grtz,

Simon

50%
50%
SimonC
SimonC
7/28/2012 6:28:13 AM
User Rank
Beginner
Re: RS 232 and LEDS
Thanks mate

50%
50%
Adam Taylor
Adam Taylor
7/28/2012 5:54:58 AM
User Rank
Blogger
Re: RS 232 and LEDS
Simon

If you have a 33MHz clock the period of it is 30.3 ns. At a baud rate of 9600 the bit period is 104 us. 

Thus the number of clocks within a bit period is 104 us / 30.3 ns = 3432 clocks 

if you have any other questions you have my email address so feel free to use it

Hope this helps

Adam

50%
50%
SimonC
SimonC
7/28/2012 5:40:30 AM
User Rank
Beginner
Re: RS 232 and LEDS
Thanks,

I have a little question about the code, Adam.

If I understand the code right, the bit_period variable is the number of clockcounts in a bit of 'rx', right? What would you suggest for a 33 MHz clock input in a 9600 bits per second 'rx' input? I would take 3437 counts/bit.

50%
50%
Adam Taylor
Adam Taylor
7/27/2012 11:24:57 AM
User Rank
Blogger
Re: RS 232 and LEDS
Just sent you the test bench as well 

50%
50%
SimonC
SimonC
7/27/2012 11:19:56 AM
User Rank
Beginner
Re: RS 232 and LEDS
Thanks Adam and Max. I hope it's not too complicated ;)

50%
50%
SimonC
SimonC
7/27/2012 11:19:54 AM
User Rank
Beginner
Re: RS 232 and LEDS
Thanks Adam and Max. I hope it's not too complicated ;)

50%
50%
Max Maxfield
Max Maxfield
7/27/2012 11:16:32 AM
User Rank
Blogger
Re: RS 232 and LEDS
@Adam: I've forwarded it to Simon -- cheers -- Max

50%
50%
SimonC
SimonC
7/27/2012 11:04:42 AM
User Rank
Beginner
Re: RS 232 and LEDS
Hi, sorry, was afk for a while

here it is: simonvandenberge@hotmail.be

 

thanks a lot ;)

50%
50%
<<   <   Page 2 / 7   >   >>
More Blogs from Duane Benson
Now it's time to delve deeper into the state machine I'm using to control my I2C interface.
The three states associated with bi-directional "inout" pins can cause confusion for the unwary.
It's time to jump into unexplored territory -- the state machine that will control Duane Benson's I2C interface.
We're now ready for the I2C master to transmit a command set to a remote device.
Duane Benson has his SPI interface working. At some point, he'll want to rewrite the Verilog code, but first he wants to get the I2C interface up and running.
flash poll
follow us on twitter
follow Xilinx on twitter
like us on facebook
like Xilinx on facebook
All Programmable Planet     About Us     Contact Us     Help     Register     Twitter     Facebook     RSS