Jump to content
ELFORUM - Forumul electronistilor

Pic explicare cod incepator


Recommended Posts

Salut,

Am si eu o rugaminte imi poate explica cineva cum functioneaza urmatoarea secventa de cod? Mentionez ca am gasit-o intr-un program si fiind incepator nu am inteles cum functioneaza ...dupa parerea mea ar trebui sa intre in ciclu infinit dar nu o face.

;---------------------------------------------------------------------------WAIT_100ms   ;---------------------------------------------------------------------------;intarziere de 100 ms     		movlw   .129		movwf   Waux2_SYS_LOOP6			movlw   0		movwf   Waux1_SYS_LOOP7			decfsz  Waux1,f		goto    _SYS_LOOP7		decfsz  Waux2,f		goto    _SYS_LOOP6	;2+1+1+129*(2+256*3+1+2)=99,721 ms		movlw   .93		movwf   Waux1_SYS_LOOP8		decfsz  Waux1,f		goto    _SYS_LOOP8		decfsz  Waux2,f		;+2+93*3=100,002 ms		return			;+2=100,004 ms;---------------------------------------------------------------------------
dupa parerea mea ...ar trebui sa intre in ciclu infinit la sys loop 07 deoarece are o trimitere neconditionata (goto) mentionez ca am cunostinte de java si c /c++ asa ca va rog sa explicati cat mai 'babeste' deoarece nu m-am mai lovit de asm. Deasemenea nu inteleg ce este cu toate calculele de milisecunde .Va multumesc anticipat
Link to comment
  • Replies 3
  • Created
  • Last Reply

Top Posters In This Topic

Top Posters In This Topic

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now



×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.Terms of Use si Guidelines