12f675 serial pic2pic


Results 1 to 5 of 5

Threaded View

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


    Did you find this post helpful? Yes | No

    Default

    could be many things here. But at least, can you confirm all of the following tests
    1. Is a simple led blink work on both of your PIC
    2. Is the LCD work on your 16F877

    Another thing... is the SERIN Idle state may cause you a grief? idle what? look at the following post...
    http://www.picbasic.co.uk/forum/show...86&postcount=5

    Be sure you set the transmitter pin to the corect state before sending something.

    You DEFINE OSC is not correctly writen.. no problem anyway, it will not be considered. Chances are that the default OSC is 4. DEFINE spelling and writing is often discussed here... almost every week/month. They must be written as state in the manual, in UPPERCASE.
    DEFINE OSC 4 without any underscore.

    Also, when using 12Fs with internal osc in a serial comm, you should consider using the OSCCAL value to ensure a better Oscillator precision. Personnally i always use it, serial comm or not. it's just a simple code line after all

    SET OSCCAL_1K 1

    If you have a good device programmer, and if you're lucky, the OSCAL value is still there. To check it, just read your PIC and look at the last memory location... should different of 3fff

    what else... maybe enough to start i guess

    what about ...
    Code:
    ' 12F675
    @ DEVICE INTRC_OSC, WDT_OFF, MCLR_OFF, PWRT_ON 
    DEFINE OSCCAL_1K 1
    DEG VAR BYTE
    CMCON=7
    ANSEL=0
    TRISIO.0=0
    GPIO.0=0    ' Set corect idle state
    DEG=1
    
    BASLA:
        PAUSE 3000
        SEROUT2 GPIO.0,16780,["A",DEG]
        PAUSE 200
        goto BASLA
    You don't need to attach the R/W pin of your LCD to the PIC if you don't plan to read from. Just connect it to GND.
    Last edited by mister_e; - 12th March 2006 at 22:37.
    Steve

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

Similar Threads

  1. Replies: 33
    Last Post: - 19th March 2010, 03:02
  2. Dynamic USB Serial Number (PIC18F4550)
    By awmt102 in forum mel PIC BASIC Pro
    Replies: 4
    Last Post: - 16th July 2009, 17:03
  3. PIC18F4680 to PC via MAX232 (RS232 serial) no output
    By opticsteam1 in forum mel PIC BASIC Pro
    Replies: 2
    Last Post: - 14th April 2008, 20:39
  4. interfacing to the pc serial port
    By kelangfei in forum General
    Replies: 4
    Last Post: - 7th October 2007, 22:35
  5. Serial LCD on 12F675
    By anj in forum mel PIC BASIC Pro
    Replies: 4
    Last Post: - 31st March 2004, 23:11

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