Display on LCD

Discussion in 'Embedded Systems and Microcontrollers' started by RG23, Dec 6, 2010.

  1. RG23

    Thread Starter Active Member

    Dec 6, 2010
    301
    2
    I want to count the number of incoming pulses and from that I need to detect the frequency and display it on the LCD.

    I am using PIC 16F887

    Can anyone please help me out?
     
  2. spinnaker

    AAC Fanatic!

    Oct 29, 2009
    4,887
    1,012
    Exactly what help do you need?

    Are you currently displaying anything at all on the LCD?
     
  3. RG23

    Thread Starter Active Member

    Dec 6, 2010
    301
    2
    I am using PIC 16F887 that will count the number of incoming pulses and from that I need to detect the frequency, convert it to ascii and display on LCD.

    Below is a part of code I have tried

    ISR:

    BCF STATUS, RP0
    BCF STATUS, RP1 ; select Register Bank 0
    Loop1: btfsc PIR1,2
    goto Freq_Int
    movf Frequency,0
    movwf PORTD
    call SND_DTA
    Freq_Int: incf Frequency,1
    goto Loop1

    Please let me know if you have any idea.

    Thank you
     
  4. thatoneguy

    AAC Fanatic!

    Feb 19, 2009
    6,357
    718
    Is this a personal project or a school project?

    I'd recommend using C for this application, it typically generates better code than somebody new to assembly. LCD timing can be a bit picky.

    Have you created functional PIC programs before? If so, have any of them either used a timer or written to an LCD?
     
  5. Markd77

    Senior Member

    Sep 7, 2009
    2,803
    594
    I've got some code that could be useful here. It doesen't have the LCD part but it measures a frequency and converts to ASCII then sends it to a computer via serial.
    www.marksphotos.info/fg
     
Loading...