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

pipe 1 does not need dynamic payloads enabled to transmit ACK payloads #653

Closed
2bndy5 opened this issue Oct 18, 2020 · 1 comment
Closed
Assignees

Comments

@2bndy5
Copy link
Member

2bndy5 commented Oct 18, 2020

The following line of code from enableAckPayload() is a bit erroneous.

write_register(DYNPD, read_register(DYNPD) | _BV(DPL_P1) | _BV(DPL_P0))

should be changed to

write_register(DYNPD, read_register(DYNPD) | _BV(DPL_P0))

Because enabling the dynamic payloads feature on pipe 1 is not needed to transmit ACK payloads, the configuration of pipe 1 should be left up to the user in this context. Of course, the examples should demonstrate proper pipe usage rather than letting the library hide (& probably confuse people about) the requirement to enable the dynamic payloads feature for pipes using ACK payloads in RX mode.

Examples/tests affected:

  1. GettingStarted_CallResponse.ino (from "examples/GettingStarted_CallResponse" folder)
  2. pingpair_ack.ino (from "examples/pingpair_ack" folder)
  3. pingpair_irq.ino (from "examples/pingpair_irq" folder)
  4. gettingstarted_call_response.cpp (from "examples_linux" folder)
  5. gettingstarted_call_response_int.cpp (from "examples_linux/interrupts" folder)
  6. gettingstarted_call_response_int2.cpp (from "examples_linux/interrupts" folder)
  7. pingpair_test.pde (from "tests/native" folder)
  8. pingpair_irq.pde (from "tests/pingpair_test" folder)

The note about this line of code in the docs should also be amended accordingly.

@2bndy5
Copy link
Member Author

2bndy5 commented Oct 18, 2020

a bit erroneous.

I inadvertently made a pun! 😄

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

1 participant