Hello all,
I have finished work on a lirc driver for linux that supports receive and transmit in ir sample mode. I have just submitted the patch here:
http://sourceforge.net/mailarchive/foru ... =lirc-list (http://sourceforge.net/mailarchive/forum.php?thread_name=4ebf97df-17f8-48bb-ba65-32e4b9983ac4%40devleno&forum_name=lirc-list)
Tested with irw, irrecord and irsend, working fine in my setup, ymmv.
Peter
Very nice, thank you!
I read through the code, very tidy. Everything in the DB transmit function seems good.
I'll post this up and see if we can get some more testers.
I want to test irtoy lirc driver, but i can't build it.
I download lirc-0.9.0.tar.bz2, patch it. Create new setup-driver.sh from setup.data.
My OS Mint 9.
Then: sudo ./setup.sh && make install
From dialog I select driver:usb_irtoy and tty:/de/ttyACM0
At the end I get:
configure: error: *** it is not possible to install the specified driver
on this system
Following steps worked for me.
Since you have already patched won't explain that.
make sure you have autoconf and automake installed, if they are not already present and run the following commands:
./autogen.sh
./setup.sh #This will ask for the Device and software configurations
./configure.sh --prefix=/usr
make
sudo make install
[quote author="const"]
From dialog I select driver:usb_irtoy and tty:/de/ttyACM0
At the end I get:
configure: error: *** it is not possible to install the specified driver
on this system[/quote]
Yes You need to run ./autogen.sh before ./setup.sh, I should have mentioned that.
I don't have autogen.sh in lirc-0.9.0.tar.bz2. Where I can get it?
[quote author="const"]I don't have autogen.sh in lirc-0.9.0.tar.bz2. Where I can get it?[/quote]
Ah yes, you need to get the latest version from the GIT repository to get the autogen.sh script, it is not included in the normal LIRC distribution. Make sure you have git installed, then create a new empty directory and from there do:
git clone git://lirc.git.sourceforge.net/gitroot/lirc/lirc
This will create a directory lirc in the current directory and populate it with the latest lirc source files.
cd to the lirc directory, apply the irtoy driver patches:
zcat 0001-Add-driver-for-USB-Infrared-Toy-in-sample-mode.patch.gz | patch -p1
zcat 0002-Add-USB-Infrared-Toy-driver-to-setup-system.patch.gz | patch -p1
This should complete without errors.
Then:
./autogen.sh
./setup.sh
setup.sh will pesent you with a menu:
select option 1 "driver configuration"
select option 8 "usb devices"
select option 0, "Dangerous Prototypes USB Infrared Toy"
select the tty for your Irtoy, normally /dev/ttyACM0
You are now back in the main menu, make sure that after Driver configuration it says:
(driver: usb_irtoy tty:/dev/ttyACMx) where x is the tty you selected, 0, 1, 2 or 3
Select option 3, "Save configuration and run configure"
You are now back at the command line, do:
make
sudo make install
I get latest version from the GIT repository. Patch it. Run ./autogen.sh and receive:
Can't exec "libtoolize": No such file or directory at /usr/bin/autoreconf line 189.
Use of uninitialized value in pattern match (m//) at /usr/bin/autoreconf line 189.
configure.ac:24: error: possibly undefined macro: AC_PROG_LIBTOOL
If this token and others are legitimate, please use m4_pattern_allow.
See the Autoconf documentation.
autoreconf: /usr/bin/autoconf failed with exit status: 1
configure.ac:17: required file `./compile' not found
configure.ac:17: `automake --add-missing' can install `compile'
configure.ac:10: required file `./install-sh' not found
configure.ac:10: `automake --add-missing' can install `install-sh'
configure.ac:10: required file `./missing' not found
configure.ac:10: `automake --add-missing' can install `missing'
daemons/Makefile.am:12: library used but `RANLIB' is undefined
daemons/Makefile.am:12: The usual way to define `RANLIB' is to add `AC_PROG_RANLIB'
daemons/Makefile.am:12: to `configure.ac' and run `autoconf' again.
daemons/Makefile.am: required file `./depcomp' not found
daemons/Makefile.am: `automake --add-missing' can install `depcomp'
tools/Makefile.am:51: Libtool library used but `LIBTOOL' is undefined
tools/Makefile.am:51: The usual way to define `LIBTOOL' is to add `AC_PROG_LIBTOOL'
tools/Makefile.am:51: to `configure.ac' and run `aclocal' and `autoconf' again.
tools/Makefile.am:51: If `AC_PROG_LIBTOOL' is in `configure.ac', make sure
tools/Makefile.am:51: its definition is in aclocal's search path.
Makefile.am: required file `./INSTALL' not found
Makefile.am: `automake --add-missing' can install `INSTALL'
configure.ac:11: required file `config.h.in' not found
Creating setup-driver.sh ...
I feel that something is wrong, but run ./setup.sh , select driver: usb_irtoy tty:/dev/ttyACM0 and
select option 3, "Save configuration and run configure". I get:
Configuration: .setup.config, executable shell script: configure.sh
Starting the generated shell script which will call configure with the right
parameters...
configure: error: cannot find install-sh, install.sh, or shtool in "." "./.." "./../.."
[quote author="const"]
Can't exec "libtoolize": No such file or directory at /usr/bin/autoreconf line 189.
[/quote]
Looks like you need to install the libtool package, something like
sudo apt-get install libtool
Thank You very much! I build lirc.
But now I have two problem.
First:
~ $ sudo service lirc start
lirc: unrecognized service
Second:
~ $ irrecord -n -H usb_irtoy -d /dev/ttyACM0 RemoteXXX.conf
Driver `usb_irtoy' not supported.
Supported drivers:
default
[quote author="const"]Thank You very much! I build lirc.
But now I have two problem.
First:
~ $ sudo service lirc start
lirc: unrecognized service
Second:
~ $ irrecord -n -H usb_irtoy -d /dev/ttyACM0 RemoteXXX.conf
Driver `usb_irtoy' not supported.
Supported drivers:
default
[/quote]
Ok, let's make sure it's not finding the lirc version that came with your distribution before the one you compiled. Do
which irrecord
and let us know what it says.
Yes, I run old irrecod from /usr/local/bin (new I biuld in /usr ). I delete all licr files from /usr/local.
irrecord find usb_irtoy , but don't work. It want firmware version 20. I update firmware to V20 and
successfully created file RemoteXXX.conf.
But I still have the first problem. How I can start lirc service?
[quote author="const"]
~ $ sudo service lirc start
lirc: unrecognized service
[/quote]
It's lirc
d, so do
~ $ sudo service lircd start
Be careful though, it could start the lircd from the distribution that probably still is lurking in /usr/local/sbin. For a quick test, you can just do
lircd RemoteXXX.conf
making sure you execute the lircd you compiled, not the one from your distribution. After starting lircd, test with irw to see if it recognizes your remote.
~ $ sudo service lircd start
lircd: unrecognized service
Do you have a file lirc or lircd in /etc/init.d at all? Also, try starting lircd directly as I indicated above, at least it will allow you to test if your newly compiled lircd works.
I start lirc service.
1. make uninstall
2. Install lirc from MInt9 Synaptic
Now I have scripts for lirc service.
3. make install
irrecord does two different conf files for the same remote panel. First big in raw mode and it work correct.
Second small, with it, two of the 21 buttons do not work and the rest give multiple commands on one click.
[quote author="const"]I start lirc service.[/quote]
Great!
[quote author="const"]
irrecord does two different conf files for the same remote panel. First big in raw mode and it work correct.
Second small, with it, two of the 21 buttons do not work and the rest give multiple commands on one click.[/quote]
That kind of problem with irrecord happens from time to time, mainly due to the enormous amount of guesswork irrecord does in "cooked" mode. However, I would like to make sure it's not a driver issue, can you let us know what remote control you used? Also, check the lirc website for conf files for your remote.
I use noname chinese remote like this http://http://www.ebay.com/itm/Wireless-Car-MP3-FM-Transmitter-Player-Modulator-USB-/320733450539?pt=Other_MP3_Player_Accessories&hash=item4aad34112b
The first correct work conf (raw mode) I get if don't press button after first 80 dot string.
[quote author="const"]I use noname chinese remote.[/quote]
Can you post the conf files, both the raw one and the short one that does not work? I would like to compare the two and try to see what's going on.
Yes, I can post. Where to post? PM?
Sent you a PM
yo yo! pretty excited cuz i just got this to compile for openwrt (after fucking with it for days).
i will write up a step-by-stepper after i doublecheck my work :D
big thanks to pitsie for making this driver!
Nice work! Hope the driver works as it should!
This is amazing - i've been waiting a while for a native LIRC driver for the toy :) You rock!
The patch seems to work fine. ¿Do you know if the LIRC developers plan to merge it into the mainline?
Hello,
I want to use my irtoy with lirc to turn on my devices (with an infrared controlled power plug). I used it with winlirc so far, and it was working.
Now I switched to XBMCubuntu. Lirc still seems not to natively support the irtoy.
I tried to compile it on my own, but i got stuck on at:
cd to the lirc directory, apply the irtoy driver patches:
zcat 0001-Add-driver-for-USB-Infrared-Toy-in-sample-mode.patch.gz | patch -p1
zcat 0002-Add-USB-Infrared-Toy-driver-to-setup-system.patch.gz | patch -p1
the output is:
zcat 0001-Add-driver-for-USB-Infrared-Toy-in-sample-mode.patch.gz | patch -p1
gzip: 0001-Add-driver-for-USB-Infrared-Toy-in-sample-mode.patch.gz: No such file or directory
sixpacku@sixpack:~/lircd/lirc$ zcat 0002-Add-USB-Infrared-Toy-driver-to-setup-system.patch.gz | patch -p1
gzip: 0002-Add-USB-Infrared-Toy-driver-to-setup-system.patch.gz: No such file or directory
it seems like the patches do not exist. where can i get them?
Edit:
got, it - found them at http://sourceforge.net/mailarchive/mess ... d=28032156 (http://sourceforge.net/mailarchive/message.php?msg_id=28032156) (due to noscript, no attachements where shown)
.
I cannot run setup.sh, it fails with:
./setup.sh
dialog not found!
what is wrong?
You need dialog. If you are using a Debian based distro like ubuntu you can do: apt-get install dialog
setup.sh will pesent you with a menu:
select option 1 "driver configuration"
select option 8 "usb devices"
select option 0, "Dangerous Prototypes USB Infrared Toy"
select the tty for your Irtoy, normally /dev/ttyACM0
cant select irtoy at ttyACMx because mine is at ttyUSB2
aslo xbmc@xbmc:~/lirc$ make
returns:
make: *** No targets specified and no makefile found. Stop.
The patches merged upstream for over the year now. Thank you Peter and all who helped with testing!
Hello,
after a complete reinstall of kodi (x64) I tried to get lirc with irtoy working again.
I just cloned the newest lirc from sourceforge and the patch is not yet included.
I tried to patch the files but this wont work:
patching file configure.ac
Hunk #1 FAILED at 154.
Hunk #2 FAILED at 445.
Hunk #3 FAILED at 679.
Hunk #4 FAILED at 1390.
4 out of 4 hunks FAILED -- saving rejects to file configure.ac.rej
can't find file to patch at input line 60
Perhaps you used the wrong -p or --strip option?
The text leading up to this was:
--------------------------
|diff --git a/daemons/hw-types.c b/daemons/hw-types.c
|index 0536ea2..b11cbdf 100644
|--- a/daemons/hw-types.c
|+++ b/daemons/hw-types.c
--------------------------
I saved my old patched lirc install files, but after autogen setup and configure when I enter "make" it wont work:
i386 architecture of input file `libhw_module.a(hw_usbirtoy.o)' is incompatible with i386:x86-64 output
how can I get it working again?