<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=Content-Type content="text/html; charset=iso-8859-1">
<META content="MSHTML 5.50.4134.100" name=GENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=#ffffff>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV><FONT face=Arial size=2>Hello,</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV><FONT face=Arial size=2>I use the latest (ss-20011025) : Linux 7.1,
autoconf 2.52, automake 1.5 and m68k-rtems-gcc 2.95.3.</FONT></DIV>
<DIV><FONT face=Arial size=2>My custom BSP is based upon efi68k (it running
properly with RTEMS 4.5.0).</FONT></DIV>
<DIV><FONT face=Arial size=2>However, I have found an strange
error : </FONT></DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV><FONT face=Arial size=2>********** console.c</FONT></DIV>
<DIV><FONT face=Arial size=2>[...]</FONT></DIV>
<DIV><FONT face=Arial size=2> #define REG_DELAY for(cx=0; cx < 10;
cx++);</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV><FONT face=Arial size=2>long cx;</FONT></DIV>
<DIV><FONT face=Arial size=2>[...]</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV><FONT face=Arial
size=2>0155 /* UART D
*/<BR>0156 /* ------
*/<BR>0157 *(VOIE4 +
CDE_REG) = 0x20; /* reset le recepteur
*/<BR>0158
REG_DELAY;<BR>0159 *(VOIE4 +
CDE_REG) = 0x30; /* reset l'emetteur
*/<BR>0160
REG_DELAY;<BR>0161 *(VOIE4 +
CDE_REG) = 0x40; /* reset les erreurs
*/<BR>0162
REG_DELAY;<BR>0163 *(VOIE4 +
CDE_REG) = 0x50; /* reset break detect
*/<BR>0164
REG_DELAY;<BR>0165 *(VOIE4 +
CDE_REG) = 0xb0; /* reset reg mode pour acceder a
MR0 */<BR>0166
REG_DELAY;<BR>0167 *(VOIE4 +
MODE_REG) = 0x80; /* Watchdog pour caracteres dans
RxFIFO */<BR>0168
REG_DELAY;<BR>0169 *(VOIE4 +
MODE_REG) = 0x13; /* MR1= no RTS Control, no parity, 8
bits */<BR>0170
REG_DELAY;<BR>0171 *(VOIE4 +
MODE_REG) = 0x7; /* MR2= 1 Stop bit, Cts enable,
normal */<BR>0172
REG_DELAY;<BR>0173 *(VOIE4 +
CK_SEL_REG) = 0xbb; /* CSR= 9600 bps vitesses Tx/Rx
*/<BR>0174
REG_DELAY;<BR>0175 *(VOIE4 +
CDE_REG) =
0x05; /* rts=0, enable Tx et Rx
*/<BR>0176
REG_DELAY;</FONT></DIV>
<DIV><FONT face=Arial size=2>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV><FONT face=Arial size=2>[...]</FONT></DIV></FONT></DIV>
<DIV><FONT face=Arial size=2>**********</FONT></DIV>
<DIV><FONT face=Arial
size=2>0165 *(VOIE4 +
CDE_REG) = 0xb0; /* reset reg mode pou<BR>000010F0
13FC00B00010.. move.b
#$B0,$00100035<BR>0166
REG_DELAY;<BR>000010F8
7000
moveq #0,D0<BR>000010FA
7409
moveq #9,D2<BR>000010FC
B480
cmp.l D0,D2<BR>000010FE
6C02
bge.s $00001102<BR>00001100
6004
bra.s $00001106<BR>00001102
5280
addq.l #1,D0<BR>00001104
60F4
bra.s
$000010FA<BR>0167 *(VOIE4 +
MODE_REG) = 0x80; /* Watchdog pour cara<BR>00001106
13FC00800010.. move.b
#$80,$00100031<BR>0168
REG_DELAY;<BR>0000110E
7000
moveq #0,D0<BR>00001110
7409
moveq #9,D2<BR>00001112
B480
cmp.l D0,D2<BR>00001114
6C006004 bge.w
$0000711A<BR>
^^^^^^^^^^^^^^ ^^^^^^^^^</FONT></DIV>
<DIV><FONT face=Arial size=2>
very, very strange
:( </FONT></DIV>
<DIV><FONT face=Arial size=2> </FONT></DIV>
<DIV><FONT face=Arial size=2>00001118
5280
addq.l #1,D0<BR>0000111A
60F4
bra.s
$00001110<BR>0169 *(VOIE4 +
MODE_REG) = 0x13; /* MR1= no RTS Contro<BR>0000111C
13FC00130010.. move.b
#$13,$00100031<BR>0170
REG_DELAY;<BR>00001124
7000
moveq #0,D0<BR>00001126
7409
moveq #9,D2<BR>00001128
B480
cmp.l D0,D2<BR>0000112A
6C02
bge.s $0000112E<BR>0000112C
6004
bra.s $00001132<BR>0000112E
5280
addq.l #1,D0<BR>00001130
60F4
bra.s
$00001126<BR>0171 *(VOIE4 +
MODE_REG) = 0x7; /* MR2= 1 Stop bit, C<BR>00001132
13FC00070010.. move.b #$07,$00100031</FONT></DIV>
<DIV><FONT face=Arial size=2>***********</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV><FONT face=Arial size=2>I will use rtems_bsp_delay ;)</FONT></DIV>
<DIV><FONT face=Arial size=2>but, I will know what going on.</FONT></DIV>
<DIV><FONT face=Arial size=2>This code is correct with RTEMS 4.5.0 (GCC
2.95.2).</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV>What can I do? </DIV>
<DIV> </DIV>
<DIV><FONT face=Arial size=2>Thanks.</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV><FONT face=Arial size=2>Stan.</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV></BODY></HTML>