no text on LCD


Closed Thread
Results 1 to 31 of 31

Thread: no text on LCD

Hybrid View

  1. #1
    Join Date
    Jun 2007
    Posts
    19


    Did you find this post helpful? Yes | No

    Default

    why is it that when i copy any of these text files and try to convert it in to a hex file it always shows up with lots of errors, about 60 errors each time.

    therefore i can not copy any of these files and download them on to the micro controller as it is not creating a hex file.
    But the code i have written shows with no errors anymore just warnings.

    am i doing something wrong?
    i normaly create a text file in notepad, then i use MPASM to convert the text file in to a HEX file, i then use PROGPIC 2 along with my velleman hardware programmer board to download on to the PIC, it has worked on other PIC such as 16F627 to create effects such as flashing LED's.

    i downloaded that file of yours mel, when an LED is connected between pin A0 and +5v it constantley flashes almost 1 sec on 1 sec off, all other data lines on the LCD are now grounded and a 10k pot between +5V and 0V with the wiper conn to V0 (contrast), adjustment of the pot varies the contrast but still no luck wit writing on lcd, still shows as 2 rows of blocks on line 1 and 3.
    Last edited by Dj tempo; - 19th June 2007 at 14:50.

  2. #2
    malc-c's Avatar
    malc-c Guest


    Did you find this post helpful? Yes | No

    Default

    If the PIC is flashing the LED then the device is running OK

    You say you use Notepad to generate the HEX code via MPSAM. Why not try downloading the MPLAB from Microchip and use its editor to edit the code and then save the file as an ASM format and then quickbuild the project. I did this with the "final lcd code 2" text copied from your original post on 17th. However whilst it compiles fine, it still throws up a few warnings that might give others a hint as to what might be wrong ?
    Code:
    Clean: Deleting intermediary and output files.
    Clean: Done.
    Executing: "C:\Program Files\Microchip\MPASM Suite\MPAsmWin.exe" /q /p16F84 "lcdtest.asm" /l"lcdtest.lst" /e"lcdtest.err"
    Warning[205] C:\LCDTEST.ASM 13 : Found directive in column 1. (__CONFIG)
    Warning[202] C:\LCDTEST.ASM 20 : Argument out of range.  Least significant bits used.
    Warning[202] C:\LCDTEST.ASM 28 : Argument out of range.  Least significant bits used.
    Warning[224] C:\LCDTEST.ASM 434 : Use of this instruction is not recommended.
    Warning[224] C:\LCDTEST.ASM 436 : Use of this instruction is not recommended.
    Warning[224] C:\LCDTEST.ASM 438 : Use of this instruction is not recommended.
    Warning[205] C:\LCDTEST.ASM 598 : Found directive in column 1. (END)
    Loaded C:\lcdtest.COD.
    BUILD SUCCEEDED: Tue Jun 19 16:02:30 2007

  3. #3
    malc-c's Avatar
    malc-c Guest


    Did you find this post helpful? Yes | No

    Default

    Doing the same with Mister-e's code it compiles fine without any errors

    Code:
    Clean: Deleting intermediary and output files.
    Clean: Done.
    Executing: "C:\Program Files\Microchip\MPASM Suite\MPAsmWin.exe" /q /p16F84A "mretest.asm" /l"mretest.lst" /e"mretest.err"
    Loaded C:\mretest.COD.
    BUILD SUCCEEDED: Tue Jun 19 16:13:21 2007
    I just don't have the hardware to test the resulting HEX file with a 4 line LCD

  4. #4
    Join Date
    Jun 2007
    Posts
    19


    Did you find this post helpful? Yes | No

    Default

    do you mean MPLAB IDE 7.60? as i have just downloaded.
    what do you mean by quick build?

    i have tried many files including those of nigels but i still have problems converting to a HEX file.

  5. #5
    malc-c's Avatar
    malc-c Guest


    Did you find this post helpful? Yes | No

    Default

    I have ver 7.50, but its more or less the same.

    Copy Mister_e's code from the post above. launch MPLAB and select FILE > NEW from the tool bar options. A blank window will appear called UNTITLED and the cursor will be blinking at the top left.

    Paste the code into the window, the window will change to UNTITLED*

    Select CONFIGURE > SELECT DEVICE from the toolbar options, and select the chip you are using from the drop down list and click OK

    Select FILE > SAVE AS from the toolbar options and select the root of the C drive as the location to save the file to. Give it a name, say LCD and in the file type select the second option ( Assembly source files). Now click on SAVE - The window will now be titled LCD.asm

    From the toolbar select PROJECT > QUICKBUILD LCD.ASM

    The MPSAM window should pop up and compile the code, and a window called OUTPUT should appear with the summary of the build.

    You should then be able to locate the LCD.HEX file in the root of C:

    Hope this helps

  6. #6
    Join Date
    Jun 2007
    Posts
    19


    Did you find this post helpful? Yes | No

    Default

    so far so good untill i select quick build.
    it says (no.asm file)
    do i have to upload the file to it somehow?
    if i click open it will only let me load an .mcp file
    Last edited by Dj tempo; - 19th June 2007 at 21:36.

  7. #7
    skimask's Avatar
    skimask Guest


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by Dj tempo View Post
    so far so good untill i select quick build.
    it says (no.asm file)
    do i have to upload the file to it somehow?
    Make sure the window that is showing the .asm file is 'highlighted' (has the focus, active, whatever you want to call it), then click the quick build menu option.

  8. #8
    malc-c's Avatar
    malc-c Guest


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by Dj tempo View Post
    so far so good untill i select quick build.
    it says (no.asm file)
    do i have to upload the file to it somehow?
    if i click open it will only let me load an .mcp file
    So let me confirm that you have pasted the text into that window, then saved it to the root of C: as an asm file ( don't just click on save as it will default to the first file format in the list). If there is text in that window, and its saved as an asm file, its hilighted, then there should be no reason why the project won't quick build, or at least none that I can see

Similar Threads

  1. Replies: 2
    Last Post: - 5th November 2009, 17:07
  2. 16f688 LCD what have I done wrong
    By spitfiredriver in forum mel PIC BASIC Pro
    Replies: 6
    Last Post: - 8th August 2009, 19:54
  3. Play with LCD on PICDEM
    By The IceMan in forum mel PIC BASIC
    Replies: 5
    Last Post: - 22nd August 2008, 16:56
  4. LCD issue with EasyPIC5
    By manwolf in forum mel PIC BASIC Pro
    Replies: 12
    Last Post: - 15th June 2008, 09:17
  5. LCD will not start
    By btaylor in forum mel PIC BASIC Pro
    Replies: 49
    Last Post: - 24th May 2007, 02:30

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