Shop OBEX P1 Docs P2 Docs Learn Events
Garbage at end of string with printf! — Parallax Forums

Garbage at end of string with printf!

LeonLeon Posts: 7,620
edited 2012-02-26 07:32 in Propeller 1
Printf to stdout puts garbage on the end of the printed string.

Comments

  • mindrobotsmindrobots Posts: 6,506
    edited 2012-02-26 06:35
    Leon,

    Can you provide any more details? Prop board you are using? Code you are running? Based on the experiences so far, this isn't a widespread situation, so details would be much appreciated.
  • LeonLeon Posts: 7,620
    edited 2012-02-26 06:40
    I'm using a QuickStart board, with the simple hello.c program in the Readme file, under Windows. gcc version is 4.6.1.

    puts has the same problem.

    I must have been using an old version, I downloaded it some time ago. I downloaded the current version and it was OK.
  • Dave HeinDave Hein Posts: 6,347
    edited 2012-02-26 07:21
    The garbage characters are generated because the SimpleSerial driver releases the transmit pin after sending out a character, and the QuickStart card does not have a pullup on this pin. The lastest version of PropGCC may now be driving this pin between characters. However, this would cause problems when printing from another cog.
  • LeonLeon Posts: 7,620
    edited 2012-02-26 07:32
    Thanks, Dave. That should be mentioned in the docs, I can't see it anywhere.
Sign In or Register to comment.