Page 1 of 1

Timer1 & 2 16F15xxx

Posted: Mon Apr 15, 2019 1:01 pm
by medelec35
Just adding enable for both timer1 and timer2:

Code: Select all

    89:	T1CONbits.T1OSCEN = 0;
	                  ^ (255) not a member of the struct/union ""
	                     ^ (182) illegal conversion between types
int -> volatile union S148
    91:	T1CONbits.TMR1CS1 = 1;
	                  ^ (255) not a member of the struct/union ""
	                     ^ (182) illegal conversion between types
int -> volatile union S148
    94:	PIE1bits.TMR1IE = 1;
	                ^ (255) not a member of the struct/union ""
	                   ^ (182) illegal conversion between types
int -> volatile union S391
   105:	PIE1bits.TMR2IE = 1;
	                ^ (255) not a member of the struct/union ""
	                   ^ (182) illegal conversion between types
int -> volatile union S391
Timer int 16F15324.c: myisr()
   121:	if ((PIR1bits.TMR1IF) && (PIE1bits.TMR1IE))
	                    ^ (255) not a member of the struct/union ""
	                                         ^ (255) not a member of the struct/union ""
	              (199) logical type required ^
	              (199) logical type required ^
   124:	PIR1bits.TMR1IF = 0;
	                ^ (255) not a member of the struct/union ""
	                   ^ (182) illegal conversion between types
int -> volatile union S374
   134:	if ((PIR1bits.TMR2IF) && (PIE1bits.TMR2IE))
	                    ^ (255) not a member of the struct/union ""
	                                         ^ (255) not a member of the struct/union ""
	              (199) logical type required ^
	              (199) logical type required ^
   137:	PIR1bits.TMR2IF = 0;
	                ^ (255) not a member of the struct/union ""
	                   ^ (182) illegal conversion between types
int -> volatile union S374
(908) exit status = 1
(908) exit status = 1

C:\Program Files (x86)\Microchip\xc8\v2.00\bin\xc8.exe reported error code 1

Re: Timer1 & 2 16F15xxx

Posted: Tue Apr 16, 2019 11:57 am
by Benj
Hi Martin,

Thanks for letting me know. Hopefully now fixed in the latest v7 update archive.

Re: Timer1 & 2 16F15xxx

Posted: Wed Apr 17, 2019 7:13 am
by medelec35
Thanks, Ben
No compile errors now, with Timer1 or Timer2.