Forum : ST7/STM8
Original Post
Post Information | Post |
---|---|
November 23, 2007 - 12:15pm
|
I use ride(bn747) st7 Simulator debug.But when i try write or read SCIDR(51H), the SCISR(50H) not any changer. Target:ST72324X4 Thank you! |
Hi,
SCISR has value C0h, as bits 7 and 6 are set. This means (bit 7) transmit data register is empty and (bit 6) transmission is complete. That just means the SCI is ready to send or receive, nothing in its buffer in either direction.
Bruno
Sorry,i make a mistake.Example:Reset,SCISR=0C0H,I try do :LD SCIDR,A , but SCISR still be 0c0h.
You are right.
If you read the datasheet for your device, you will note that bit 7 and 6 of SCISR are flags indicating the status of the SCI. These flags report whether the peripheral is "empty" or not. So even if you reset the flags to 0, they will eventually (and automatically) come back to 1 when the SCI buffers are free.
I hope this helps.
Bruno