Byte and word issues

  The MSP430 is byte-addressed, and little-endian. Word operands must be located at even addresses

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.

Assembly之Instruction之Byte and Word的更多相关文章

  1. BYTE、WORD与DWORD类型

    Original Link:  http://hi.baidu.com/vnxuaqndtncrxyr/item/f67c83872cf80cd65e0ec10d Author: 厚积薄发 在Visu ...

  2. C++ BYTE、WORD与DWORD类型

    在VS中,BYTE与WORD,DWORD本质上都是一种无符号整型,它们在WINDEF.H中被定义,定义如下: typedef unsigned char       BYTE;typedef unsi ...

  3. Assembly之instruction之Indirect Autoincrement Mode

    Assembler Code Content of ROMMOV @R10+,0(R11)   MOV @R10+,0(R11) Length: One or two words Operation: ...

  4. Assembly之instruction之MOV

    MOV[.W]   Move source to destinationMOV.B Move source to destination Syntax MOV  src,dst  or       M ...

  5. C language bit byte and word

    bit:The smallest storage unit of a computer byte:Common computer storage unit word:Computer natural ...

  6. Assembly之instruction之Status register

    The status register (SR/R2), used as a source or destination register, can be used in the register m ...

  7. Assembly之instruction之JC

    JC Jump if carry setJHS  Jump if higher or same Syntax JC label JHS label Operation If C = 1: PC + 2 ...

  8. Assembly之instruction之JUMP

    JMP  Jump unconditionally Syntax   JMP  label Operation PC + 2 × offset −> PC Description The 10- ...

  9. Assembly之instruction之Register Mode

    Assembler Code Content of ROM MOV R10,R11 MOV R10,R11 Length: One or two words Operation: Move the c ...

随机推荐

  1. python的转义字符及用法详解

    在需要在字符中使用特殊字符时,python用反斜杠(\)转义字符. Python3.7 的官方文档中列出的所支持的转义字符,如下表: 中文版: 注:\oyy 应该是 \0yy  另外 :\e 和 \0 ...

  2. 6.3.4 使用marshal 模块操作二进制文件

    Python 标准库 marshal 也可以进行对象的序列化和反序列化,下面的代码进行了简单演示. import marshal x1 = 30 x2 = 5.0 x3 = [1,2,3] x4 = ...

  3. 【郑轻邀请赛 B】base64解密

    [题目链接]:https://acm.zzuli.edu.cn/zzuliacm/problem.php?id=2128 [题意] [题解] 把密文; 在表中找到每个字符对应的数字; 然后转换成相应的 ...

  4. java中的redis工具类

    1.redis基础类 package com.qlchat.component.redis.template; import javax.annotation.PostConstruct; impor ...

  5. hdu_1861_游船出租_201402282130

    游船出租 Time Limit: 1000/1000 MS (Java/Others)    Memory Limit: 32768/32768 K (Java/Others) Total Submi ...

  6. nyoj_915_+-字符串_201402261520

    +-字符串 时间限制:1000 ms  |           内存限制:65535 KB 难度:1   描述 Shiva得到了两个只有加号和减号的字符串,字串长度相同.Shiva一次可以把一个加号和 ...

  7. LDAP目录服务折腾之后的总结

    前言 公司管理员工信息以及组织架构的后台系统要和Active Directory目录服务系统打通,后台系统使用PHP开发, 折腾了二十多天,终于上线了,期间碰到过各种疑难问题,不过总算在GOOGLE大 ...

  8. MySQL:Useful Commands

    MySQL Useful Commands Start/Stop/Restart MySQL On Linux start/stop/restart from the command line: /e ...

  9. CF #316 DIV2 D题

    D. Tree Requests time limit per test 2 seconds memory limit per test 256 megabytes input standard in ...

  10. Maven中的dependency的scope作用域详解

    1.test范围指的是测试范围有效,在编译和打包时都不会使用这个依赖 2.compile范围指的是编译范围有效,在编译和打包时都会将依赖存储进去 3.provided依赖:在编译和测试的过程有效,最后 ...