![]() | ![]() | ![]() |
| | |||||||
| Micro Controllers Discuss all aspects of micro controllers - building them, coding them, etc. All controllers are welcome - PIC, BASIC, Z8 Encore!, etc. |
| | LinkBack (1) | Thread Tools | Display Modes |
| |
(permalink)
|
| hi i have a PIC board with input and output pins down the sides, this board was designed for the 16f84, i know the 16f628a uses the same pins but i have found that the 16f628a has an internal oscillator, My board has a 4mhz crystal on it. The question can i just stick the 16f628a in place of the 16f84 or do i need to remove the oscillator? if i can just stick the 16f628a in place do i need to disable the internal oscillator or will it just sort itself out? thanks | |
| |
| | (permalink) | |
| Quote:
If you check on the MicroChip website there's a 'migration document', giving details of what you need to change for upgrading from 84 to 628. Basically you just need to disable the comparators, it takes two lines, if you check my tutorials they all do it, and it's clearly commented. So add the two lines to your source code, alter the header lines and config fuse settings, and reassemble the code. That's all you need to do!, there's no hardware changes at all. | ||
| |
| | (permalink) |
| thanks for the help, im actually using basic to program the chip, do i still have to follow the same steps? but just do it with basic coding? thanks | |
| |
| | (permalink) | |
| Quote:
| ||
| |
| | (permalink) | ||
| Quote:
thanks for the help | |||
| |
| | (permalink) |
| Nigel, The 628 pic has it's own power-up timer reset. I am having a problem with one application where this 100mS delay is too short as the supply comes up slower and cause the micro to lock up sometimes. What is the correct thing to do, go back to external timing components? Also when should brown-out bit be enabled? Thanks TO | |
| |
| | (permalink) | |||
| Quote:
Anything like this is down to your particular BASIC compiler, how do you currently tell it to use a 4MHz oscillator?. The 16F84 has a number of different oscillator options, if the right one isn't selected it won't work - the 628 is no different, it needs telling which option to use. As you're using BASIC, this is ENTIRELY down to the compiler, the instructions should tell you how to do it. | ||||
| |
| | (permalink) | |
| Quote:
Failing that, use an external reset circuit that will hold the reset pin low for longer than the PSU takes to come up. | ||
| |
| | (permalink) |
| The PSU I have no control over as this board get's installed by various customers on their own power supplies. I can only make a recommendation to the supply they should use but customers often like to follow their own will. Also can someone indicate when the brown-out bit should be used. I have read somewhere that enabling this sometimes causes more problems than it is supposed to fix? | |
| |
| | (permalink) | ||
| Quote:
Quote:
| |||
| |
| | (permalink) | ||||
| Quote:
At the begining of your code , you should set the config fuses. One of these being " xt_osc or hs_osc" to set external xtal. the following is copied from the proton manual configuration fuse settings vary from PICmicro to PICmicro, however, certain settings are standard to most PICmicro types. These are: - WDT_ON Enable the internal Watchdog timer. WDT_OFF Disable the internal Watchdog timer. HS_OSC Use a High-speed crystal (Xtals over 4MHz) . XT_OSC Use a standard crystal (4MHz or under). LP_OSC Use a low frequency crystal (KHz range). PWRTE_ON Enable power up timer. PWRTE_OFF Disable power up timer. Example ' Disable the Watchdog timer and specify an HS_OSC etc, on a PIC16F877 device CONFIG HS_OSC , WDT_OFF , PWRTE_ON , BODEN_OFF , LVP_OFF , WRTE_ON , CP_OFF , DEBUG_OFF | |||||
| |
| | (permalink) |
| Hello, I am new in microcontrollers and all projects I did were with PIC16F84A. I want to migrate one project (fading up/down LED) to a PIC16F627A, and I don’t know how to do that. I searched on the microchip web page, but didn’t find it. Any help is welcome. José Flor Last edited by joseflor; 6th September 2007 at 09:18 AM. | |
| |
| | (permalink) |
| | |
| |
| | (permalink) | |
| Quote:
I did a very long code with a lot of PWM. How do I change that code for Fade up and down in a total of 10 seconds? Cheers José Flor | ||
| |
| | (permalink) |
| Ups, I figured out the problem. I did a few changes in the code but I was burning the original code. Being the case I couldn’t see it working differently. I'm sorry for this inconvenient. José Flor | |
| |
| Bookmarks |
| Thread Tools | |
| Display Modes | |
| |
| LinkBack to this Thread: http://www.electro-tech-online.com/micro-controllers/12479-pic-16f84-16f628a-question.html | ||||
| Posted By | For | Type | Date | |
| Como passar (código) do PIC16F84A para o PIC16F627A — Eletronica.org | This thread | Refback | 17th May 2008 05:58 PM | |