HSEROUT problem


Closed Thread
Results 1 to 16 of 16

Thread: HSEROUT problem

Hybrid View

  1. #1

    Default

    thx for the post, but constructive help please
    seriously important.

  2. #2
    Join Date
    Oct 2003
    Location
    holland
    Posts
    251

    Default

    First of all The used chip has only 1 hardware uart so HSERIN and HSEROUT without the 2 behind is normaly used.
    Then you combine behind the HSEROUT the modifiers of the SEROUT command.
    I can tell you ofcource what you had to type, but you will learn more by yourself if you read the exact used modifiers used for the HSEROUT (HSERIN) command and the SEROUT (SERIN) command and what is the difference beteween those two commands.
    You can find it in the book that came with the compiler or you can download it by www.melabs.com

  3. #3

    Default

    hey mat,
    thx for the help but i still dun quite get it.
    meaning that my HSEROUT is code wrongly??
    am i missing something??

    i meant i dun quite get this part
    "without the 2 behind is normaly used.
    Then you combine behind the HSEROUT the modifiers of the SEROUT command."

  4. #4
    Join Date
    Oct 2003
    Location
    holland
    Posts
    251

    Default

    Indeed.
    Look into the documents and you see:
    HSEROUT [Item{,item....}] as HSEROUT [data1] when more HSEROUT [data1, data2, data3]

    SERIN Pin,Mode,{Timeout,Label,}{[Qual...],}{Item...}

    The Hser... commands are already defined by the statements:
    DEFINE HSER_BAUD 9600
    DEFINE HSER_RCSTA 90h
    DEFINE HSER_TXSTA 24h
    DEFINE HSER_SPBRG 129
    DEFINE HSER_CLROERR 1

    I hope you understand what I meant to say.
    In your programm you made a mix of the the both.

  5. #5

    Default

    hey mat,
    thx for all the help.

    so how should i go about changing the codes??
    basically i nv use HSEROUT before,
    so i dun really understand it.

  6. #6
    skimask's Avatar
    skimask Guest

    Default

    Quote Originally Posted by Williamaybe View Post
    so how should i go about changing the codes??
    basically i nv use HSEROUT before,
    so i dun really understand it.
    There's no reason why you can't use SEROUT in place of HSEROUT, just configure the I/O as general purpose rather than a serial port.
    And you're trying to user HSEROUT2. If you read your PBP manual, you'll see that HSEROUT2 is reserved for PICs with 2 hardware serial port modules, something that the 16F876A does NOT have.

  7. #7

    Default

    thx ski for telling me that.
    but seriously i dunno why.
    when i write serout and serin,
    my programme doesnt really function as expected.

    "my modem does receive the message that i send
    but somehow there is no output"

    is there any problems with it??

Similar Threads

  1. I2C Slave with a PIC
    By ralfmayr in forum mel PIC BASIC Pro
    Replies: 129
    Last Post: - 21st August 2016, 18:44
  2. HSEROUT and Commas, What? Help Me Understand
    By altech6983 in forum mel PIC BASIC Pro
    Replies: 4
    Last Post: - 20th July 2009, 20:12
  3. Is HSEROUT corrupting bit 7 ?????
    By Robert Wells in forum mel PIC BASIC Pro
    Replies: 3
    Last Post: - 23rd October 2008, 17:26
  4. HSEROUT Problem
    By Keith in forum General
    Replies: 2
    Last Post: - 25th June 2005, 16:09
  5. Advantages of HSerout over Serout2 and a problem
    By rpstroj in forum mel PIC BASIC Pro
    Replies: 5
    Last Post: - 11th August 2004, 23:19

Members who have read this thread : 2

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