Experimental Physics and Industrial Control System
On 10.04.2015 18:50, Michael Johnson wrote:
In Stream, I do not set any terminators (redundant?).
You can set terminators in the startup script using asynOctetSet*Eos or
in the StreamDevice protocol. The protocol defined terminators overwrite
those in the startup script (StreamDevice restores them when it is done
with the protocol).
Program heap: free of bad pointer 98assertion "(uread(BSP_UART_COM1,
LSR) & THRE) != 0" failed: file
"../../../../../../../../__rtems-4.9.2/c/src/lib/libbsp/__i386/pc386/../../i386/shared/__comm/uart.c",
line 585, function: BSP_uart_termios_write_com1
This seems to be outside StreamDevice. But if you send me a stack dump I
may able to find out from where it gets called.
(after changing "print" to "printf" to get it to compile)
Maybe this gets called wrongly. I renamed the StreamBuffer method from
"printf" to "print" because I found out that on some platforms (RTEMS)
printf is actually a macro (for fprintf(stdout, ...))
I really need to publish the current StreamDevice version. :-)
BTW: assertions should not call functions or macros. They should only
test but never modify values, because switching them off results in no
code at all, thus code like this is "illegal":
assert((uread(BSP_UART_COM1, LSR) & THRE) != 0);
The legal variant would be something like this:
int ureadResult = uread(BSP_UART_COM1, LSR);
assert ((ureadResult & THRE) != 0);
Dirk
- Replies:
- Re: Stream device problem with redirection in @mismatch Dirk Zimoch
- References:
- Stream device problem with redirection in @mismatch ruzickaj
- Re: Stream device problem with redirection in @mismatch Dirk Zimoch
- Re: Stream device problem with redirection in @mismatch ruzickaj
- Re: Stream device problem with redirection in @mismatch Dirk Zimoch
- Re: Stream device problem with redirection in @mismatch Dirk Zimoch
- Re: Stream device problem with redirection in @mismatch Michael Johnson
- Navigate by Date:
- Prev:
Re: StreamDevice reading waveforms Anthony Pietryla
- Next:
Re: StreamDevice reading waveforms Dirk Zimoch
- Index:
1994
1995
1996
1997
1998
1999
2000
2001
2002
2003
2004
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
<2015>
2016
2017
2018
2019
2020
2021
2022
2023
2024
- Navigate by Thread:
- Prev:
Re: Stream device problem with redirection in @mismatch Michael Johnson
- Next:
Re: Stream device problem with redirection in @mismatch Dirk Zimoch
- Index:
1994
1995
1996
1997
1998
1999
2000
2001
2002
2003
2004
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
<2015>
2016
2017
2018
2019
2020
2021
2022
2023
2024