Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

UART on FPGA (Spartan 3E)

Status
Not open for further replies.

electrobuz

Member level 2
Joined
May 20, 2013
Messages
46
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,286
Activity points
1,638
I have to connect a Microcontroller (Atmega 16) to an FPGA (Nexys 2 Spartan 3E) using UART. How are the connections to be made? Do I need to use a voltage converter IC (for 3.3V to 5V) or I can directly connect the RX,TX pins of the Atmega 16 to the 9 Pin connector of the FPGA.

Thanks
 

you have not told any detail here..but microcontrollers (in genral) are not uart protocol supported so MAX232 IC is the most famous for protocol conversion. What do you have on the FPGA side also important, if you can share detail may be we can tell somethign
 

What voltage Atmega16 is running? If you can choose voltage for it, use for example 3.3v and no voltage conversion needed. If it is running 5v, you can do 5v->3v with two resistors. (voltage divider). You can check datasheets if it is possible to connect 3.3v output directly to 5v input. Is 3.3v high level high enough to 5v input read as 1? If not some level conversion is needed. You can do inverting level conversion with one transistor and few resistors(and handle inversion in FPGA). Or use real level coverter IC.
 

What voltage Atmega16 is running? If you can choose voltage for it, use for example 3.3v and no voltage conversion needed. If it is running 5v, you can do 5v->3v with two resistors. (voltage divider). You can check datasheets if it is possible to connect 3.3v output directly to 5v input. Is 3.3v high level high enough to 5v input read as 1? If not some level conversion is needed. You can do inverting level conversion with one transistor and few resistors(and handle inversion in FPGA). Or use real level coverter IC.

The Atmega runs at 5V. So I will apply voltage conversion to the two lines RxD and TxD and connect them to the microcontroller. Nothing else is required right?
 

Atmega 16 to the 9 Pin connector of the FPGA

I am sorry. Totally missed the part that you are going to use D9 connector on your Nexys 2 board.(I was thinking direct connection FPGA IO pins) I looked at Nexys manual and it does have RS-232 level converter. So D9 is standard RS-232 port. You must use TTL to RS-232 converter, something like max232. See **broken link removed**. D9 on left to your Nexys, JP1 to atmega 16. Remember to cross over RX and TX. If you are planning to use hardware flow control, CTS and RTS signals must also routed.
 
Last edited:

Yes it does have a level converter (ST3232). So I can directly connect the TxD and RxD on the 9 Pin (everything else is left as it is) to the RxD and TxD of the micrcontroller?
 

Status
Not open for further replies.

Similar threads

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top