Migrate from 16F628 to 16F628A


Closed Thread
Results 1 to 11 of 11

Hybrid View

  1. #1
    Join Date
    Jul 2003
    Posts
    2,358


    Did you find this post helpful? Yes | No

    Default

    There is no significant difference between a 628 and a 628A. Code for one will run without changes on the other.

    However, any form of timing critical functions (such as SEROUT, SERIN etc) on INTERNAL OSCILLATOR is suspect. Just because it worked on a 628 (non-A) means you were lucky. If the world was flat, then you were sailing on the edge. Take a random sample of PICs, and some will have their Internal Oscillators spot on, and others will be off significantly to corrupt asynchronous data. Fit a Resonator or Xtal, switch to XT or HS Osc, and your troubles will disappear. Either that, or go buy a really big selection of PICs and outsort the ones that work...

    I used to say, never go above 300 Baud on Internal Oscillator, but I've had batches of chips where even that wasn't reliable.

  2. #2
    Join Date
    May 2005
    Location
    Minnesota
    Posts
    31


    Did you find this post helpful? Yes | No

    Default Thanks for fast response

    I will attach an external resonator on the 628A in a few hours.

    With all the programs I have writen using SerOut, I have never experienced this.

    I'll let you know how it goes.

    Many thanks.

    Brad

  3. #3
    Join Date
    Nov 2005
    Location
    Bombay, India
    Posts
    967


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by Melanie
    There is no significant difference between a 628 and a 628A.However, any form of timing critical functions (such as SEROUT, SERIN etc) on INTERNAL OSCILLATOR is suspect. Just because it worked on a 628 (non-A) means you were lucky. I used to say, never go above 300 Baud on Internal Oscillator, but I've had batches of chips where even that wasn't reliable.
    Melanie

    I do not quite understand your statements. I use the 628A on a regular basis with 9600 baud for SERIN2 and SEROUT2 with no problems till now. Can you please clarify if this is something to watch out for as a gotcha ??

    Jerson

  4. #4
    Join Date
    Jul 2003
    Posts
    2,358


    Did you find this post helpful? Yes | No

    Default

    But are you using it with the PIC set to INTERNAL OSCILLATOR?

  5. #5
    Join Date
    Nov 2005
    Location
    Bombay, India
    Posts
    967


    Did you find this post helpful? Yes | No

    Default Yes, using Int Osc @ 4 MHz

    Melanie

    Yes, I always use the internal osc. No problems yet.

    Jerson

  6. #6
    Join Date
    Jul 2003
    Posts
    2,358


    Did you find this post helpful? Yes | No

    Default

    Then you have been very lucky so far.

    The Internal Oscillator is rarely on-frequency, it drifts with temperature and has the stability of a political manifesto at election time. The higher the baud rate, the greater the error margin. If you send or receive a short burst, the few bytes might be within spec, but thereafter you will drift out of specification and communication will be corrupted.

    The rule is always to use a Resonator or Xtal when doing timing critical functions.

  7. #7
    Join Date
    Nov 2005
    Location
    Bombay, India
    Posts
    967


    Did you find this post helpful? Yes | No

    Default maybe

    Hi Melanie

    Well, lucky perhaps. But, the most times, I have used the Serout / Serin functions as a handshake and they carry very little traffic. My products usually power off to a sleeping state which is around 90-95% of their working time. So, perhaps this is where I am lucky.

    I can see your point about the internal oscillator drifting with time and temperature; and will keep it at the back of my mind for projects involving longer running times for serial communications.

    Hey, btw : I like your analogy about the election manifesto. Looks like none of 'em politicians have reached me yet

    Cheers
    Jerson

  8. #8
    Join Date
    May 2005
    Location
    Minnesota
    Posts
    31


    Did you find this post helpful? Yes | No

    Default Installed ext resonator

    Well, that worked. Thanks. I have to attach resonators to SSOP packages. Quite a few of them.

    One more question, please;
    The package type is a 16LF628A. Data sheet says it will operate at 2.5 volts. What do I need to do to get it to run on the low voltage? I have a 3 volt regulator in the circuit, and it does not run. At all. Even blinking a LED.

    Thanks again.

    B

Similar Threads

  1. 16f628 / 16f628a
    By azmax100 in forum General
    Replies: 5
    Last Post: - 27th January 2009, 03:37
  2. Are 16f628 and 16f628A difference each other?
    By elektrodam in forum mel PIC BASIC Pro
    Replies: 8
    Last Post: - 15th July 2006, 06:20
  3. SERIN2 not working with 16F628
    By d1camero in forum mel PIC BASIC Pro
    Replies: 3
    Last Post: - 6th May 2004, 20:37
  4. HSEROUT and 16F628A
    By fredblah in forum mel PIC BASIC Pro
    Replies: 1
    Last Post: - 6th May 2004, 00:07
  5. 16F628 on-chip eeprom problem
    By atomski in forum mel PIC BASIC Pro
    Replies: 16
    Last Post: - 4th March 2004, 07:43

Members who have read this thread : 1

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