First post, by freecrac
			
								freecrac
								Offline
			
			
				
					
			
		
					
																	Rank
				Newbie
																
			I am on an Android tablet with the Magic DOSBOX app installed and i try to make a counter for hexadecimal values (with a little help from Debug).
The counter starts with 00 and ends with FF..
But i am not sure if the envroment variables are always stored on the same memory location. Example: 0000:12B0
If it run properly it prints the hex numbers on the screen:
00
01
03
..
EE
EF
FF
Please can you test the batch file and give an answer if it works or not.
@Echo offREM *LOOP.BAT*set VA=00REM Loop from VA to if commandREM Hex-Counter for VAecho a cs:100>tmp.debecho xor ax,ax>>tmp.debecho mov ds,ax>>tmp.debecho mov si,12B0>>tmp.debecho mov ax,4156>>tmp.debecho cmp [si],ax>>tmp.debecho jz 0111>>tmp.debecho inc si>>tmp.debecho jnz 010A>>tmp.debecho add si,3>>tmp.debecho mov ah,[si]>>tmp.debecho mov al,[si+1]>>tmp.debecho cmp al,39>>tmp.debecho ja 0123>>tmp.debecho jnz 0136>>tmp.debecho mov al,41>>tmp.debecho jmp 0138>>tmp.debecho cmp al,46>>tmp.debecho jnz 0136>>tmp.debecho mov al,30>>tmp.debecho cmp ah,39>>tmp.debecho jnz 0132>>tmp.debecho mov ah,41>>tmp.debecho jmp 0138>>tmp.debecho inc ah>>tmp.debecho jmp 0138>>tmp.debecho inc al>>tmp.debecho mov [si],ah>>tmp.debecho mov [si+1],al>>tmp.debecho ret>>tmp.debecho.>>tmp.debecho n VAR.COM>>tmp.debecho rcx>>tmp.debecho 3E>>tmp.debecho wcs:100>>tmp.debecho q>>tmp.debdebug<tmp.deb>nuldel tmp.deb:A1VAR.COMecho %VA%if %VA% ==FF goto ENDgoto A1:ENDset VA=del VAR.COM
Debug from the Freedos Operating System:
http://sites.google.com/site/pcdosretro/enhdebug
http://www.ibiblio.org/pub/micro/pc-stuff/fre … html/debug.html
Debug manual: http://www.armory.com/~rstevew/Public/Tutor/D … bug-manual.html
(Download and extract debug into the mounted folder of DOSBOX.)