Just wondering if there is any news on the "B" update?
Just wondering if there is any news on the "B" update?
-Bert
The glass is not half full or half empty, Its twice as big as needed for the job!
http://foamcasualty.com/ - Warbird R/C scratch building with foam!
Cool!!! I must have been out of the loop: LOL Thank you!
-Bert
The glass is not half full or half empty, Its twice as big as needed for the job!
http://foamcasualty.com/ - Warbird R/C scratch building with foam!
Ok, I have not tried at home yet, just from work. But I get errors trying to compile for the new chips. I tried three of the new J's, and pretty much get the same errors. I have checked to make sure that MPLAB had the chips and their P18F47J53.INC files as well.
Is it just me? I will try from home in a couple hours.
And Darrel, I thought it was 2.60B
Code:;**************************************************************** ;* 18F27J53.INC * ;* * ;* By : Leonard Zerman, Jeff Schmoyer * ;* Notice : Copyright (c) 2010 microEngineering Labs, Inc. * ;* All Rights Reserved * ;* Date : 09/13/10 * ;* Version : 2.60b * ;* Notes : * ;****************************************************************![]()
Last edited by ScaleRobotics; - 5th March 2011 at 01:07. Reason: added .lst file
YEAH!!! I haven't tried it yet, but the patch says it has fixed the 2 UART on the 16F1's so now we can use HSEROUT2/IN2. Very cool!![]()
-Bert
The glass is not half full or half empty, Its twice as big as needed for the job!
http://foamcasualty.com/ - Warbird R/C scratch building with foam!
Walter,
You just need to update your MPLAB. Those chips are a recent addition.
I'm not sure which version they were added, but they are in MPASM 5.37.
The .LST file indicates they weren't in 5.31.
DT
Thanks Darrel, sorry for the trouble. I must have had a weird MPLAB/MPASM install issue at work. Mpasm showed the include file, but MPLAB 8.33 I couldn't see the chip in the drop down box. Definitely missing something. Anyway, it worked fine at home, but it didn't like my slightly altered .inc files. I had to delete a few to make the update install.
Thanks again.
At last got to the stage where it programs, but as we all know, that's just the start.
I think it's the dreaded INC config stuff.
Using HSPPL I get a slow clock out, doesn't run program. I've read the datasheet many times but nowhere does it really explain options.
There is next to nothing on the forums about this 18F27J53 device.
Many flags do not appear to be in the INC file.
Tried @ _CONFIG using many of the switches but I'm only shotgunning.
I want to run USB using internal clock; CPU speed not important.
Any idea about INC file or @ _CONFIG settings? Thanks for your help in anticipation.
Goto the MPASM SUITE directory under C:\Program Files\Microchip\MPASM Suite
There you will find MicroChips *.inc file for the chip. At the end of the file all of the configs are listed.
I did not see what you are planning to use for an OSC. Post a little bit more about your setup, MCLR and stuff and we can help with the configs.
Dave
Always wear safety glasses while programming.
Dave, thanks for coming back.
My setup is whatever someone else has working. Don't care about CPU speed for now.
The program works fine on 16Fxxx.
I've tried 4, 8 and 20meg crystals/resonators, changed divider in INC and set DEFINE OSC n to clock speed.
Currently 4 divided by 1.
All result in the same low clock out as if the crystal is not doing anything.
Tried HS and HSPLL. Have a 20MHz oscillator so will try that next using EC.
But I suspect it's nothing to do with the clock settings (as they don't make any difference), it's another switch somewhere.
'setup:
' @ __CONFIG _CONFIG1H _HSPLL_OSC_1H
' @ __CONFIG _CONFIG1H _XINST = OFF
' @ __CONFIG _CONFIG1H _PLLDIV = 5
' @ __CONFIG _CONFIG1H _WDTPS = 512
' @ __CONFIG _CONFIG1H _ADCSEL = BIT12
DEFINE OSC 4 ' set the clock speed
DEFINE DEBUG_REG PORTC ' Set Debug pin port
DEFINE DEBUG_BIT 2 ' Set Debug pin bit
DEFINE DEBUG_BAUD 9600 ' Set Debug baud rate
DEFINE DEBUG_MODE 1 ' Set Debug mode: 0=true (for drivers), 1=inverted
DEFINE LCD_LINES 4 ' Using a 4 lines LCD
; Oscillator:
; OSC = INTOSC INTOSC
; OSC = INTOSCO INTOSCO (CLKO-RA6)
; OSC = INTOSCPLL INTOSCPLL
; OSC = INTOSCPLLO INTOSCPLLO (CLKO-RA6)
; OSC = HS HS, USB-HS
; OSC = HSPLL HS+PLL, USB-HS+PLL
; OSC = EC EC (CLKO-RA6), USB-EC
; OSC = ECPLL EC+PLL (CLKO-RA6), USB-EC+PLL
; PLL Prescaler Selection:
; PLLDIV = 12 Divide by 12 (48 MHz oscillator input)
; PLLDIV = 10 Divide by 10 (40 MHz oscillator input)
; PLLDIV = 6 Divide by 6 (24 MHz oscillator input)
; PLLDIV = 5 Divide by 5 (20 MHz oscillator input)
; PLLDIV = 4 Divide by 4 (16 MHz oscillator input)
; PLLDIV = 3 Divide by 3 (12 MHz oscillator input)
; PLLDIV = 2 Divide by 2 (8 MHz oscillator input)
; PLLDIV = 1 No prescale (4 MHz oscillator input drives PLL directly)
I do not have that chip to actually test this, but try this using the internal OSC.
Then in your codeCode:'Set the *.inc OSC configs to.. CONFIG PLLDIV = 2 CONFIG OSC = INTOSCPLL CPUDIV = OSC1
That should have the chip set to run at USB speeds using the built in OSC.Code:DEFINE OSC 48
Dave
Always wear safety glasses while programming.
Thanks Dave.
Tried INTOSCPLL and INTOSCPLLO
Whatever I do produces 1 meg clock out.
Going to order some more and see if I've blown up this guy
Let you know...
LIST
LIST p = 18F27J53, r = dec, w = -311, f = inhx32
INCLUDE "P18F27J53.INC" ; MPASM Header
CONFIG XINST = OFF
CONFIG WDTPS = 512
CONFIG PLLDIV = 2 ; CONFIG PLLDIV = 5
CONFIG OSC = INTOSCPLLO ; CONFIG OSC = HSPLL
CPUDIV = OSC1
CONFIG ADCSEL = BIT12
NOLIST
Check the OSCTUNE.6 bit. It may need to be set to actually turn on the PLL
-Bert
The glass is not half full or half empty, Its twice as big as needed for the job!
http://foamcasualty.com/ - Warbird R/C scratch building with foam!
Or you can turn the PLL on in configs, with:
CONFIG CFGPLLEN = ON ;Turns on PLL enable
Bookmarks