技术论坛

回复:对RLO和BR理解不透,请好心人教教我。

作者 主题
奇侠

经验值: 6872
发帖数: 5350
精华帖: 25
回复:对RLO和BR理解不透,请好心人教教我。


只看楼主 2006-10-18 12:10:50
quote:以下是引用wangtaotao在2006-10-18 01:04:42的发言:
quote:以下是引用shine在2006-10-17 16:02:01的发言:
那就是书中错了。你可以看Step7的在线帮助。
对于其他指令,看帮助中各条指令对状态字的影响

shine 老师:能和我说说“Step7的在线帮助”在哪里吗?
谢谢您!


你说Step7在线帮助会不会在我的电脑上?

你用程序写一个jnb 然后试试看F1键能否看到帮助

Format

JNB

Address Des cription
Symbolic name of jump destination.
Des cription

If the result of logic operation is 0, JNB interrupts the linear program scan and jumps to a jump destination. The linear program scan resumes at the jump destination. The jump destination is specified by a
jump label. Both forward and backward jumps are possible. Jumps may be executed only within a block, that is, the jump instruction and the jump destination must lie within one and the same block. The jump destination must be unique within this block. The maximum jump distance is -32768 or +32767 words of program code. The actual maximum number of statements you can jump over depends on the mix of the statements used in your program (one-, two-, or three word statements).

If the result of logic operation is 1, the jump is not executed. The RLO is set to 1 and the program scan continues with the next statement.

Independent of the RLO, the RLO is copied into the BR when there is a JNB instruction.

Status word

BR CC 1 CC 0 OV OS OR STA RLO /FC
writes: x - - - - 0 1 1 0
Example

STL Explanation
A I 1.0
A I 1.2
JNB JOVR //Jump if RLO = 0 to jump label JOVR. Copy RLO bit contents into the BR bit.
L IW8 //Program scan continues here if jump is not executed.
T MW22
JOVR: A I 2.1 //Program scan resumes here after jump to jump label JOVR.
怎么论坛改成这样了??
以下网友喜欢您的帖子:

  
重要声明:

著作权归作者所有。商业转载请联系作者获得授权,非商业转载请注明出处。

帖子链接:http://www.ad.siemens.com.cn/club/bbs/post.aspx?a_id=279265&b_id=4&s_id=0&num=0

  • 上一页
  • 1
  • 下一页
收起
回复:对RLO和BR理解不透,请好心人教教我。
×
扫描打开手机版
您收到0封站内信:
×
×
信息提示
很抱歉!您所访问的页面不存在,或网址发生了变化,请稍后再试。