Auto Baud Rate Detection


Results 1 to 11 of 11

Threaded View

  1. #10
    mytekcontrols's Avatar
    mytekcontrols Guest

    Arrow Aotobaud Detect on 18F2525: A progress report...

    Hi you all,

    I got some 18F2525's yesterday. First thing I had to do was go to my workshop and put together an In-Circuit Serial Programming adapter for my new chip (I'm running this directly on a StampVue production board which doesn't have an ICSP). Previously I had been making due with this ugly thing pictured below:



    But I thought it was about time I came up with a better solution. Something that would allow me to pop in any 28 pin device for testing purposes. So the "Ugly Blob" is no more, and in steps my "Universal 28 PDIP ICSP adapter".



    All fun aside, lets get down to some actual tests.

    Well I thought: "What the heck, this thing is an 18F series device, and the previous 18F252 was also. I'll just plug it in, don't change my code, and see what happens".

    Well you probably know the answer to this one. Of course it didn't work, I ended up getting no video output on my StampVue production board. Hmm... what was wroung. I took out the scope probe and discovered some of my PortB pins were not producing the signals that they should, and then it hit me. Looking at the data sheet showed me that some of these pins are multiplexed as additional analog inputs, something that the 18F252 did not have.

    So I needed to change the initialization value for ADCON1 to reflect my desire to have all the PORTB pins be Digital I/O, and only AN0 - AN4 be analog inputs (ADCON1 = %00001010). So now I got my PORTB outputs back, and also my video functions were restored as a result. However I noticed my analog inputs were not working. Delving back into the datasheet also showed that some rearranging, and an additional register had been added to deal with the added analog capability. The GO/DONE bit had been moved from bit2 of ADCON0 to bit1 instead. This allowed them to increase the channel selection bits from 3 to 4, by shifting the GO/DONE bit to the right. Also some of the other functions such A/D oscillator selection had been moved to a new register ADCON2.

    After I got all of this sorted out, everything was once again working correctly (or should I say, I think it is).

    Melanie and Steve, can you guys think of any other register changes that could cause potential conflicts when porting over to the 18F2525 from an 18F252? Like I said everything appears to be ok now that I have adjusted things in the ADCON registers.

    Anyway, today I will try to run some tests on the AutoBaud Feature of the 18F2525's EUSART, and let you know what I find out.
    Attached Images Attached Images   

Similar Threads

  1. A Serial GLCD 128x64 Simple Project
    By Oldspring in forum Off Topic
    Replies: 0
    Last Post: - 8th March 2010, 20:58
  2. AUTO baud rate detection FOR UART connection to PC
    By mike20200 in forum mel PIC BASIC Pro
    Replies: 2
    Last Post: - 3rd September 2007, 00:56
  3. PIC12F675, accuracy of baud rate with Internal Oscillator
    By Chris Mayhew in forum mel PIC BASIC Pro
    Replies: 3
    Last Post: - 31st August 2005, 22:41
  4. Automatic Baud Rate Detection
    By titanvision in forum Off Topic
    Replies: 7
    Last Post: - 4th August 2005, 03:43
  5. Baud Rate and Timing Calculator
    By picnaut in forum General
    Replies: 3
    Last Post: - 23rd January 2004, 16:48

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