diag.Debug.Writeline output going to the COM1 serial port.

J

Jay

We are noticing in our release build on a windows CE that any
occurance of Debug.WriteLine() is being written to the COM1 rs232
port. This is causing garbage to be printed out on our serial RS232
printer. Does anyone know if it is possible to turn this feature off
without commenting out all the debug.WriteLine statements and
recompiling?

registry setting?
command?


regards,
Jay
 
C

Chris Tacke, eMVP

This is device specific. Your vendo has chosen to have debug messages come
out COM1 as the debug port. Some OEMs have provided their devices with a
mechanism to turn off the debug port. Check with your OEM to see if they
have such a feature. If not you'll have to remove all of your calls.


--

Chris Tacke, Embedded MVP
OpenNETCF Consulting
Giving back to the embedded community
http://community.OpenNETCF.com
 
J

Jay

This is device specific.  Your vendo has chosen to have debug messages come
out COM1 as the debug port.  Some OEMs have provided their devices witha
mechanism to turn off the debug port.  Check with your OEM to see if they
have such a feature.  If not you'll have to remove all of your calls.

--

Chris Tacke, Embedded MVP
OpenNETCF Consulting
Giving back to the embedded communityhttp://community.OpenNETCF.com








- Show quoted text -

the hardware was build for us so I will inquire.
we did build the OS also if that is an option.

thanks for the info
 
S

superclass

Jay said:
the hardware was build for us so I will inquire.
we did build the OS also if that is an option.

if look MSDN you can see that there is registry key
HKEY_LOCAL_MACHINE\Drivers\Console\OutputTo
that controls redirection of console.

No default setting. This value controls whether the command processor output
is redirected to the serial port.
Setting this value to -1 will redirect the output to a debug port. Setting
this value to 0 to specifies no redirection.
Setting this value to a number greater than 0 and less than 10 will redirect
to a serial port.
 
C

Chris Tacke, eMVP

This has nothing to do with a Console. It's the debug port. It's set up in
the kernel with something like NkWriteDebugMsg (can't recall offhand exactly
and don't feel like firing up PB to check). It typically gets initialized
as the kernel starts up - very, very early - and it used no driver - just
direct writes to the UART. If the OP is the OEM, they could always just
stub out the kernel implementation so nothing gets written out, then rebuild
the OS.


--

Chris Tacke, Embedded MVP
OpenNETCF Consulting
Giving back to the embedded community
http://community.OpenNETCF.com
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top