What is theabsolutely minimal hardware to run BLINK with a PIC18F4620?


Closed Thread
Results 1 to 13 of 13

Hybrid View

  1. #1
    Join Date
    Aug 2006
    Location
    Look, behind you.
    Posts
    2,818


    Did you find this post helpful? Yes | No

    Default Re: What is theabsolutely minimal hardware to run BLINK with a PIC18F4620?

    Hi Brian,
    I would guess it's something in the default configs that is/are? at odds with your code, better to hand code the configs so you know what you have.
    DEFINE OSC ??
    Last edited by Archangel; - 30th October 2013 at 02:02.
    If you do not believe in MAGIC, Consider how currency has value simply by printing it, and is then traded for real assets.
    .
    Gold is the money of kings, silver is the money of gentlemen, barter is the money of peasants - but debt is the money of slaves
    .
    There simply is no "Happy Spam" If you do it you will disappear from this forum.

  2. #2
    Join Date
    Nov 2003
    Location
    Greece
    Posts
    4,131


    Did you find this post helpful? Yes | No

    Default Re: What is theabsolutely minimal hardware to run BLINK with a PIC18F4620?

    Bit 7 of OSCCON, should not be a zero?

    Ioannis

  3. #3
    Join Date
    Apr 2007
    Location
    Pennsylvania, USA
    Posts
    158


    Did you find this post helpful? Yes | No

    Default Re: What is theabsolutely minimal hardware to run BLINK with a PIC18F4620?

    bit 7 only matters if using sleep

    add led1=0 near the beginning of your code

    You should also define the osc to 08
    Shawn

  4. #4
    Join Date
    May 2008
    Location
    Italy
    Posts
    825


    Did you find this post helpful? Yes | No

    Default Re: What is theabsolutely minimal hardware to run BLINK with a PIC18F4620?

    Try

    OSCCON = %01111000
    OSCTUNE = %01000000
    DEFINE OSC 32

    I use "INTIO2" but your setting should make no difference if you don't use osc pins as digital in/out.

    Cheers

    Al.
    All progress began with an idea

  5. #5
    Join Date
    Sep 2010
    Location
    Las Vegas, NV
    Posts
    305


    Did you find this post helpful? Yes | No

    Default Re: What is theabsolutely minimal hardware to run BLINK with a PIC18F4620?

    I'm not the best at reading the manual for this chip but from what I read on the data sheet OSCTUNE = %01000000 bit 6(PLLEN) can only be used with a 4 or 8 MHz oscillator.

    OSCCON = %01111000 defines a 8 MHz internal oscillator. I think the first part should be of OSCCON should be OSCCON = %011111xx that defines an internal stable oscillator. I don't understand what the last two bits do so that would take some more exploration. It looks like you've got a plethora of options that depend on your specific situation.

    In smaller chips the port usually needs to be set to digital for LEDs to light. I couldn't figure out how to do that for this chip.

    Also, if the LED takes 2.2 volts of the 5 volts applied that leaves 2.8 volts for the 1k resistor. That's only 2.8 milliamps if the chip doesn't drop any voltage. I think that's low and am surprised it will light with 5 volts applied.

    I hope it helps.

  6. #6
    Join Date
    Jan 2005
    Location
    Montreal, Quebec, Canada
    Posts
    3,154


    Did you find this post helpful? Yes | No

    Default Re: What is theabsolutely minimal hardware to run BLINK with a PIC18F4620?

    He is using high brightness LEDs. They might consume less than the average 20mA used by common LEDs (might be very high efficiency LEDs).

    Robert

Similar Threads

  1. ADCIN with PIC18F4620
    By Brian J Walsh in forum mel PIC BASIC Pro
    Replies: 1
    Last Post: - 4th July 2008, 01:25
  2. PIC18F4620 Troubles
    By CluckShot in forum mel PIC BASIC Pro
    Replies: 6
    Last Post: - 16th May 2007, 03:02
  3. pic18f4620 and flashlab77
    By igeorge in forum mel PIC BASIC Pro
    Replies: 3
    Last Post: - 5th November 2006, 01:00
  4. LCD + keyboard matrix minimal I/O
    By RFsolution in forum mel PIC BASIC Pro
    Replies: 5
    Last Post: - 21st June 2006, 19:49
  5. Sound and sound control with minimal parts
    By bartman in forum General
    Replies: 23
    Last Post: - 18th January 2005, 14:08

Members who have read this thread : 0

You do not have permission to view the list of names.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts