Hi,
Seems as Oscillator Config in Project Options not works as need.
My pic starts only after adding C code at the begin of chart.
OSCCON=0b01110110;
OSCCON2=0b00000010;
OSCTUNE=0b11000000;
It is starts at 16MHZ.
Now I need to use PLL to starts internal OSC at 64MHZ. I need to add to C code configuration register CONFIG1H=0b01011000
but compiler give error message
LCD_Enc_test.c: main()
4758: CONFIG1H=0b01011000;
^ (192) undefined identifier "CONFIG1H"
(908) exit status = 1
(908) exit status = 1
C:\Program Files (x86)\Flowcode 7\compilers\pic\bin\xc8.exe reported error code 1
Can you advice to run PIC with internal oscillator at 64MHZ?
Thanks!
PIC18F14K22 Oscillator question
Moderator: Benj
-
- Matrix Staff
- Posts: 9520
- Joined: Sat May 05, 2007 2:27 pm
- Location: Northamptonshire, UK
- Has thanked: 2585 times
- Been thanked: 3815 times
- Contact:
Re: PIC18F14K22 Oscillator question
Error is there because you cant add any CONFIG statments.radist73 wrote: I need to add to C code configuration register CONFIG1H=0b01011000
but compiler give error message
You must set the CONFIG within Flowcode configuration settings (Build, Project options) only.
Martin
-
- Posts: 36
- Joined: Mon Dec 22, 2014 10:04 pm
- Location: TALLINN
- Has thanked: 5 times
- Been thanked: 2 times
- Contact:
Re: PIC18F14K22 Oscillator question
Thanks for reply! But could you check, may be component have any problem? Seems as PLL cant start...
-
- Matrix Staff
- Posts: 9520
- Joined: Sat May 05, 2007 2:27 pm
- Location: Northamptonshire, UK
- Has thanked: 2585 times
- Been thanked: 3815 times
- Contact:
Re: PIC18F14K22 Oscillator question
If you post your flowchart I can see if I can spot the issue.
Martin