Results 1 to 6 of 6

Thread: Questions in Assembler - Created a PIANO wheee :)

  1. #1

    Thread Starter
    New Member
    Join Date
    Apr 2002
    Posts
    2

    Questions in Assembler - Created a PIANO wheee :)

    I have a problem in my piano program -
    i want to make a part in my program that is responsible for the color change in the piano keys in such a way that AS LONG AS A KEYBOARD KEY IS PRESSED that piano key that is related to the keyboard key will be BLUE (creating a delay that is reacting to the key press, or something) and the moment the finger is released from the key - it will turn white again.
    i dont know how to create such a delay - now im using a fixed delay which is no good at all... sometimes when i press the same key twice fast it doesnt show the blue thing appropiately
    besides that i need help in many more things... if someone will be willing to help me - i will appreciate it very much

    thank you in advance
    amit

  2. #2

    Thread Starter
    New Member
    Join Date
    Apr 2002
    Posts
    2

    Help ...

    Pleaseee help me !
    My project is 'supposed' to be handed over in a week and i have no idea how to solve this !

    arhhhhhh

  3. #3
    Frenzied Member numtel's Avatar
    Join Date
    Apr 2000
    Location
    CA
    Posts
    1,163
    at http://board.win32asmcommunity.net/ you'll get a much faster response

  4. #4
    New Member
    Join Date
    Apr 2002
    Location
    Sarajevo
    Posts
    3
    The thing that may help you is to use ports ....

    if you know pascal this would be it ... the asm is not much different


    Program test_keybp;
    begin
    repeat
    Witeln(port[$60]);
    until port[$60] = 1;
    end.


    this program will loop ..until you press ESC
    and write the codes of the key(s) pressed...

    you can say :

    make_blue;

    while port[$60] = xxx do begin
    {stay blue, or do something}
    end;

    return_to_white;


    the instruciton in ASM is IN for reading and OUT for writ...

    There is a problem with this ...you need to find a way to tell
    the comp. that you handled the key change or it will beep ...
    like hell..
    how to do that I do not know..


    sorry for the way I wrote this, no time for decorations
    Try something else.

  5. #5
    New Member
    Join Date
    Apr 2002
    Location
    Sarajevo
    Posts
    3

    ups

    I forgot, the $60 (60h) is the "place" where the status
    of the keyb. is kept... so any change will be noticable by
    comparing ...


    I will post the code ... as soon as I get my hands on masm
    or pascal, tried to do a .com in debug.exe but I love my
    self and my self and decided not to.
    Try something else.

  6. #6
    Kitten CornedBee's Avatar
    Join Date
    Aug 2001
    Location
    In a microchip!
    Posts
    11,594
    some port near that tells that you handled it.
    All the buzzt
    CornedBee

    "Writing specifications is like writing a novel. Writing code is like writing poetry."
    - Anonymous, published by Raymond Chen

    Don't PM me with your problems, I scan most of the forums daily. If you do PM me, I will not answer your question.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width