help to program an PIC with MPLAB


Closed Thread
Results 1 to 5 of 5
  1. #1
    Join Date
    Apr 2009
    Posts
    4

    Unhappy help to program an PIC with MPLAB

    Hi,

    I'm new to pic programming and I need help wth this assignment.

    I bought an picKit 2, and now I can't prog an PIC 16F627,
    i'm programming in c.

    I'm using MPLAB v8.10, and I don't know if it is bad configuration
    about set language tool location... or what...

    I can't produce a hex file with MPLAB v8.10 for PIC 16F627,
    it appears those errors below. I have tried many ways to alter this
    but it is allways the same errors .

    I set those configurations when I initiated the project programming
    Active Toolsuite:
    Toolsuite Contents:
    C:\..\PICC\Ccsc.exe

    MPLAB IDE v8.10

    Active Toolsuite:
    CCS C Compiler for PIC10/12/14/16/18/24/dsPIC30/dsPIC33

    Toolsuite Contents
    CCS C Compiler (ccsc.exe)

    C:\..\PICC\Ccsc.exe

    Executing: "C:\progPICS\PICC\Ccsc.exe" +FM "teste_01.c" +DF +LN +T +A +M +Z +Y=9 +EA

    *** Error 24 "C:\PROGPICS\PICC\devices\16F627.h" Line 2(9,18): Unknown device type
    1 Errors, 0 Warnings.

    --------------------------------------------------------------------------------------
    --------------------------------------------------------------------------------------

    when I altered to HI-TECH programming

    Active Toolsuite:
    Toolsuite Contents:
    C:\..\PICC\PRO\9.65\bin\picc.exe

    Active Toolsuite:
    HI-TECH Universal ToolSuite

    Toolsuite Contents:
    HI-TECH ANSI C Compiler


    C:\..\PICC\PRO\9.65\bin\picc.exe

    If anybody can help me I would appreciate it.

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


    Did you find this post helpful? Yes | No

    Default

    Without code and such it's a bit hard to answer that.

    Not sure for CCS, but it might just be because you have the demo version. Still, 16F627 is an old one, 16f627A is the "new" version, much recommended.

    I'm much a fan of Hi-Tech C rather than CCS... not impressed at all with CCS... probably one of the many reason why Microchip Bought Hi-Tech company instead of CCS

    Anyways, here it's Melabs PicBasic forum, questions about Mplab third-party tool would be better answered on Microchip forum (http://www.microchip.com/forums/Default.aspx?) or via their tech support (http://support.microchip.com/scripts...=webticketcust) or still via the respective third-party forums.
    Steve

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

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


    Did you find this post helpful? Yes | No

    Default

    Oh BTW, 16F627 is not supported by PICKIT 2 in MPLAB (8.30 here) but only in PICKIT 2 standalone application.

    16F627A is supported in MPLAB & in the standalone application.
    Steve

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

  4. #4
    Join Date
    Apr 2009
    Posts
    4


    Did you find this post helpful? Yes | No

    Default

    Thanks for your interest.

    If you says that 16F627 isn't supported by PICKIT 2 in MPLAB. And that seems to be right to me. So, how do I can program this pic. You say that you use HI-TECH C, where do I get that software?
    I think I will need a different bootloader than that I used with for CCS...
    Sorry, i'm a bit without any direction to go on ...

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


    Did you find this post helpful? Yes | No

    Default

    Download the latest MPLAB version on Microchip website, and install Hi-Tech C pro, in Lite mode.
    http://www.microchip.com/stellent/id...&part=SW007002

    OR go on Hi-Tech website, and download it from there
    http://www.htsoft.com/microchip/downloads/demos.php

    Here's the link for Hi-Tech compiler forum
    http://forum.htsoft.com/all/ubbthreads.php

    If you really have the ol' version of 16F627, you generate the .HEX files in MPLAB (when you compie your code, then import it in the PICKIT 2 standalone application, then program your PIC from there.
    Steve

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

Similar Threads

  1. Looking at pic basic pro symbol values in mplab 8.15a simulator
    By ukemigrant in forum mel PIC BASIC Pro
    Replies: 10
    Last Post: - 16th May 2009, 13:18
  2. Pic Start Plus Help
    By shawn in forum mel PIC BASIC Pro
    Replies: 4
    Last Post: - 7th March 2007, 03:47
  3. Which pic has a big flash program memory?
    By amindzo in forum mel PIC BASIC Pro
    Replies: 4
    Last Post: - 1st November 2006, 19:35
  4. Matching PIC memory and program size?
    By manxman in forum mel PIC BASIC Pro
    Replies: 8
    Last Post: - 9th August 2006, 08:02
  5. Serial communication PIC to PIC help.
    By Rubicon in forum mel PIC BASIC Pro
    Replies: 3
    Last Post: - 24th January 2005, 15:45

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