Scan Code Finder

Discuss popular GCS tools like ZZT, Megazeux and Adventure Game Studio, as well as programming and other topics related to game design.
Post Reply
User avatar
tienkhoanguyen
PSEUDOCODER
Posts: 2664
Joined: Fri Sep 05, 2014 9:43 am
Location: Texas

Scan Code Finder

Post by tienkhoanguyen »

God, Jesus Christ, is number one!hehe
Jesus Christ!hehe
Bless Jesus Christ!
Then please bless my mom.
Honour to my mom Huong Thi Vu
Honour to my dad Thuy Binh Nguyen
Love to cousin Carl Anh Cuong Cao Vu
Thank you Jesus Christ.
User avatar
tienkhoanguyen
PSEUDOCODER
Posts: 2664
Joined: Fri Sep 05, 2014 9:43 am
Location: Texas

God, Jesus Christ, is number one!hehe

Post by tienkhoanguyen »

Jesus Christ!hehe

If we are working in C it is easy to use key detections.

However if we are working in assembly language we need the scan codes.

So ironically this C program finds the scan codes for assembly hehe
God, Jesus Christ, is number one!hehe
Jesus Christ!hehe
Bless Jesus Christ!
Then please bless my mom.
Honour to my mom Huong Thi Vu
Honour to my dad Thuy Binh Nguyen
Love to cousin Carl Anh Cuong Cao Vu
Thank you Jesus Christ.
User avatar
tienkhoanguyen
PSEUDOCODER
Posts: 2664
Joined: Fri Sep 05, 2014 9:43 am
Location: Texas

God, Jesus Christ, is number one!hehe

Post by tienkhoanguyen »

Jesus Christ!hehe

So if we wanted to detect say one of the keyboard letters in assembly:

We would use the scan code finder for that specific key press code. hehe
God, Jesus Christ, is number one!hehe
Jesus Christ!hehe
Bless Jesus Christ!
Then please bless my mom.
Honour to my mom Huong Thi Vu
Honour to my dad Thuy Binh Nguyen
Love to cousin Carl Anh Cuong Cao Vu
Thank you Jesus Christ.
User avatar
tienkhoanguyen
PSEUDOCODER
Posts: 2664
Joined: Fri Sep 05, 2014 9:43 am
Location: Texas

God, Jesus Christ, is number one!hehe

Post by tienkhoanguyen »

Jesus Christ!hehe

interrupt 16h using AH value equal to 0 is the scan code detection routine

the same interrupt using AH value equal to 1 is the same except:

it only stops when no key is in the buffer

The zero flag is equal to 1 if no key is in the buffer

(earlier I handed out an interrupt list and this interrupt is listed there)
[please verify just in case my memory is wrong]
God, Jesus Christ, is number one!hehe
Jesus Christ!hehe
Bless Jesus Christ!
Then please bless my mom.
Honour to my mom Huong Thi Vu
Honour to my dad Thuy Binh Nguyen
Love to cousin Carl Anh Cuong Cao Vu
Thank you Jesus Christ.
User avatar
tienkhoanguyen
PSEUDOCODER
Posts: 2664
Joined: Fri Sep 05, 2014 9:43 am
Location: Texas

God, Jesus Christ, is number one!hehe

Post by tienkhoanguyen »

Jesus Christ!hehe

Scancode cheat sheet just in case mine doesn't work right.

http://www.mediafire.com/view/ki279csil ... _codes.pdf
God, Jesus Christ, is number one!hehe
Jesus Christ!hehe
Bless Jesus Christ!
Then please bless my mom.
Honour to my mom Huong Thi Vu
Honour to my dad Thuy Binh Nguyen
Love to cousin Carl Anh Cuong Cao Vu
Thank you Jesus Christ.
User avatar
tienkhoanguyen
PSEUDOCODER
Posts: 2664
Joined: Fri Sep 05, 2014 9:43 am
Location: Texas

God, Jesus Christ, is number one!hehe

Post by tienkhoanguyen »

Jesus Christ!hehe

Here is a scan code finder.

It is written in all Borland Turbo Assembler 4.1 unlike the previous one.

The previous one was made using Borland Turbo C 2.01 at that time.

http://www.mediafire.com/download/ee93q ... nours3.zip
God, Jesus Christ, is number one!hehe
Jesus Christ!hehe
Bless Jesus Christ!
Then please bless my mom.
Honour to my mom Huong Thi Vu
Honour to my dad Thuy Binh Nguyen
Love to cousin Carl Anh Cuong Cao Vu
Thank you Jesus Christ.
User avatar
tienkhoanguyen
PSEUDOCODER
Posts: 2664
Joined: Fri Sep 05, 2014 9:43 am
Location: Texas

God, Jesus Christ, is number one!hehe

Post by tienkhoanguyen »

Jesus Christ!hehe

In this scan coder finder one we have letters.

It is still made in pure Borland Turbo Assembler 4.1.

The only difference is that the letters are made to be interchangeable.

For instance, in the future you get bored and just install the new one.

So it looks different.

The message is the same however the set is different.

In previous ones of my custom set is was not made to be easily changeable.

This one still looks generic just for testing purposes (my beta) haha
God, Jesus Christ, is number one!hehe
Jesus Christ!hehe
Bless Jesus Christ!
Then please bless my mom.
Honour to my mom Huong Thi Vu
Honour to my dad Thuy Binh Nguyen
Love to cousin Carl Anh Cuong Cao Vu
Thank you Jesus Christ.
User avatar
tienkhoanguyen
PSEUDOCODER
Posts: 2664
Joined: Fri Sep 05, 2014 9:43 am
Location: Texas

God, Jesus Christ, is number one!hehe

Post by tienkhoanguyen »

God, Jesus Christ, is number one!hehe
Jesus Christ!hehe
Bless Jesus Christ!
Then please bless my mom.
Honour to my mom Huong Thi Vu
Honour to my dad Thuy Binh Nguyen
Love to cousin Carl Anh Cuong Cao Vu
Thank you Jesus Christ.
User avatar
tienkhoanguyen
PSEUDOCODER
Posts: 2664
Joined: Fri Sep 05, 2014 9:43 am
Location: Texas

God, Jesus Christ, is number one!hehe

Post by tienkhoanguyen »

Jesus Christ!hehe

Here is my updated scan code finder.

It has the proper alignment for AL and AH texts.

If you compare this with the version written in C the values *should* be same.

When you press a key it shows the scan code in AL and AH accordingly.

Please note that contrary to popular beliefs you need BOTH AL and AH values.

http://www.mediafire.com/download/1avaj ... f825v2.zip
God, Jesus Christ, is number one!hehe
Jesus Christ!hehe
Bless Jesus Christ!
Then please bless my mom.
Honour to my mom Huong Thi Vu
Honour to my dad Thuy Binh Nguyen
Love to cousin Carl Anh Cuong Cao Vu
Thank you Jesus Christ.
Post Reply