Author Topic: phonecall  (Read 544 times)


  • Member
  • ****
  • Posts: 867
  • Eagles are just great!
« on: May 17, 2017, 08:41:38 AM »
Ok i know this is stupid, but when you are learning (some difficult subject), you like to study the theory (what you must know ) and also apply what you have learned so far. And while i reach the creation of a window, i put here the " phone call" program, which is quite stupid, but fun too.  :lol:

Code: [Select]
.model  flat,stdcall
option  casemap:none

include c:\masm32\include\
includelib c:\masm32\lib\kernel32.lib


    mov     ebx,10
    push    1000 ; 1 second.
    push    500 ; At least in my netbook this sounds like a phone tone.
    call    Beep
    push    2000 ; 2 seconds
    push    0 ;  of silence.
    call    Beep
    dec     ebx ; 10 times.
    jnz     again
    push    0
    call    ExitProcess

    end     start

Don't worry, nobody will answer that call... :greensml: