Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

What is %sr in move #0x2700, %sr

Status
Not open for further replies.

naseeam

Member
Consider the following move instruction:

move.w #0x2700, %sr

This move instruction masks all interrupts. The immediate value 0x2700 is written to destination %sr. What is %sr? How does this instruction work?

Please point me to documentation that will explain % in this instruction? We are using GCC tools for compiling and assembling our code. Do I need GNU g++ assembler to understand % in this insturction or do I need Freescale Coldfire MCF548x Reference Manual. How do I get this reference manual? And please point me link to fetch the gnu assembler?

Thanks!
 

Papabravo

Well-Known Member
%sr is the symbolic name for a register. If I had to guess I would say that the actual name might be something like "Status Register" or "System Register" The GNU documentation may or may not speak to your question. My experience has been that GNU documentation is generally voluminous and poorly indexed for the neophyte. It is always a worthwhile effort to try to track things like this down. As you gain more experience with it, it does become easier. As far as the particular processor you are using you need to find a document on the Freescale site that is titled something like "Hardware Manual" or "Instruction Set Reference"

I charge at least $150.00/hr to do this stuff by the way.

Good Luck.
 
Last edited:
Status
Not open for further replies.

Latest threads

EE World Online Articles

Loading
Top