Skip to content

Fixed interrupt handler in serial_api.c for the Nordic NRF51. The last b... #1047

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Apr 20, 2015
Merged

Fixed interrupt handler in serial_api.c for the Nordic NRF51. The last b... #1047

merged 1 commit into from
Apr 20, 2015

Conversation

marcuschangarm
Copy link
Contributor

...yte sent in a sequence would not correctly clear the interrupt flag.

…t byte sent in a sequence would not correctly clear the interrupt flag.
@sg-
Copy link
Contributor

sg- commented Apr 16, 2015

Can you provide an example showing how this was failing?

@anpilog
Copy link
Contributor

anpilog commented Apr 17, 2015

FYI:
I had similar issue with NRF51. My fix was pretty similar as well.
Unfortunately I don't remember test case for that 8(

@marcuschangarm
Copy link
Contributor Author

The example app below crashes immediately if the fix is not applied:

http://developer.mbed.org/users/marcuschang/code/AsyncSerialTest/

0xc0170 added a commit that referenced this pull request Apr 20, 2015
Fixed interrupt handler in serial_api.c for the Nordic NRF51
@0xc0170 0xc0170 merged commit 41824de into ARMmbed:master Apr 20, 2015
@sg-
Copy link
Contributor

sg- commented Apr 21, 2015

This patch breaks other implementations of the TX irq handler such as: https://developer.mbed.org/users/sam_grove/code/BufferedSerial/

There are also a lot of FSL targets in which the TX DR irq in an empty state always fire since its 'ready' and the programmers model is to disable this when a buffer is empty. I think the API should be defined so we can write complimentary libraries in a common way or bring buffered transactions into the mbed SDK.

@marcuschangarm
Copy link
Contributor Author

Sam, I looked at the BufferedSerial and I like your solution better, so I'm withdrawing this pull request.

Regarding the TX always firing, I get different behavior on the Nordic NRF51 depending on whether I have the Bluetooth enabled or not, i.e., interrupts only fire once without BLE.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants