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

Help with send ir command #9

Open
dantederrico opened this issue Feb 4, 2025 · 11 comments
Open

Help with send ir command #9

dantederrico opened this issue Feb 4, 2025 · 11 comments

Comments

@dantederrico
Copy link

hi, I have a problem with PiIR. I'm trying to copy the ir codes of a tv remote control and transmit them with raspberry. When I launch the command to record I can store the codes in the .json file but when I have to send them it doesn't transmit anything. I wanted to ask you if it is necessary to change something in the config.txt file (dtoverlay) or if it is not necessary. My configuration is the following: - - Raspberry Pi 2B bullseye

  • ir board ENER314-IR image

Thank you very much and I hope you can help me 😊

@ts1
Copy link
Owner

ts1 commented Feb 5, 2025

I don't think config.txt or other settings is necessary.

  • Make sure your GPIO number is correct
  • Use phone camera or something to see if the IR LED is flashing (on iPhone only selfie camera can see IR)
  • Try LIRC or other project - if it works, and PiIR doesn't, report me again

@dantederrico
Copy link
Author

I prefer to use PiIR because unlike Lirc it has less configurations to do. However in the past it worked I don't know what could have happened. Now I tried to install Buster on Raspberry pi 2b. From the setting in the photo I don't have to change anything? I would like to use PiIR possibly.image

@ts1
Copy link
Owner

ts1 commented Feb 5, 2025

I don't know about gpio-ir. Maybe it's a LIRC thing?
PiIR doesn't need these either.

@dantederrico
Copy link
Author

Hi Takeshi
I still can't transmit the IR codes of my TV remote control. I can store them in the json file but when I go to send them nothing happens. The LED on the transmitter card lights up and is therefore driven but I'm not sure if the LED transmits. I tried using a camera to see but nothing happens. I currently have raspberry pi 3B+ with bulleseye. Ir receiver connected to pin 22 while ir transmitter to pin 18. I'll leave you a short video. I hope you can help me. Thank you.

Image

Video.WhatsApp.2025-02-10.ore.10.46.12_aa5700d8.mp4

@ts1
Copy link
Owner

ts1 commented Feb 12, 2025

Could you send me the JSON file? I might be able to look into it.

@dantederrico
Copy link
Author

Thanks for the support Takeshi, fortunately I solved it. I recharged the operating system and now everything is back up to work!! Thanks anyway for the support and I'll keep you updated if you have any problems 😊

@dantederrico
Copy link
Author

Puoi mandarmi il file JSON? Potrei essere in grado di esaminarlo.

Hi Takeshi, I did a test today. I tried to get the project running on a rasperry pi 3b+ with bulleseye 2022 (32bit) installed. I captured the IR codes of my hifi device (Denon RC-220) again but they don't work... which is very strange because on the Raspberry Pi 2B with Buster I had done the same procedure and they worked. What can be changed? I don't understand why it works on 2b and not on 3b+. The codes recorded by the json file are the same. I used same hardware to transmit and receive. I'll leave you the .json file I recorded. I hope it can help me and who knows it might be useful to someone else. Thanks in advance as always.I'll also leave you the configuration file used by Lirc to send commands in case you want to make a comparison.

denon.json

RC-220.txt

@ts1
Copy link
Owner

ts1 commented Feb 18, 2025

That JSON file is a bit unusual—it might be a bug in PiIR. Could you please try this: while recording into a new JSON file with PiIR, play your JSON file using PiIR to see if you get the same result? If it doesn’t, then it’s definitely a bug in PiIR.

@dantederrico
Copy link
Author

That JSON file is a bit unusual—it might be a bug in PiIR. Could you please try this: while recording into a new JSON file with PiIR, play your JSON file using PiIR to see if you get the same result? If it doesn’t, then it’s definitely a bug in PiIR.

Hi, I did the test as you told me. I re-recorded the buttons by creating a new json file but the recorded data is identical. But the Raspberry updated and it no longer works :(. Can you do some testing to get feedback? At the moment it only seems to work with that version. Thank you ^.^

@dantederrico
Copy link
Author

Hi Takeshi, sorry for the inconvenience, it magically works on raspberry p 3b+ too (I don't know why maybe as you say it will definitely be a bug) I wanted to ask you a question. Since I created a voice assistant in Python, could you tell me how to integrate the send ir command (piir play...) into the script? because I'm trying but I can't thanks!!

@ts1
Copy link
Owner

ts1 commented Feb 21, 2025

I'm using in my script like below:

import piir
remote = piir.Remote(Path(__file__).parent / 'light.json', 17)
remote.send('full')

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