Sending a word var to a PC using HSerout


Closed Thread
Results 1 to 3 of 3

Hybrid View

  1. #1
    Join Date
    Apr 2005
    Posts
    96

    Question Sending a word var to a PC using HSerout

    I've been trying to send a word variable from a 877a chip to a pc microcode studio plus hyperterminal with not much luck.

    I have gotten an echo program to work where the pic will send to the pc what ever I send to the pic.

    Now if I try to send a word file from the pic to the pc I get nothing but jiberish. I realize I may need to convert the word variable to ascii characters, but I am not sure how.

    I think I am missing somthing obvious but not sure what thanks for any input.

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


    Did you find this post helpful? Yes | No

    Default

    you must use the HSERIN modifiers. DEC,HEX,BIN depending what you need to see

    Code:
    MyVar var word
    MyVar=4321
    
    Hserout[DEC MyVar]
    now you're suppose to see 4321
    Steve

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

  3. #3
    Join Date
    Apr 2005
    Posts
    96


    Did you find this post helpful? Yes | No

    Default thanks I'm getting there

    Thanks for your help, it seems to work for the most part. Right now the first time I read out to the PC after I use the microloader bootloader to load my file on to the pic all I get is jibberish. Once I reset the pic using the mclr everything works as expected.
    Last edited by modifyit; - 20th June 2005 at 13:30.

Similar Threads

  1. RF Modules
    By tonyfelloni in forum mel PIC BASIC Pro
    Replies: 44
    Last Post: - 26th June 2010, 17:42
  2. Minimizing code space
    By Tobias in forum mel PIC BASIC Pro
    Replies: 2
    Last Post: - 30th May 2009, 07:25
  3. DS2760 Thermocouple Kit from Parallax in PicBasicPro
    By seanharmon in forum mel PIC BASIC Pro
    Replies: 3
    Last Post: - 8th July 2008, 23:19
  4. calculation problem
    By nicolelawsc in forum mel PIC BASIC Pro
    Replies: 2
    Last Post: - 31st March 2006, 15:23
  5. 16F877 RAM Question
    By Art in forum mel PIC BASIC Pro
    Replies: 8
    Last Post: - 6th August 2005, 11:47

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