Page 1 of 1
communication between 2 or more pic
Posted: Wed Dec 22, 2010 2:18 pm
by some3
HI
like I said I want to communicate between at least 2 pic 16f877a how can I do that.
I was thinking about rs232 ??
One pic will be like an control panel whit input botuns, lcd, lots of LED....
the other will be for outputs and inputs like operating valves, motors,......
Re: communication between 2 or more pic
Posted: Wed Dec 22, 2010 3:08 pm
by Benj
Hello,
RS232 or the TTL 5V equivalent eg not using MAX232 voltage level converter chips is probably the easiest way of establishing communications.
You should be able to wait for an incoming byte and then switch depending on that byte value to control the operation of the device.
Eg
Byte = 1, Take the next bytes and output them to a LCD, If the byte received is 255 then go back to waiting for a valid byte.....
Re: communication between 2 or more pic
Posted: Sat Dec 25, 2010 2:16 pm
by some3
I have figured something out aboute rs232 because i realy couldnt make real sents of your post..sory
now I have a new problem my flowcode says that this version of flowcode can compile code or the folowing components only:
LED
LEDarray
led7seg
led7seg4
LCDDisplay
SWITCH
SWITCHbank
ADC
kaypad
PWM
formulaFlowcode
MIAC
what is wrong I dont get any activiti on the pins when I try the chip.
Re: communication between 2 or more pic
Posted: Sat Dec 25, 2010 2:33 pm
by medelec35
No activity on the pins is usually down to the configuration settings of the chip (Select 'Chip' 'Configure' then switch to expert screen. Make sure watchdog timer and LVP are disabled. Take a look here:
http://www.matrixmultimedia.com/mmforum ... =26&t=6936
If you want to post your flowchart, along with the hex code it has compiled, then I can have a look for you and see whats causing the issue.
Re: communication between 2 or more pic
Posted: Sat Dec 25, 2010 2:53 pm
by some3
the problem is whit flowcode I cant compile anithing but the listed things Ihave tried all not listed comonents and the same error aperes.
the flowcode and hex are here
Re: communication between 2 or more pic
Posted: Sat Dec 25, 2010 3:08 pm
by medelec35
Your flowchart compiled OK on my PC with no errors. Are you using an internal or external osc, and at what speed?
I would also be helpful if you can post the .msg file so the all the error information can be read.
Only time you will get limitations on components not able to be used (e.g RS232) is if you have a student/home version.
Edit: just saw your picture.
If you do help/about what is the version and licence type you have got?
Could it be you have not fully registered with pro serial?
Re: communication between 2 or more pic
Posted: Sat Dec 25, 2010 3:36 pm
by some3
oh no.
i have a student version of flowcode

(
i am using a 16f877a pic whit an 4mhz osc. (HS in setings )
Re: communication between 2 or more pic
Posted: Sat Dec 25, 2010 3:39 pm
by medelec35
You must have the Demo or Student version as I have just downloaded and installed the demo version and I get exactly the the same message now.
In order to use RS232 you must have a licence for the professional version. If you already have the student version, then if you upgrade to to professional, then there is a large discount.
Re: communication between 2 or more pic
Posted: Sat Dec 25, 2010 3:44 pm
by medelec35
We posted at the same time.
The pro version is well worth buying, due to the extra components available.
Until then, I'm afraid you will not be able to continue with your flowcode that contains RS232, due to licence limitations, Sorry about that.
Re: communication between 2 or more pic
Posted: Sat Dec 25, 2010 3:57 pm
by some3
oh well then happy christmas
tnx for now I will continue as soon as I have a pro licenc
Re: communication between 2 or more pic
Posted: Sat Dec 25, 2010 4:05 pm
by medelec35
Thanks, and Happy Christmas to you, and to everyone else who reads this.