OutBufDXasDecimal: push eax push ebx push esi sub esp, 24h mov eax, edx ; value mov ebx, 10 ; radix mov esi, esp .repeat xor edx, edx div ebx mov [esi], dl inc esi .until eax==0 .repeat dec esi mov al, [esi] add al, '0' stosb .until esi==esp add esp, 24h pop esi pop ebx pop eax retn ;OutBufDXasDecimal ends
dw2asc proc hnum:dword, strmem:ptr ;from electro_m23 at yahoo.com via Iczelion's Win32 Assembly Forum push edi mov edi,strmem mov ecx,28 l1l1: mov eax,hnum shr eax,ecx and al,0fh cmp al,10 jb noneedforalpha add al,'a'-'0'-10 noneedforalpha: add al,'0' sub ecx,4 mov [edi],al inc edi cmp ecx,-4 jg l1l1 mov eax,strmem pop edi ret
See also:
| file: /Techref/intel/32bit/math/b2a-32b10d.htm, 0KB, , updated: 2000/5/1 09:02, local time: 2012/2/9 19:38,
38.107.179.231:LOG IN |
| ©2012 These pages are served without commercial sponsorship. (No popup ads, etc...).Bandwidth abuse increases hosting cost forcing sponsorship or shutdown. This server aggressively defends against automated copying for any reason including offline viewing, duplication, etc... Please respect this requirement and DO NOT RIP THIS SITE. Questions? <A HREF="http://www.piclist.com/techref/intel/32bit/math/b2a-32b10d.htm"> intel 32bit math b2a-32b10d</A> |
| Did you find what you needed? |
Robotics nuts!Check out http://users.frii.com/dlc/robotics/projects/botproj.htm from Dennis Clark. This guy ROCKS! He has made (and sells but also releases code, docs, etc...) for a number of cool little robotic modules including whiskers, IR proximity detect and remote control, Sonar proximity detect, PWM, Servo, compass. Most of these use the little PIC 12C508 controller which costs basically nothing and is soooo tiny.The 4 servos, 2400 baud serial servo controller is a wonder of magic and he sells the programmed chip for $8. Wow! |
.