Pinguino Forum

Full Version: IR LIBRARY
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25
i am looking for a IR library to decode like a sony IR remote.
thanks
fred
I found this one on Google.
It seems quite easy to port to Pinguino and works with a lot of brands.

(10-12-2013, 01:52 PM)derf158 Wrote: [ -> ]i am looking for a IR library to decode like a sony IR remote.
thanks
fred
(11-12-2013, 11:26 AM)regis Wrote: [ -> ]I found this one on Google.
It seems quite easy to port to Pinguino and works with a lot of brands.

(10-12-2013, 01:52 PM)derf158 Wrote: [ -> ]i am looking for a IR library to decode like a sony IR remote.
thanks
fred

Regis
What did you find?
(11-12-2013, 03:15 PM)regis Wrote: [ -> ]Oops, sorry : https://github.com/shirriff/Arduino-IRremote


Regis I think I am going to need help on porting this into pinguino IDE . I was looking at the link for the arduino ir library. I noticed arduino.h wprogram.h I do not know how to handle the modification to these files. I did put the ir library files into the P8 library folder.i renamed IRremote.cpp to IRremote.c .
The first thing I would do is to rename every C++ function in your IRremote.c file.
For example, rename IRsend:ConfusedendNEC in IRsend_sendNEC
Add every function in a pdl/IRremote.pdl file. For ex :
irsend.sendNEC IRsend_sendNEC#include <IRremote.c>
Try not to use output function except for debug purpose. So no Serial.print() in your code except if it's surrounded with #ifdef DEBUG / #endif.
Take a look at interrupt.c to see how interrupt works with PIC18F.
BLINKLED should be USERLED or just add #define BLINKLED USERLED
Good luck.


(12-12-2013, 01:11 PM)derf158 Wrote: [ -> ]
(11-12-2013, 03:15 PM)regis Wrote: [ -> ]Oops, sorry : https://github.com/shirriff/Arduino-IRremote


Regis I think I am going to need help on porting this into pinguino IDE . I was looking at the link for the arduino ir library. I noticed arduino.h wprogram.h I do not know how to handle the modification to these files. I did put the ir library files into the P8 library folder.i renamed IRremote.cpp to IRremote.c .
(12-12-2013, 04:30 PM)regis Wrote: [ -> ]The first thing I would do is to rename every C++ function in your IRremote.c file.
For example, rename IRsend:ConfusedendNEC in IRsend_sendNEC
Add every function in a pdl/IRremote.pdl file. For ex :
irsend.sendNEC IRsend_sendNEC#include <IRremote.c>
Try not to use output function except for debug purpose. So no Serial.print() in your code except if it's surrounded with #ifdef DEBUG / #endif.
Take a look at interrupt.c to see how interrupt works with PIC18F.
BLINKLED should be USERLED or just add #define BLINKLED USERLED
Good luck.


(12-12-2013, 01:11 PM)derf158 Wrote: [ -> ]
(11-12-2013, 03:15 PM)regis Wrote: [ -> ]Oops, sorry : https://github.com/shirriff/Arduino-IRremote


Regis I think I am going to need help on porting this into pinguino IDE . I was looking at the link for the arduino ir library. I noticed arduino.h wprogram.h I do not know how to handle the modification to these files. I did put the ir library files into the P8 library folder.i renamed IRremote.cpp to IRremote.c .
ok I will work it thank you
(12-12-2013, 07:45 PM)derf158 Wrote: [ -> ]
(12-12-2013, 04:30 PM)regis Wrote: [ -> ]The first thing I would do is to rename every C++ function in your IRremote.c file.
For example, rename IRsend:ConfusedendNEC in IRsend_sendNEC
Add every function in a pdl/IRremote.pdl file. For ex :
irsend.sendNEC IRsend_sendNEC#include <IRremote.c>
Try not to use output function except for debug purpose. So no Serial.print() in your code except if it's surrounded with #ifdef DEBUG / #endif.
Take a look at interrupt.c to see how interrupt works with PIC18F.
BLINKLED should be USERLED or just add #define BLINKLED USERLED
Good luck.


(12-12-2013, 01:11 PM)derf158 Wrote: [ -> ]
(11-12-2013, 03:15 PM)regis Wrote: [ -> ]Oops, sorry : https://github.com/shirriff/Arduino-IRremote


Regis I think I am going to need help on porting this into pinguino IDE . I was looking at the link for the arduino ir library. I noticed arduino.h wprogram.h I do not know how to handle the modification to these files. I did put the ir library files into the P8 library folder.i renamed IRremote.cpp to IRremote.c .
ok I will work it thank you
Regis i do not understand what i need to do with the pdl?
Add every function in a pdl/IRremote.pdl file. For ex :
irsend.sendNEC IRsend_sendNEC#include <IRremote.c>

thanks
fred
Pdl files are Pinguino's Keyword files. They help the Pinguino preprocessor to translate C++ format instructions (name.function) to SDCC-understable C instructions (functions that are in the .c file that will be included in the core program).
Please, read this :
http://wiki.pinguino.cc/index.php/How_ca...inguino%3F
Hey derf158,
if you share an hw schema, we can take a look together.

Bye
Pages: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25