pic18f2620 freezing


Closed Thread
Results 1 to 5 of 5
  1. #1
    Join Date
    Jan 2005
    Location
    Puerto Rico
    Posts
    133

    Default pic18f2620 freezing

    Hello is some one have this problems and fix it help me..

    my pic work but when i on plug a hall sensor and my pic freezing ..

    My Hobbies is PicBasic PRO

  2. #2
    Join Date
    Mar 2003
    Location
    Commerce Michigan USA
    Posts
    1,166


    Did you find this post helpful? Yes | No

    Default

    jetpr, I use 18F2620's for just about all of my projects and products at work. I have never had such a problem.. Code please?

    Dave Purola,
    N8NTA

  3. #3
    Join Date
    Jan 2005
    Location
    Puerto Rico
    Posts
    133


    Did you find this post helpful? Yes | No

    Lightbulb

    RPM=0
    RPMSamp=0
    RPMSamp1=0
    RPMSamp2=0
    '** RPM **
    '60 ms Sample time yields direct RPM readout in 1000's
    'Comments start with real RPM of 143,578 and RPMNumSamps=3
    Count tachPin, 60 * RPMNumSamps, RPMSamp 'RPMSamp = 430
    RPMSamp = RPMSamp * 10 'RPMSamp = 4300
    ' pause 20
    ' Count tachPin, 60 * RPMNumSamps, RPMSamp2 'RPMSamp = 430
    ' RPMSamp2 = RPMSamp2 * 10 'RPMSamp = 4300
    ' RPMSamp=(RPMSamp1+RPMSamp2)/2
    RPM = RPMSamp / (RPMNumSamps * 10) 'RPM = 143
    IF NOT RPMNoDecimal Then 'Calculate the tenths if RPMNoDecimal = 0
    RPML = RPMSamp // (RPMNumSamps * 10) 'RPML = 10
    RPML = RPML / RPMNumSamps 'RPML = 3
    EndIF
    My Hobbies is PicBasic PRO

  4. #4
    Join Date
    Nov 2003
    Location
    Wellton, U.S.A.
    Posts
    5,924


    Did you find this post helpful? Yes | No

    Default

    Is that the whole code?
    Dave
    Always wear safety glasses while programming.

  5. #5
    Join Date
    Sep 2004
    Location
    montreal, canada
    Posts
    6,898


    Did you find this post helpful? Yes | No

    Default

    Well, I guess not But poor PCB layout, schematic, PSU filtering could indeed produce few unwanted issue, that's for sure.

    Latch-up caused by a high voltage spike on MCLR (entering programming mode) could be one source. The whole schematic, board layout and whole code would definitely help
    Steve

    It's not a bug, it's a random feature.
    There's no problem, only learning opportunities.

Similar Threads

  1. Need help with a pulse counter project PIC18F2620
    By blackrider in forum Schematics
    Replies: 1
    Last Post: - 29th April 2009, 00:08
  2. Freezing PIC !
    By PICante in forum General
    Replies: 15
    Last Post: - 18th September 2008, 16:27
  3. Help pic18f2620
    By jetpr in forum mel PIC BASIC Pro
    Replies: 3
    Last Post: - 1st February 2008, 02:09
  4. Serout2 pic18f2620
    By cerio in forum mel PIC BASIC Pro
    Replies: 4
    Last Post: - 23rd May 2007, 23:06
  5. PIC18F2620 "out of memory"??
    By Ron Marcus in forum mel PIC BASIC Pro
    Replies: 8
    Last Post: - 3rd January 2006, 01:01

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