From mboxrd@z Thu Jan 1 00:00:00 1970 From: "Ling Su" To: "Jesper Skov" Cc: Subject: Re: [ECOS] How to make a code from RAM startup to ROM startup? Date: Tue, 17 Apr 2001 11:01:00 -0000 Message-id: <007701c0c768$5ef0f5f0$0201a8c0@raccoon> References: <000b01c0c493$1632f9d0$0201a8c0@raccoon> X-SW-Source: 2001-04/msg00153.html > Ling> <3>. Actually we I debugging my code, I find the serial port 1 > Ling> is very unstable due to the use of diag_printf(), since the call > Ling> doesn't go through serial driver, and some conflicts will happen > Ling> easily when I am writing to serial 1, and diag_printf write to > Ling> serial 0. If I use GDB to debug, I am not sure if gdb stub will > Ling> keep polling the serial port if I doesn't set up any break point > Ling> and just let it free run after downloading the code, since I > Ling> always meet serial port write failure, I think this point might > Ling> be suspicious. Anyone know this? Please shed me some light! > > It's not quite clear to me what you are asking for, but using both the > HAL IO and the serial IO driver on the same controller is not > guaranteed to work. > So, sounds to me it is no way to handle serial debugging with the GDB stubs, since it is built on HAL_IO. The current situation for me is, I realized that the HAL_IO and serial IO might have conflict problems, so I removed all the diag_printf() call. I just use GDB to download the code onto the board, then issue a "continue" command to let it run, in this case, I am not sure if the HAL_IO layer still alive to access serial port? I remember there is some serial test cases, which use obviously serial IO running under GDB, they are all working very well. From Jesper's explanation, I guess they should fail at least sometime, right? Look forward to hearing some answers! Best Regards, -Ling