Assembly之instruction之JC
JC Jump if carry set
JHS Jump if higher or same
Syntax JC label
JHS label
Operation
If C = 1: PC + 2 × offset −> PC
If C = 0: execute following instruction
Description
The status register carry bit (C) is tested. If it is set, the 10-bit signed offset contained in the instruction LSBs is added to the program counter. If C is reset, the next instruction following the jump is executed. JC (jump if carry/higher or same) is used for the comparison of unsigned numbers (0 to 65536).
Status Bits
Status bits are not affected.
Example
The P1IN.1 signal is used to define or control the program flow.
BIT #01h,&P1IN ; State of signal −> Carry
JC PROGA ; If carry=1 then execute program routine A
...... ; Carry=0, execute program here
Example
R5 is compared to 15. If the content is higher or the same, branch to LABEL.
CMP #,R5
JHS LABEL ; Jump is taken if R5 ≥ 15
...... ; Continue here if R5 < 15
Assembly之instruction之JC的更多相关文章
- Assembly之instruction之JUMP
JMP Jump unconditionally Syntax JMP label Operation PC + 2 × offset −> PC Description The 10- ...
- Assembly之instruction之Indirect Autoincrement Mode
Assembler Code Content of ROMMOV @R10+,0(R11) MOV @R10+,0(R11) Length: One or two words Operation: ...
- Assembly之Instruction之Byte and Word
Byte and word issues The MSP430 is byte-addressed, and little-endian. Word operands must be located ...
- Assembly之instruction之Status register
The status register (SR/R2), used as a source or destination register, can be used in the register m ...
- Assembly之instruction之Register Mode
Assembler Code Content of ROM MOV R10,R11 MOV R10,R11 Length: One or two words Operation: Move the c ...
- Assembly之instruction之MOV
MOV[.W] Move source to destinationMOV.B Move source to destination Syntax MOV src,dst or M ...
- Assembly之instruction之CMP
CMP[.W] Compare source and destinationCMP.B Compare source and destination Syntax CMP src,dst or ...
- BitHacks
备份文件时看到的.我以前居然下过这东西. 2016-12-4 12:05:52更新 纯文本格式真棒.假如使用word写的我能拷过来格式还不乱?? Markdown真好. Bit Hacks By Se ...
- Bit Twiddling Hacks
http://graphics.stanford.edu/~seander/bithacks.html Bit Twiddling Hacks By Sean Eron Andersonseander ...
随机推荐
- C#高级编程四十八天----列表
C#中的List C#中deList怎么样?List<T>类是ArrayList类的泛型等效类,该类使用大小可按需动态增长的数组实现List<T>泛型接口. 泛型的优点:它为使 ...
- 【Hibernate学习】 ——ORM(一)
Hibernate是一种能实现ORM的框架. ORM即Object Relational Mapping.对象关系映射.也就是将关系数据库中表的数据映射成为对象.也就是说将表与表之间的操作映射成对象与 ...
- 演练:我的第一个 WPF 桌面应用程序 https://docs.microsoft.com/zh-cn/dotnet/framework/wpf/getting-started/walkthrough-my-first-wpf-desktop-application
这篇文章演示如何开发简单的 Windows Presentation Foundation (WPF) 应用程序包括元素所共有的大多数 WPF 应用程序: 可扩展应用程序标记语言 (XAML) 标记. ...
- WCC框架设计
一个好的框架,不仅能帮助程序开发节约很多时间,同时也能减少bug的引入.这个框架是在ssy同学的基础上进行了一些改进: 主要在于一下几点(会随着项目开发逐渐更新这篇文章) 1. 应用了反射机制,实现网 ...
- Mycat(5):聊天消息表数据库按月分表实践,平滑扩展
本文的原文连接是: http://blog.csdn.net/freewebsys/article/details/47003577 未经博主同意不得转载. 1,业务需求 比方一个社交软件,比方像腾讯 ...
- [英语学习]微软面试前英语集训笔记-day 1
最近有机会参加微软面试前的英语集训. 第一天是由wendy老师主讲.热场题目是介绍你自己.包括你的姓名,家庭hobby,爱好,专业,学校,工作经历等等. 接下来的主题是friendship.给我印象较 ...
- JavaScript总结01
1 JavaScript 与 Java 的关系? 雷锋和雷峰塔的关系JavaScript和Java都与sun公司有合作,是借势Java 2 JavaScript 的特点是什么? 脚本语言(一种轻量级的 ...
- WinForm里面连接Oracle数据库
WinForm里面连接Oracle数据库 string oradb = "Data Source=(DESCRIPTION=" + "(ADDRE ...
- Java 高级数据结构 —— Properties
1. Properties Properties 是 Java 的内置实现: public class Properties extends Hashtable<Object,Object> ...
- js几种escape()解码与unescape()编码
js几种escape()解码与unescape()编码 www.111cn.net 编辑:kepeer 来源:转载 一篇js几种escape()解码与unescape()编码函数,同时我们也和它和服务 ...