hi
i try too use INTOSC in one Project with a 16LF1823 but this not working prperty after program Micro///this just working property wen i set FREQ in 0.5 MHZ and PWM out put FRQ is not true i see with osiloscope ///when i set PWM FRQ to 38 kHZ micro provide 1 KHz PWM
INT OSC in PIC 16LF1823
-
- Posts: 40
- http://meble-kuchenne.info.pl
- Joined: Mon Apr 05, 2021 1:59 am
- Has thanked: 8 times
- Been thanked: 4 times
-
- Matrix Staff
- Posts: 1746
- Joined: Mon Dec 07, 2020 10:06 am
- Has thanked: 444 times
- Been thanked: 604 times
Re: INT OSC in PIC 16LF1823
Hello,
On the component toolbar look under Runtime -> Matrix tools for the IntOsc helper component.
This lists the speeds that the internal oscillator on your selected device can run at and also lists the line of C code needed to be inserted after the start icon to configure the chip to run at the selected speed.
For 0.5MHz you need to use the following line of C code at the start of your program.
Hopefully this helps.
On the component toolbar look under Runtime -> Matrix tools for the IntOsc helper component.
This lists the speeds that the internal oscillator on your selected device can run at and also lists the line of C code needed to be inserted after the start icon to configure the chip to run at the selected speed.
For 0.5MHz you need to use the following line of C code at the start of your program.
Code: Select all
OSCCON = 0x38;
Regards Ben Rowland - MatrixTSL
Flowcode Online Code Viewer (Beta) - Flowcode Product Page - Flowcode Help Wiki - My YouTube Channel
Flowcode Online Code Viewer (Beta) - Flowcode Product Page - Flowcode Help Wiki - My YouTube Channel