This is the mail archive of the
ecos-discuss@sourceware.org
mailing list for the eCos project.
turn off diag_printf?
- From: Dave Milter <davemilter at gmail dot com>
- To: ecos-discuss at ecos dot sourceware dot org
- Date: Tue, 6 Oct 2009 11:33:57 +0400
- Subject: [ECOS] turn off diag_printf?
I used arm cpu from at91 family and its DBGU channel for working with redboot.
When my application starting it used dbgu for diag_printf and also
ordinary printf working via
this channel, now I want interrupt driven IO via this DBGU serial
port, but only after full initialization.
So I want such scheme:
redboot - diag_printf working
ecos app:
- initialization - diag_printf working
- main function is called - diag_printf working
- somehow switch off diag_printf - now it nothing print to DBGU port (1)
- interrupt driven IO via DBGU port is activated
I have problem with (1), how should I do it?
I find such code:
CYGACC_COMM_IF_CH_DATA_SET(*comm, &at91_ser_channels[0]);
CYGACC_COMM_IF_WRITE_SET(*comm, cyg_hal_plf_serial_dbg_write);
CYGACC_COMM_IF_READ_SET(*comm, cyg_hal_plf_serial_dbg_read);
CYGACC_COMM_IF_PUTC_SET(*comm, cyg_hal_plf_serial_dbg_putc);
CYGACC_COMM_IF_GETC_SET(*comm, cyg_hal_plf_serial_dbg_getc);
CYGACC_COMM_IF_CONTROL_SET(*comm, cyg_hal_plf_serial_dbg_control);
CYGACC_COMM_IF_DBG_ISR_SET(*comm, cyg_hal_plf_serial_dbg_isr);
CYGACC_COMM_IF_GETC_TIMEOUT_SET(*comm, cyg_hal_plf_serial_dbg_getc_timeout);
if I replace in this code function like cyg_hal_plf_serial_dbg_write
with empty functions,
diag_printf stop send something to DBGU?
--
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss