lpcware

printf cannot be used in RawSerial class in LPC1549

Discussion created by lpcware Employee on Jun 15, 2016
Latest reply on Jun 15, 2016 by lpcware
Content originally posted in LPCWare by zhjcpi on Wed May 21 00:14:55 MST 2014
Dear,

I am working on mBed LPC1549 platform.

I am trying to use RawSerial to output debug information. I delcare debug serial port as RawSerial class, the system will halt when printf is called, such as
    RawSerial pc(D1, D0);
    pc.printf("hello world.\r\n")

I delcare debug serial port as Serial class, the system will work well when printf is called, such as
    Serial pc(D1, D0);
    pc.printf("hello world.\r\n")

Does the printf is supported in Mbed RawSerial class in LPC1549 platform?

Thanks.

Outcomes