Sonsivri
 
*
Welcome, Guest. Please login or register.
Did you miss your activation email?
November 22, 2024, 07:25:40 19:25


Login with username, password and session length


Pages: [1]
Print
Author Topic: Configuring some Fuses in Proton with 18F2550  (Read 6643 times)
0 Members and 1 Guest are viewing this topic.
Deimos
Newbie
*
Offline Offline

Posts: 31

Thank You
-Given: 1
-Receive: 14


Whatever...!!!


WWW
« on: September 09, 2007, 08:17:21 20:17 »

Hi:

in the past, when it wanted to work with the USB, I entered normally to the EasyHID and it generated the code, soon it added what needed and compiled, and in the short while to load hex in the Winpic, had to modify the division of the PLL to the one of the crystal that used, therefore could not use the F10 key so that it loaded the HEX and it directly programs the Pic micro by that change that it had to do, now to loooong time since I began with this, I have watched the fuses and I have made the next configurations to have change nothing in winpic:

Code:
@CONFIG_REQ
    @PLL_REQ
        @__config config1l, PLLDIV_3_1 & CPUDIV_2_1 & USBDIV_2_1
        @__config config1h, FOSC_HSPLL_HS_1
    @WATCHDOG_REQ
        @__config config2h, WDT_OFF_2 & WDTPS_128_2
    @DEBUG_REQ        
        @__config config4l, LVP_OFF_4 & ICPRT_OFF_4 & XINST_OFF_4 & DEBUG_OFF_4
    @__config config3h, PBADEN_OFF_3


The PLLDIV_3_1, is the PLL dicision, you can see al PLL divisions here:

PLLDIV_1_1        Oscillator not divided
PLLDIV_2_1        Oscillator divided by 2
PLLDIV_3_1        Oscillator divided by 3
PLLDIV_4_1        Oscillator divided by 4
PLLDIV_5_1        Oscillator divided by 5
PLLDIV_6_1        Oscillator divided by 6
PLLDIV_10_1      Oscillator divided by 10
PLLDIV_12_1      Oscillator divided by 12

This configuration may be added to our code to program directly the Pic micro.

I hope that helps you in your USB projects.

Regards  Grin
« Last Edit: September 09, 2007, 08:23:19 20:23 by Deimos » Logged

Saludos desde Ecuador
iphone
Active Member
***
Offline Offline

Posts: 168

Thank You
-Given: 115
-Receive: 10


« Reply #1 on: September 10, 2007, 04:15:54 16:15 »

Deimos,

Hope you can help me ...

I need to use PIC18Fxxxx with 20 crystal and  I want to set the PIC to run on 40Mhz. So how to do that with PLL ?

Also I need PIC to run on 32Mhz but without crsytal (external) but use only internal osilator (8 Mhz) with PLL ?

Can you make example using  ISIS files ( maybe with some button and led ... just to complete the example) ?

Thanks
Logged
Deimos
Newbie
*
Offline Offline

Posts: 31

Thank You
-Given: 1
-Receive: 14


Whatever...!!!


WWW
« Reply #2 on: September 10, 2007, 07:43:24 19:43 »

I think, that whitout external crystal cant run pic micro to that frecuence, you need to see the data of the specific pic that you need to use.

If you wanna configure de fuses in proton, see the .LPB file  of that micro in the INC folder, ofcourse you need the datasheet too.
Logged

Saludos desde Ecuador
iphone
Active Member
***
Offline Offline

Posts: 168

Thank You
-Given: 115
-Receive: 10


« Reply #3 on: September 11, 2007, 08:04:27 20:04 »

Yes, it's possible ie for PIC18F4410 ... The datasheet for PIC18F4410 said :

Flexible Oscillator Structure:
• Four Crystal modes, Up to 40 MHz
• 4x Phase Lock Loop (PLL) – Available for Crystal
and Internal Oscillators
• Two External RC modes, Up to 4 MHz
• Two External Clock modes, Up to 40 MHz
• Internal Oscillator Block:
- 8 user-selectable frequencies, from 31 kHz to
8MHz
- Provides a complete range of clock speeds
from 31 kHz to 32 MHz when used with PLL
- User-tunable to compensate for frequency drift


So can you give simple example how to configure for 40Mhz (with 20Mhz crstal) and 32Mhz (using internal oscilator) if you can ?

Thanks
Logged
Deimos
Newbie
*
Offline Offline

Posts: 31

Thank You
-Given: 1
-Receive: 14


Whatever...!!!


WWW
« Reply #4 on: September 12, 2007, 05:11:16 05:11 »

Look at the .LPB file  of that micro in the INC folder, in the end of the document is the configuration of the fuses, just copy to your code and change for the values that you need.
Logged

Saludos desde Ecuador
Pages: [1]
Print
Jump to:  


DISCLAIMER
WE DONT HOST ANY ILLEGAL FILES ON THE SERVER
USE CONTACT US TO REPORT ILLEGAL FILES
ADMINISTRATORS CANNOT BE HELD RESPONSIBLE FOR USERS POSTS AND LINKS

... Copyright © 2003-2999 Sonsivri.to ...
Powered by SMF 1.1.18 | SMF © 2006-2009, Simple Machines LLC | HarzeM Dilber MC