dumb question


Closed Thread
Results 1 to 40 of 94

Thread: dumb question

Hybrid View

  1. #1
    Join Date
    Nov 2003
    Location
    Wellton, U.S.A.
    Posts
    5,924


    Did you find this post helpful? Yes | No

    Default

    What!?! No resistors? That is like coming to class with out a pencil.

    Vista is ok.

    Do you mean the EEPROM that is built into the PIC. Use the same connection as you have when programmng
    Dave
    Always wear safety glasses while programming.

  2. #2
    Join Date
    Nov 2003
    Location
    Wellton, U.S.A.
    Posts
    5,924


    Did you find this post helpful? Yes | No

    Default

    Did you get a demo board with the PicKit? The one with LEDs and buttons and ...
    If you did you can start playing now. The 628 can happen later.
    Dave
    Always wear safety glasses while programming.

  3. #3
    Join Date
    Aug 2009
    Posts
    56


    Did you find this post helpful? Yes | No

    Default

    I have the board,then,Im ready to play!
    Last edited by osceola; - 22nd August 2009 at 21:00.

  4. #4
    Join Date
    Aug 2009
    Posts
    56


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by mackrackit View Post
    What!?! No resistors? That is like coming to class with out a pencil.

    Vista is ok.

    Do you mean the EEPROM that is built into the PIC. Use the same connection as you have when programmng
    No,not the EEPROM that is built into the PIC,a normal EEPROM,24LC512,and I havent find any datasheets to look at how you have to connect the EEPROM to the PICKIT2 board

  5. #5
    Join Date
    Nov 2003
    Location
    Wellton, U.S.A.
    Posts
    5,924


    Did you find this post helpful? Yes | No

    Default

    Lets worry about the eeprom a bit later.

    I want you to read this
    http://www.picbasic.co.uk/forum/showthread.php?t=543
    We will be setting the fuses in your code, in the long run this seems to be the best way. Later when you go back to a program you will not have to remember how you had them set.

    Now I am going to assume you have the low pin count board with the 16F690 on it?
    Dave
    Always wear safety glasses while programming.

  6. #6
    Join Date
    Aug 2009
    Posts
    56


    Did you find this post helpful? Yes | No

    Default

    Yes,PIC16F690.Im reading.....
    Last edited by osceola; - 23rd August 2009 at 00:02.

  7. #7
    Join Date
    Aug 2009
    Posts
    56


    Did you find this post helpful? Yes | No

    Default

    http://www.picbasic.co.uk/forum/showthread.php?t=543
    So basicly if Im using MPLAB IDE and MPASM as assembler this tools will be located in the MPLAB IDE folder under the aplication Maestro?

  8. #8
    Join Date
    Nov 2003
    Location
    Wellton, U.S.A.
    Posts
    5,924


    Did you find this post helpful? Yes | No

    Default

    For now use Micro Code Studio and MPASAM as the assembler. I am hearing about problems with MPLAB right now.
    The file you need to comment the lines in is in the PBP directory.

    Assuming you have the 16F690.inc file commented on the correct lines like the above thread shows... This code should have a couple LEDs blinking.

    Code:
    '16F690 DEMO
      '  DEFINE OSC 8       'Comment the 4Mhz and uncomment these for 8Mhz
      '  OSCCON=%01110000
    
        DEFINE OSC 4           'This is the default setting
        OSCCON=%01100000
          
        'The first line is if you are using PM, the second if you are using MPASAM
      '  @ device  pic16F690, intrc_osc_noclkout, wdt_on, mclr_on, protect_off
        @ __config _INTRC_OSC_NOCLKOUT & _WDT_ON & _MCLRE_ON & _CP_OFF
      
        'VARS
        LED1    VAR PORTC.0
        LED2    VAR PORTC.1
        
        START:
        HIGH LED1
        LOW  LED2
        PAUSE 250
        LOW  LED1
        HIGH LED2
        PAUSE 250
        GOTO START
    This should do the same as the above code but in a different way.
    Code:
    '16F690 DEMO_2
      '  DEFINE OSC 8       'Comment the 4Mhz and uncomment these for 8Mhz
      '  OSCCON=%01110000
    
        DEFINE OSC 4           'This is the default setting
        OSCCON=%01100000
          
        'The first line is if you are using PM, the second if you are using MPASAM
      '  @ device  pic16F690, intrc_osc_noclkout, wdt_on, mclr_on, protect_off
        @ __config _INTRC_OSC_NOCLKOUT & _WDT_ON & _MCLRE_ON & _CP_OFF
        
        TRISC = %00000000   '0 will make the pins an output, 1 will make them inputs
        
        START:
        PORTC = %00000001
        PAUSE 250
        PORTC = %00000010
        GOTO START
    I do not have the demo board that you have, so I hope I did not make a mistake.
    Play with these and look in the manual to see how to add a button for an input.
    Then change things so when the button is pressed the LEDs blink differently.
    Dave
    Always wear safety glasses while programming.

  9. #9
    Join Date
    Aug 2009
    Posts
    56


    Did you find this post helpful? Yes | No

    Default

    Ok,I think we miss a lesson first of this:how to use Micro Code Studio,how compiling a file and how convert it to hex files and after load it to chip

  10. #10
    Join Date
    Aug 2009
    Posts
    56


    Did you find this post helpful? Yes | No

    Default

    I compile that code with Micro Code Studio and
    at the first cod only blink Led no2 on the board without pressing nothing
    at the second code stay On Led no1 without pressing nothing
    and in the compiler I got this error when compiling
    Error LED2.ASM 49 : [235] opcode expected instead of '_config
    Im using Micro Code Studio with PICBASIC PRO Compiler Demo
    Last edited by osceola; - 23rd August 2009 at 01:14.

Similar Threads

  1. AN Question for "word" variable read The serial port
    By redfoen in forum mel PIC BASIC Pro
    Replies: 1
    Last Post: - 14th December 2007, 17:39
  2. really simple, dumb question
    By picster in forum mel PIC BASIC Pro
    Replies: 1
    Last Post: - 3rd March 2007, 22:02
  3. Question for a math guru
    By Christopher4187 in forum General
    Replies: 3
    Last Post: - 22nd November 2006, 09:45
  4. Please answer my first question
    By John_001 in forum Off Topic
    Replies: 1
    Last Post: - 15th September 2006, 06:49
  5. Dumb question
    By Christopher4187 in forum General
    Replies: 0
    Last Post: - 20th June 2006, 12:02

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