Page 2 of 2

Re: MX010 - RC5 remote control

Posted: Mon May 30, 2011 6:37 pm
by Disjoint
Hi all,

I have just upgraded from FC V3 for PIC to V4 thinking that the RC5 component was now included after reading Sean's excellent article "Programmable RC-5 Remote Control" last October, where he stated "A fully integrated Flowcode RC-5 component will be available in the near future", just my luck!

I wish to create a small circuit to switch LED's on/off or flash + vary the speed of a small DC motor, all controlled via IR.

After reading Fotios posts about his project I downloaded his RC5_INT_3_mod.fcf, then compiled and loaded it into a P16F877a and it worked perfectly. As I don’t require a 40 pin device and size of the finished PCB needs to be as small as possible, a P16F88 seemed like a good choice for initial experimentation (I happen to have a few of these to hand).

This is where the problems have started, I first of all created a new project for the P16F88, pasted Fotios main coding into it then imported his macro "output" and Sean's "SignalEdge". To test I have changed the outputs to indicate on port A (A0 - A3) and removed the LCD output/commands.

Flowcode refuses to compile the program and gives me the following error "If your flowchart contains C code, please review this carefully. If your flowchart contains no C-code or you have thoroughly reviewed the code, contact Technical Support."

I suspect that the error is in the configuration which is in C code. Unfortunately I started learning assembly and after two weeks purchased FC V3 and bypassed the rest of assembly and also C. Any help and/or assistance would be greatly appreciated.

Enclosed is my modified version of Fotios's RC5_INT_3_mod.fcf and error txt file.
RC5_INT_3_mod_16F88_01.msg.txt
(748 Bytes) Downloaded 788 times
RC5_INT_3_mod_16F88_01.fcf
(23.9 KiB) Downloaded 891 times
Many Thanks,

Peter.

Re: MX010 - RC5 remote control

Posted: Tue May 31, 2011 10:12 am
by Benj
Hello Peter,

There are a few key differences between the 16F877A and the 16F88.

The T0IF flag becomes TMR0IF as seen in the Reset TMR0 icon in the signal edge macro.

PortD does not exist for the 16F88 device. I changed these references to PortB.

The EEPROM error messages were there because for some reason the EEPROM component was missing from the program.

Finally the timeout variable was also missing from the program. I added this and the program is now compiling correctly.

Re: MX010 - RC5 remote control

Posted: Thu Jun 02, 2011 4:46 pm
by pdevel
Hi
I'm very interresting by your project
But I have any questions:is it the same program for transmitter and receiver?
And is it possible use the rf for replace IR?
Regards
Philippe

Re: MX010 - RC5 remote control

Posted: Fri Jun 03, 2011 3:27 pm
by Benj
Hello Philippe

We have a article on sending and receiving using the Flowcode RF component available from here if this helps.
http://www.matrixmultimedia.com/article.php?a=369