Thanks alot! I will try that.
Do I need to set OSCCON and OSCTUNE registers as well if I am using internal oscillator? I am a bit confused about Frequency Tuning bit of OSCTUNE register.How you get to 16MHz from 96 MHz PLL?
Thanks alot! I will try that.
Do I need to set OSCCON and OSCTUNE registers as well if I am using internal oscillator? I am a bit confused about Frequency Tuning bit of OSCTUNE register.How you get to 16MHz from 96 MHz PLL?
for 16mhz
Code:#CONFIG CONFIG WDTEN = ON CONFIG PLLDIV = 2 CONFIG STVREN = ON CONFIG XINST = OFF CONFIG DEBUG = OFF CONFIG CPUDIV = OSC3_PLL3 CONFIG CP0 = OFF CONFIG OSC = INTOSCPLL CONFIG T1DIG = ON CONFIG LPT1OSC = OFF CONFIG FCMEN = OFF CONFIG IESO = OFF CONFIG WDTPS = 512 CONFIG DSWDTOSC = INTOSCREF CONFIG RTCOSC = T1OSCREF CONFIG DSBOREN = ON CONFIG DSWDTEN = ON CONFIG DSWDTPS = G2 CONFIG IOL1WAY = ON CONFIG MSSP7B_EN = MSK7 CONFIG WPFP = PAGE_0 CONFIG WPEND = PAGE_WPFP CONFIG WPCFG = OFF CONFIG WPDIS = OFF #ENDCONFIG OSCTUNE.6=1 ; pll enableCode:8mhz -----/2 --= 4---pll--= 96 -/2 = 48 ------/3-- = 16 inc osc pll pre pll cpu div
Last edited by richard; - 31st May 2016 at 11:16. Reason: white space is nearly impossible
Warning I'm not a teacher
I got it running using external oscillator but bluetooth doesn't pickup the commands..
Any idea? evendoesn't work.Code:Hserout [dec 10]
Actually It's working using what you suggested.
Thanks alot!Code:Hserout [10,0]
Bookmarks