码迷,mamicode.com
首页 > 其他好文 > 详细

openMSP430之instruction

时间:2015-05-07 23:48:20      阅读:127      评论:0      收藏:0      [点我收藏+]

标签:

 

Byte and word issues


1  Appending “.b” to an instruction makes it a byte operation.

  A byte instruction with a register destination clears the high 8 bits of the register to 0. Thus, the following would clear the top byte of the register, leaving the lower byte unchanged:

mov.b Rn,Rn

 

2  Adding ".w"(or nothing) to an instruction makes it a word operation, which is also the default behaviour.

 

3  Peripherals are divided into an 8-bit bank and a 16-bit bank.

   The 8-bit peripherals must only be accessed using 8-bit instructions; using a 16-bit access produces garbage in the high byte.

   The 16-bit peripherals must only be accessed at even addresses. Byte accesses to even addresses are legal, but not usually useful.

openMSP430之instruction

标签:

原文地址:http://www.cnblogs.com/mengdie/p/4486415.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!