Reply by "yan...@omniverter.com [rabbit-semi]"●September 1, 20162016-09-01
Hello, Tom:
thank you for your response. I find a alternative solution. I ask user to type
'd' from debug std when the program starts, if program doesn't
get answer for certain time (for example ,5 second), I will stop debug display
task, so I can save some resource.
Thanks
Reply by "Tom...@tomlogic.com [rabbit-semi]"●August 17, 20162016-08-17
If nothing's connected, it shouldn't matter that you're still
sending output to STDIO.
If you're using the Rabbit's built-in methods to redirect STDIO to a
serial port, then I don't think there will be an easy way to conditionally
send output. You'd probably have to create a wrapper for printf() that
checks an I/O pin (CTS on the serial port?) before handing the parameters off to
vprintf() using a va_list parameter.
-Tom
On Aug 17, 2016, at 10:36 AM, y...@omniverter.com [rabbit-semi] wrote:
> Hello,
>
> I have a program including debug stdio screen display. I would like to have
this feature, when stdio is connected, program will send some parameters to
stdio, otherwise, no information is sent, do I have possibility to detect stdio
(like DC10.72) connected by program?
>
> thanks
>
Reply by "yan...@omniverter.com [rabbit-semi]"●August 17, 20162016-08-17
Hello,
I have a program including debug stdio screen display. I would like to have
this feature, when stdio is connected, program will send some parameters to
stdio, otherwise, no information is sent, do I have possibility to detect stdio
(like DC10.72) connected by program?