Problem with Flag Output of UART RX Block

Create new topics, add your comment, remark, bugs...
shatteredmaul
Posts: 2
Joined: Wed Dec 14, 2011 9:54 pm

Problem with Flag Output of UART RX Block

Postby shatteredmaul » Wed Dec 14, 2011 10:23 pm

My Build Environment:
MATLAB R2011a
Block Set Version 3.5b

My Application:
I'm using the block set with a dsPIC33. I'm streaming ADC samples over UART1. You could call it a low speed oscilloscope. Each sample is encoded to a 5 character frame which is packed with a Vector Concatenate block and transmitted with the UART TX block. Because I'm sampling in the neighborhood of 100Hz, the TX block gets executed very frequently. The baud rate is set to 115200 and the simulation step size is set to 500us.
The application is also designed to receive commands which is accomplished with a UART RX block. I use the Flag output to indicate that a new character has been received and needs to be processed.

My Problem:
The encoded samples are being transmitted without issue over UART1. However, I'm having trouble getting UART1 to receive data reliably once the UART TX block starts being executed frequently. I've tied the Flag output from the UART RX block to a digital output and sampled it with an oscilloscope. When the UART TX block is being executed frequently, the Flag output doesn't go high. I've tried using and not using RX and TX interrupts. However, the problem persists whether or not interrupts are used. Are there any known caveats with executing the UART TX block frequently, or am I simply doing something wrong?

I'd be enormously grateful for any help the community could render and will gladly contribute back in the near future!

LubinKerhuel
Site Admin - Expert
Posts: 616
Joined: Wed Mar 07, 2007 11:23 pm
Location: Marseille - France
Contact:

Re: Problem with Flag Output of UART RX Block

Postby LubinKerhuel » Thu Dec 15, 2011 9:12 am

Hello,

There is no know caveeats until now.
Your description is very clear, thanks for it.
Would it be possible to upload your model on the forum (or an equivalent model creating that problem) ? It will help to find out what's going on.

Thanks,
Lubin

shatteredmaul
Posts: 2
Joined: Wed Dec 14, 2011 9:54 pm

Re: Problem with Flag Output of UART RX Block

Postby shatteredmaul » Mon Dec 19, 2011 9:54 pm

Thanks for your response. For the time being, I'm going to implement a workaround to my problem. At some point in the near future I'm going to upload a version of the model so we can find out what the problem was. :)

Matt

palacio
Posts: 1
Joined: Sat Mar 10, 2012 7:52 am

Re: Problem with Flag Output of UART RX Block

Postby palacio » Mon Mar 12, 2012 11:48 am

I want to know about FPGA implementation of UART? Hi, I have to give a seminar on Field Programmable Graphic Array Implementation Of UART. Please any one can help regarding this.I dont have any material for this. Thanks in advance.
___________________________
yahoo keyword tool ~ overture ~ traffic estimator ~ adwords traffic estimator


Return to “General Remark and Questions”

Who is online

Users browsing this forum: No registered users and 2 guests