Would you like to react to this message? Create an account in a few clicks or log in to continue.

You are not connected. Please login or register

Program Status Word issue in 8051

2 posters

Go down  Message [Page 1 of 1]

1Program Status Word issue in 8051 Empty Program Status Word issue in 8051 Fri Apr 07, 2023 11:20 am

tomas714



Hi,

Progam Status Word register in MCU 8051 is not working properly. Bits P, OV, RS1 and AC are behaving incorrectly.

I am attaching the code which describes the problem in more detail.

Thanks
Attachments
Program Status Word issue in 8051 AttachmentPSW-Issue.zip
Schematic and program in Assembler
You don't have permission to download attachments.
(2 Kb) Downloaded 1 times

2Program Status Word issue in 8051 Empty Re: Program Status Word issue in 8051 Fri Apr 07, 2023 4:11 pm

arcachofo

arcachofo

Hi.
Thank you very much.
With the code and explanations you provide it will be easy to check and fix these issues.

3Program Status Word issue in 8051 Empty Re: Program Status Word issue in 8051 Fri Apr 07, 2023 8:44 pm

tomas714



arcachofo wrote:Hi.
Thank you very much.
With the code and explanations you provide it will be easy to check and fix these issues.

You are welcome.

This document could be useful in solving the problem:
http://www.bitsavers.org/components/intel/8051/MCS-51_Users_Manual_Feb94.pdf

See:
  • Page 42 (2-11) - Program Status Word
  • Page 52 (2-21) - Instructions that Affect Flag Settings
  • Page 60 (2-29) - Description of the ADD function with comments on the OV, C and AC bits  


Good luck!

arcachofo likes this post

4Program Status Word issue in 8051 Empty Re: Program Status Word issue in 8051 Thu Apr 13, 2023 8:48 pm

arcachofo

arcachofo

This issue is hopefully solved at Rev 1348.

Sponsored content



Back to top  Message [Page 1 of 1]

Permissions in this forum:
You cannot reply to topics in this forum