Forum Discussion
Altera_Forum
Honored Contributor
15 years agohow to send/recieve 32bit int via UART
Hi, i have a question what would be the best way to transfer 32-bit integers using UART in nios? I've allready made a simple nios design with uart connected to on-chip memory. I wrote a base ...
Altera_Forum
Honored Contributor
15 years agoI would be wary about sending binary data over a uart connection. The system software at the host end might act on some byte values (eg for flow control).
It you are sending 32bit data you also need to be aware of the endianness of the data - do you send the least or most significant 8 bits first. You also might want to use a simple data encapsulation protocol so that the reciever knows what data is being sent, and to allow additional requests to be added later.