<pre style="max-width: 100%;"><code class="cpp hljs" codemark="1"> LJMP INIT
LJMP IPT0
INIT: MOV TMOD,<span class="hljs-meta">#01H</span>
MOV TH0,<span class="hljs-meta">#0D8H</span>
MOV R0,<span class="hljs-meta">#100</span>
SETB EA
SETB TR0
MAIN: LCALL DATA_INIT
LCALL display
JNB P3<span class="hljs-number">.2</span>,CLEART
LJMP MAIN
IPT0: MOV TH0,<span class="hljs-meta">#0D8H ;65536max</span>
INC R0
LCALL SECOND
CPL P2<span class="hljs-number">.0</span>
CJNE R1,<span class="hljs-meta">#60,COMMEN1</span>
COMMEN1: RET
CPL P2<span class="hljs-number">.1</span>
CJNE R2,<span class="hljs-meta">#60,COMMEN2</span>
COMMEN2: RET
CJNE R3,<span class="hljs-meta">#24,COMMEN3</span>
COMMEN3: RET
RET
SETB EA
CLEART:MOV R0,<span class="hljs-meta">#0</span>
MOV R2,<span class="hljs-meta">#0</span>
RET
MOV B,<span class="hljs-meta">#10</span>
MOV <span class="hljs-number">30</span>H,B
MOV A,R1
DIV AB
MOV <span class="hljs-number">33</span>H,A
MOV B,<span class="hljs-meta">#10</span>
MOV <span class="hljs-number">34</span>H,B
MOV A,R3
DIV AB
MOV <span class="hljs-number">37</span>H,A
DISPLAY: MOV A,<span class="hljs-number">30</span>H
MOV P2,<span class="hljs-meta">#00000000B</span>
MOV P2,<span class="hljs-meta">#00000000B</span>
MOV A,<span class="hljs-number">31</span>H
MOV P2,<span class="hljs-meta">#00000100B</span>
MOV P2,<span class="hljs-meta">#00000100B</span>
MOVC A,@A+DPTR
MOV P0,A
MOV P0,<span class="hljs-meta">#00H</span>
MOV A,<span class="hljs-number">33</span>H
MOV P2,<span class="hljs-meta">#00001100B</span>
MOV P2,<span class="hljs-meta">#00001100B</span>
MOVC A,@A+DPTR
MOV P0,A
MOV P0,<span class="hljs-meta">#00H</span>
MOV A,<span class="hljs-number">35</span>H
MOV P2,<span class="hljs-meta">#00010100B</span>
MOV P2,<span class="hljs-meta">#00010100B</span>
MOVC A,@A+DPTR
MOV P0,A
MOV P0,<span class="hljs-meta">#00H</span>
MOV A,<span class="hljs-number">37</span>H
MOV P2,<span class="hljs-meta">#00011100B</span>
MOV P2,<span class="hljs-meta">#00011100B</span>
DB <span class="hljs-number">3f</span>H,<span class="hljs-number">06</span>H,<span class="hljs-number">5</span>bH,<span class="hljs-number">4f</span>H,<span class="hljs-number">66</span>H,<span class="hljs-number">6</span>dH,<span class="hljs-number">7</span>dH,<span class="hljs-number">07</span>H,<span class="hljs-number">7f</span>H,<span class="hljs-number">6f</span>H,<span class="hljs-number">77</span>H,<span class="hljs-number">7</span>cH,<span class="hljs-number">39</span>H,<span class="hljs-number">5</span>eH,<span class="hljs-number">79</span>H,<span class="hljs-number">71</span>H</code></pre>
<br>
<ignore_js_op>
<dl class="tattl attm">
<dd>
<img src="data/attach/1911/lluzfk2luzkpjyx2ydveuajpo5wvjjtc.jpg" alt="单片机.jpg" title="单片机.jpg">
</dd>
</dl>
</ignore_js_op>
<p><br></p>
一周热门 更多>