1. Little-Endian(小端存储),即将低字节的数据存储于低地址中,Big-Endian(大端存储)反之。

  2. 小端存储称为Intel模式,大端存储称为Motorola模式

  3. C51中LCALL指令将下一指令的执行地址压入堆栈中(堆栈地址由低向高增长),先存入低字节地址,再存入高字节地址,亦即使用“小端模式(Intel模式)”;除此之外,C51中的其它指令和数据,均使用“大端模式(Motorola模式)”

The  -bit machine and has no instructions  bits. Multi-byte data are stored according to the following rules. 

The  LCALL instruction stores the address of the next instruction on the stack. The address is pushed onto the stack low-order byte first. The address is, therefore, stored in memory in little endian format.
All other -bit and -bit values are stored, contrary to other Intel processors, -bit addresses that are in big endian format.
Floating-point numbers are stored according to the IEEE- format and are stored in big endian format with the high-order byte stored first. 

--引用参考:Keil Cx51 User‘s Guide -> Appendix -> E. Byte Ordering.
--http://www.keil.com/support/man/docs/c51/c51_xe.htm

  4. Keil编译器不能按用户需求设置大小端的存储模式

SYMPTOMS
My hardware's set up for big endian, but the compiler seems to be storing things little endian. Is there a compiler option to reverse the way data is stored?

CAUSE
At this time, there is no functionality in any of the compilers to effect a "global" change in the way data is stored.

--引用参考:http://www.keil.com/support/docs/730.htm

  5. 8051系列MCU中,用C语言进行编程时,数据的存储模式由编译器(Compiler)决定,如Keil C51 Compiler 4.0版本开始使用“大端存储模式”,而较早前的编译器版本中使用的是“小端存储模式”。

Version 4.0 Differences
Home » Appendix » B. Version Differences » Version 4.0 Differences

Byte Order of Floating-point Numbers
Floating-point numbers are now stored in the big endian order. Previous releases of the C51 compiler stored floating-point numbers in little endian format. Refer to Floating-point Numbers for more information.

--引用参考:http://www.keil.com/support/man/docs/c51/c51_xb_ver4dif.htm

  6. 主流MCU架构关于endian的配置:

使用小端(Little- (including , 65C816), Z80 (including Z180, eZ80 etc.), MCS-, , DEC Alpha, Altera Nios, Atmel AVR, SuperH, VAX, 和 PDP- 等等;

使用大端(Big- and 68k, Xilinx Microblaze, IBM POWER, system/, System/ 等等。

支持配置endian的架构:如下架构有配置endian为大端、小端中任一种的功能, ARM, PowerPC, Alpha, SPARC V9, MIPS, PA-RISC 和 IA- 等等。

--引用参考:http://smilejay.com/2012/01/big-endian_little-endian/

  --编者注:ARM架构中,可通过对功能寄存器进行设置,从而切换至Big-Endian或Small-Endian存储模式。

关于C51中“大小端存储”问题的详解的更多相关文章

  1. Java中堆内存和栈内存详解2

    Java中堆内存和栈内存详解   Java把内存分成两种,一种叫做栈内存,一种叫做堆内存 在函数中定义的一些基本类型的变量和对象的引用变量都是在函数的栈内存中分配.当在一段代码块中定义一个变量时,ja ...

  2. Java中的equals和hashCode方法详解

    Java中的equals和hashCode方法详解  转自 https://www.cnblogs.com/crazylqy/category/655181.html 参考:http://blog.c ...

  3. Linux中redis安装配置及使用详解

    Linux中redis安装配置及使用详解 一. Redis基本知识 1.Redis 的数据类型 字符串 , 列表 (lists) , 集合 (sets) , 有序集合 (sorts sets) , 哈 ...

  4. 转:Java中的equals和hashCode方法详解

    转自:Java中的equals和hashCode方法详解 Java中的equals方法和hashCode方法是Object中的,所以每个对象都是有这两个方法的,有时候我们需要实现特定需求,可能要重写这 ...

  5. Python中操作mysql的pymysql模块详解

    Python中操作mysql的pymysql模块详解 前言 pymsql是Python中操作MySQL的模块,其使用方法和MySQLdb几乎相同.但目前pymysql支持python3.x而后者不支持 ...

  6. 教程-Delphi中Spcomm使用属性及用法详解

    Delphi中Spcomm使用属性及用法详解 Delphi是一种具有 功能强大.简便易用和代码执行速度快等优点的可视化快速应用开发工具,它在构架企业信息系统方面发挥着越来越重要的作用,许多程序员愿意选 ...

  7. 在ASP.NET 5应用程序中的跨域请求功能详解

    在ASP.NET 5应用程序中的跨域请求功能详解 浏览器安全阻止了一个网页中向另外一个域提交请求,这个限制叫做同域策咯(same-origin policy),这组织了一个恶意网站从另外一个网站读取敏 ...

  8. c++中内存拷贝函数(C++ memcpy)详解

    原型:void*memcpy(void*dest, const void*src,unsigned int count); 功能:由src所指内存区域复制count个字节到dest所指内存区域. 说明 ...

  9. Android 中各种权限深入体验及详解

    Android 中各种权限深入体验及详解 分类: Android2012-07-15 19:27 2822人阅读 评论(0) 收藏 举报 androidpermissionsinstallersyst ...

随机推荐

  1. Byte[]、Image、Bitmap_之间的相互转换

    1.将图片Image转换成Byte[] /// <summary>        /// 将图片Image转换成Byte[]        /// </summary>     ...

  2. SpringMVC框架图解析

    Spring框架提供了构造Web应用程序的全能MVC模块.Spring MVC分离了控制器.模型对象.分派器以及处理程序对象的角色,这种分离让它们更容易进行制定.是一个标准的MVC框架. 那你猜一猜哪 ...

  3. EMV/PBOC 解析(二) 卡片数据读取

    上一篇简单的了解了IC智能卡的文件结构和APDU报文,这篇我们直接来读取卡内的数据.下面我们主要参照<中国金融集成电路(IC)卡规范>. 好了废话不多说,下面贴指令: (1)卡片接收一个来 ...

  4. Oracle&#39;s Business Intelligence Applications Configuration Manager 基本概念

    Oracle's Business Intelligence Applications Configuration Manager :BIACM Once the BIAPPS installatio ...

  5. How to configure Gzip for JBoss?---refer

    Question: I think to try to speed up my Web App by reducing the size of transferred data. For exampl ...

  6. 《UNIX网络编程》之select IO

    select 函数的原理 select 管理者 用select来管理多个IO 一旦其中的一个或者多个IO检测到我们所感兴趣的事件, select 函数返回,返回值为检测到的事件个数 然后,遍历事件,进 ...

  7. yii 删除内容时增加ajax提示

    环境 : 后台有新闻分类和新闻的文章,在分类下有文章存在的时候,不想用户删除分类 代码 controller public function actionDelete($id) { $data = C ...

  8. ubuntu 切换JDK版本

    安装: 第一种方式:sudo apt-get install openjdk-7-jdk(or openjdk-6-jdk) 第二种方式:tar -zxvf jdk-7u79-linux-x64.ta ...

  9. Examples_07_06 无法下载android的sdk

    在hosts里面配置. 74.125.237.1 dl-ssl.google.com 在AndroidManifest.xml中添加 <uses-feature android:name=&qu ...

  10. Wpf解决TextBox文件拖入问题、拖放问题

    在WPF中,当我们尝试向TextBox中拖放文件,从而获取其路径时,往往无法成功(拖放文字可以成功).造成这种原因关键是WPF的TextBox对拖放事件处理机制的不同, 解放方法如下: 使用Previ ...