Interrupt during serial transmission

06 Oct 2012

Hey there!

So I am currently working on a project that involves serial communication to other devices. We also have a few ticker interrupts set up to poll various sensors every so often.

What sort of behavior should I expect from the mbed if we are transmitting over serial at the same time as an interrupt is triggered? Will the serial communications be stopped mid-flow (with potential corruption of data)? Or will the mbed finish transmitting before jumping to the interrupt routing?

10 Oct 2012

Hi, Herry,

I have got the same question. Samilar project as you had, I have USB/serial communicaiton to PC and flickers. Sometimes, my PC receives unrecognised strange letters from mBed.

Anybody have idea? Really appreciated.

Grey   wrote:

Hey there!

So I am currently working on a project that involves serial communication to other devices. We also have a few ticker interrupts set up to poll various sensors every so often.

What sort of behavior should I expect from the mbed if we are transmitting over serial at the same time as an interrupt is triggered? Will the serial communications be stopped mid-flow (with potential corruption of data)? Or will the mbed finish transmitting before jumping to the interrupt routing?

10 Oct 2012

Shouldn't be a problem, the LPC sends from an internal buffer, if due to other interrupt handling that buffers runs empty before the new data can be placed in it, there will be a pause in sending of characters, but it will not stop halfway a character.