Skip to content
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

TX_DONE interrupt not firing. #44

Open
Cightline opened this issue Jun 10, 2021 · 4 comments
Open

TX_DONE interrupt not firing. #44

Cightline opened this issue Jun 10, 2021 · 4 comments

Comments

@Cightline
Copy link

Cightline commented Jun 10, 2021

I can't seem to get the TX_DONE interrupt to fire, however the RX_DONE interrupt works fine.

My code currently operates like so:

  1. Send a packet
  2. TX_DONE interrupt should fire, but it doesn't, I currently have to poll.
  3. Receive a packet
  4. RX_DONE interrupt fires, no polling needed.
  5. I can check the bit flags and see that both TX_DONE and RX_DONE are set, I've messed around with the IRQ bit flags but haven't had success.

I'm using RTIC and embedded-hal/atsamd-hal. The code is here

@ryankurte
Copy link
Member

ryankurte commented Jun 10, 2021

I take it this is via the DIO0 pin? To receive both it looks like you'll need to switch the DIO0 mapping in RegDioMapping1 from RxDone (0b00) to TxDone (0b01) between operations (after enabling RxReady and/or TxReady IRQs in RegIrqFlags1).

(It'd be neat to have an API for this in the driver if there's a reasonable way of representing it)

image

image

(from the datasheet here

@Cightline
Copy link
Author

Very helpful response, and yeah it's DIO0 pin, I'll try out what you wrote and bring the results back here so we can potentially figure out an API.

@Cightline
Copy link
Author

Busy with IRL stuff, I recommend leaving this open but it may be months before I'm able to address it.

@ryankurte
Copy link
Member

yeah no stress, useful to leave it open for whomsoever gets to it first ^_^

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

No branches or pull requests

2 participants