I modified a working GCBASIC code runing on a PIC16f628A to run on a PIC 18f1220.
I reassigned the pins according to the Data Sheet in the GCBASIC code, and the hex file does not work.
I checked the 18f1220.dat file and found a pin assignment different from the Data Sheet. I modified the 18f1220.dat to match the data sheet:
1,RA0(IO),AN0(I)
2,RA1(IO),AN1(I)
6,RA2(IO),AN2(I)
7,RA3(IO),AN3(I)
3,RA4(IO),T0CKI(I)
4,RA5(I),MCLR(I),MCLR
15,RA6(IO),OSC2(O),OSC2
16,RA7(IO),OSC1(O),OSC1
8,RB0(IO),AN4(I)
9,RB1(IO),AN5(I),U1TX(O)
17,RB2(IO),ECCPB(O)
18,RB3(IO),CCP1,P1A
10,RB4(IO),AN6(I),U1RX(I)
11,RB5(IO)
12,RB6(IO),T1CKI(I),T3CKI(I),ECCPC(O),T1OSCO(O)
13,RB7(IO),ECCPD(O),T1OSCI(I)
5,Vss
14,Vdd
The new hex file does not work, it looks like the internal 8Mhz clock intosc does not work ?
Where is the problem ?
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I thought this once too, but Hugh has mentioned that the in the xxxx.dat files are not necessarily reliable, and have no effect on compilation. The PINS were used for the GCBIDE device diagrams.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I modified a working GCBASIC code runing on a PIC16f628A to run on a PIC 18f1220.
I reassigned the pins according to the Data Sheet in the GCBASIC code, and the hex file does not work.
I checked the 18f1220.dat file and found a pin assignment different from the Data Sheet. I modified the 18f1220.dat to match the data sheet:
1,RA0(IO),AN0(I)
2,RA1(IO),AN1(I)
6,RA2(IO),AN2(I)
7,RA3(IO),AN3(I)
3,RA4(IO),T0CKI(I)
4,RA5(I),MCLR(I),MCLR
15,RA6(IO),OSC2(O),OSC2
16,RA7(IO),OSC1(O),OSC1
8,RB0(IO),AN4(I)
9,RB1(IO),AN5(I),U1TX(O)
17,RB2(IO),ECCPB(O)
18,RB3(IO),CCP1,P1A
10,RB4(IO),AN6(I),U1RX(I)
11,RB5(IO)
12,RB6(IO),T1CKI(I),T3CKI(I),ECCPC(O),T1OSCO(O)
13,RB7(IO),ECCPD(O),T1OSCI(I)
5,Vss
14,Vdd
The new hex file does not work, it looks like the internal 8Mhz clock intosc does not work ?
Where is the problem ?
I thought this once too, but Hugh has mentioned that the in the xxxx.dat files are not necessarily reliable, and have no effect on compilation. The PINS were used for the GCBIDE device diagrams.