Is it possibly a Windows XP Pro Problem?


Closed Thread
Results 1 to 11 of 11
  1. #1
    Join Date
    Mar 2011
    Location
    Los Angeles, California
    Posts
    322

    Default Is it possibly a Windows XP Pro Problem?

    I am have 2 problems. First after trying Hyper Terminal in Windows and RS-232C Lab I can see that I am sending data from the PIC. What these programs show is just the same set of characters and not what they should be. Baud is at 2400, data bits are 8, stop bit is 1, parity is none, flow control is none. I have been trying now for two days so I really need help! I also find that Microcode Studio Plus ICD will not talk to the MAX-232 so not I am completely lost! I thought about a bad cable and if this were so I could not program the PIC. Anyone have any ideas? Thanks, Ed

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

    Default Re: Is it possibly a Windows XP Pro Problem?

    Got any code?
    Dave
    Always wear safety glasses while programming.

  3. #3
    Join Date
    Mar 2011
    Location
    Los Angeles, California
    Posts
    322

    Default Re: Is it possibly a Windows XP Pro Problem?

    Sorry serious brain craps!

    ' Name : HELLOX3.pbp
    ' Compiler : PICBASIC PRO Compiler 2.6
    ' Assembler : PM or MPASM
    ' Target PIC : PIC16F628A or similar 18-pin type compatible with LAB-X3 board
    ' Hardware : LAB-X3 Experimenter Board
    ' Oscillator : 4MHz external crystal
    ' Keywords : SEROUT
    ' Description : PICBASIC PRO program to send "Hello World" on serial port.
    '
    Include "modedefs.bas" ' Mode definitions for Serout
    Define LOADER_USED 1
    Define osc 20
    mainloop:
    Serout PORTB.3, T2400, ["Hello", 10, 13] ' Display "Hello", next line
    Pause 500 ' Wait .5 second
    Serout PORTB.3, T2400, ["World", 10, 13, 10, 13] ' Display "World", skip a line
    Pause 500 ' Wait .5 second
    Goto mainloop ' Do it forever
    End

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

    Default Re: Is it possibly a Windows XP Pro Problem?

    Your code looks OK with the exception , I think, that it is PORTB.2 that goes to the MAX232.

    If I am wrong on that try the Serial Communicator built into MCS.
    Dave
    Always wear safety glasses while programming.

  5. #5
    Join Date
    Mar 2011
    Location
    Los Angeles, California
    Posts
    322

    Default Re: Is it possibly a Windows XP Pro Problem?

    Thank you and inquiring minds would like to know why B.2?
    Isn't Port B.2 the TX-in for the Max 232 on a 16F628A or am I looking for a specific type of port?

    Thanks, Ed
    Last edited by Ramius; - 1st May 2011 at 21:22.

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

    Default Re: Is it possibly a Windows XP Pro Problem?

    B.2 is the TX and B.1 is the RX from the 628.
    Just a matter of looking at it as out from the PIC and in to the MAX.

    Are you up and running now?
    Dave
    Always wear safety glasses while programming.

  7. #7
    Join Date
    Mar 2011
    Location
    Los Angeles, California
    Posts
    322

    Default Re: Is it possibly a Windows XP Pro Problem?

    Hi, no sadly I am not able to get it to work. I am using Microcode Studio plus, MPLAB IDE, and a Picstart Plus programmer. Somewhere within these three I have made the wrong choices and being perfectly honest, not knowing what options to chose. I think it will probably take a phone call to/from someone to go through the setups. Thanks though, Ed

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

    Default Re: Is it possibly a Windows XP Pro Problem?

    Sorry that I could not help.
    But a call to MeLabs and a talk with Darrell should fix you up.
    Let us know how it goes.
    Dave
    Always wear safety glasses while programming.

  9. #9
    Join Date
    Feb 2006
    Location
    Gilroy, CA
    Posts
    1,530

    Default Re: Is it possibly a Windows XP Pro Problem?

    I don't think the 628a is capable of writing to its own memory. So I don't think it is possible for you to use a bootloader for that chip. So what happens if you take this out of your code?

    Define LOADER_USED 1

    Also, you could try out the sample hex file code on MeLabs website (but it is made for the 4 Mhz crystal that comes with the hardware), just to make sure the hardware is working as you thought. http://melabs.com/doclist.htm#X3

    When you define the osc, you must use capitals! DEFINE OSC 20. PBP is proably defaulting to 4 mhz.

    Also, the MeLabs example program for that hardware uses PortB.2, like Dave mentioned. Here is their example:

    Code:
    Include "modedefs.bas" ' Mode definitions for Serout
     
    loop: Serout PORTB.2,T2400,["Hello",10,13] ' Display "Hello", next line
    Pause 500 ' Wait .5 second
    Serout PORTB.2,T2400,["World",10,13,10,13] ' Display "World", skip a line
    Pause 500 ' Wait .5 second
    Goto loop ' Do it forever
    End
    Last edited by ScaleRobotics; - 2nd May 2011 at 14:55. Reason: added hex file idea

  10. #10
    Join Date
    Aug 2006
    Location
    Look, behind you.
    Posts
    2,818

    Default Re: Is it possibly a Windows XP Pro Problem?

    Hi Ed,
    Ok so I gotta ask, is anything working, have you verified the code got in the PIC? Did you preprogram it with the bootloader? Did you get any errors when loading any of the code / bootloader ? What is going on inside my mind right now is I am seeing you define OSC 20, and I am wondering what config fuse got programmed into the chip, HS, XT, or other . . . Will a boot loaded program even run at 20 ? I don't know, as I have NEVER used a bootloader. Those are my thoughts.
    HTH
    JS
    If you do not believe in MAGIC, Consider how currency has value simply by printing it, and is then traded for real assets.
    .
    Gold is the money of kings, silver is the money of gentlemen, barter is the money of peasants - but debt is the money of slaves
    .
    There simply is no "Happy Spam" If you do it you will disappear from this forum.

  11. #11
    Join Date
    Mar 2011
    Location
    Los Angeles, California
    Posts
    322

    Default Re: Is it possibly a Windows XP Pro Problem?

    Hi All!
    Turned out that a 10 MHz resonator was installed! Thanks to all!

    Sincerely, Ed

Members who have read this thread : 1

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