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

Error in IR example for CPX #2801

Open
bradanlane opened this issue May 2, 2024 · 2 comments
Open

Error in IR example for CPX #2801

bradanlane opened this issue May 2, 2024 · 2 comments

Comments

@bradanlane
Copy link
Contributor

In the learning guide for the Circuit Playground Express, IR CPX to CPX example, the code has the following:

encoder = adafruit_irremote.GenericTransmit(header=[9500, 4500], one=[550, 550], zero=[550, 1700], trail=0)

However, the sample code from adafruilt_irremote.py has the following:

encoder = adafruit_irremote.GenericTransmit(header=[9000, 4500], one=[560, 1700], zero=[560, 560], trail=560)

The CPX example results in the receive data being the 1s compliment of the send data.

@bradanlane bradanlane changed the title Error in IR example for CPI Error in IR example for CPX May 3, 2024
@dhalbert
Copy link
Contributor

dhalbert commented May 4, 2024

Could you submit a PR for this? Thanks. That would be the easiest way to make sure it's corrected properly.

@bradanlane
Copy link
Contributor Author

OK, I forked the learning guides and went to make the change and found the same error in four different guides.

This has caused me to be concerned. I can only assume one of three possible situations:

  1. those guides were not tested (seems unlikely)
  2. those guides somehow work but only with themselves (i.e. they somehow have the reciprocal error of the receive ... but I could not find that to be the case)
  3. something has changed since those guides were written (most are 2+ years old)

I am happy to submit the pull request but I would like another set of eyes to scrutinize the changed code. I do not have a Circuit Playground Express on hand and do not have the irRobotControl board(s).

I performed my testing using a Raspberry Pi PICO and the Adafruit IR Receiver board and IR Emitter board.

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