Page 1 of 1

PIC18f4680 PORTD LCD issue

Posted: Fri Jul 20, 2012 3:29 pm
by Enamul
Hi,
I have been struggling to get LCD output in PORTD in PIC18f4680..This is because of the initialization problem in the FCD file. I have managed to sort out the issue. There are quite a few multiplexing in that port..I/O, PSP, CCP, ECCP which causing the problem.

I have attached here the FCD so that MM masters can update that. Clearing trisd will not hamper input declaration as whenever anyone declares any pin as input that macro will automatically changes that bit in tris register.

Code: Select all

Initialise="adcon1 = 0x0F;\ncr_bit(trise,PSPMODE);\nccp1con=0x00;\neccp1con=0x00;\ncmcon=0x07;\ntrisd=0x00;\n"
Thanks,
Enamul

Re: PIC18f4680 PORTD LCD issue

Posted: Fri Jul 20, 2012 4:50 pm
by Benj
Thanks Enamul,

The changes have now gone into the master files. Effected devices - 18F2585, 2680, 4585, 4680.

I have left the "trisd=0x00;\n" off all the init functions as we can't tell what the user will want the data direction to be and the LCD component should sort this out for you anyway.

I have also left the "cr_bit(trise,PSPMODE);" off for the 18F2xxx devices as they do not have the trise register.

Re: PIC18f4680 PORTD LCD issue

Posted: Fri Jul 20, 2012 5:32 pm
by Enamul
Hi Ben,
I have left the "trisd=0x00;\n" off all the init functions as we can't tell what the user will want the data direction to be and the LCD component should sort this out for you anyway.
Unfortunately until the above command I don't have anything in the display...
Enamul

Re: PIC18f4680 PORTD LCD issue

Posted: Tue Jul 31, 2012 2:34 pm
by Enamul
Hi Ben,

This change should go to 18f4580.fcd as well..
The changes have now gone into the master files. Effected devices - 18F2585, 2680, 4585, 4680.
Enamul

Re: PIC18f4680 PORTD LCD issue

Posted: Sun Sep 02, 2012 4:21 pm
by Enamul
Hi,
This change isn't still in PIC18f4580.fcd

I thought it's already updated but when LCD wasn't working I found it not still updated

Re: PIC18f4680 PORTD LCD issue

Posted: Mon Sep 03, 2012 10:40 am
by Benj
Hello Enamul,

Sorry about that. The changes have now been applied to the 18F4480 and 4580 devices.

Re: PIC18f4680 PORTD LCD issue

Posted: Mon Sep 03, 2012 10:47 am
by Enamul
Hi Ben,
It's ok. I am currently using PIC18f4580 for couple of projects and my machine needed new OS and I have reinstalled FCV5.4. I was testing ready program but it doesn't work at all..screws me down what happening. Then I found this FCD issue.