Pages

Tuesday, April 28, 2009

100 Truths

001. Real Name: Ng Khin Hooi

002. Nickname(s): i don't really have a nickname

003. Age: 19 + 1, too afraid to admit i am a 2X.

004. Horoscope: mighty Leo

005. Male or Female: Male

006. Elementary: What is elementary? Gospel Chapel Kindergarten

007. Middle School: SRB St Joseph, Miri (It was used to called sekolah rendah bantuan)

008. High School: SMK St Joseph, Miri

009. College School: College of Science and Technology

010. Hair colour: Black

011. Long or Short: My hair or my? If hair, it is short

012. Loud or Quiet: Quiet

013. Sweats or Jeans: Jeans.

014. Phone or Camera: Camera, i don't use phone too much

015. Health Freak: Not really

016. Drink or Smoke: Social Drinker

017. Do you have a crush on someone: Erm, not really, but i admire.

018. Eat or Drink: Eat

019. Piercings: None

020. Tattoos: None, pierce or tattoo will delay by blood donation for one year. Can't have that.

021. Social or Anti-Social: At the middle. Not really social much and not really the anti-social type. Hard to explain.

022. Righty or lefty: Lefty. Does this makes me live shorter?

023. First piercing: Erm, omit.

024. First relationship: Skip

025. First Best Friend: Non, I don't believe in 'best friend'.

026. First Award: Erm, getting a phone for PMR result, a Nokia 3315. haha. still using it now.

027. First Kiss: Skip

028. First Pet: Never have one, allergic to the fur.

029. First Big Vacation: I travel since I was a baby, so cannot remember la.

030. First Love at first sight: Diploma first year. A girl, and she is so purty. Too bad, tak jadi.

031. First Big Birthday: Erm, never.

032. First Surgery: Never

033. First sport you joined: I don't do sports.

034. Orange or Apple juice: Orange

035. Rock or Rap: Rock is nice, Rap is too fast. = = blurred.

036. Country or Screamo: What is this?

037. NSYNC or Backstreet boys: Erm, O2Jam,

038. Britney spears or Christina Aguilera: O2Jam...

039. Night or Day: Night.

040. Sun or Moon: Sun, I like night, but like sun, weird ey.

041. TV or Internet: Internet

042. Playstation or xbox: Never played any before.

043. Kiss or hug: Hug, kiss is so wet and saliva-sharing

044. Iguana or turtle: Turtle, in fact, both are disgusting.

045. Spider or bee: Erm, both are scary.

046. Fall or spring: Never try, Hello, we live in Malaysia lah.

047. Limewire or iTunes : Never use

048. Soccer or baseball: Don't sports.

049. Eating: Saliva?

050. Drinking: Saliva?

051. Excitement level: I can get very very high, on special occasion and around people I really know well only but usually, I am a quiet person.

052. I'm about to: Have my dinner and find a friend to discuss about project.

053. Listening to: Dunno title, it is in chinese.

054. Plan for today: It is night time already la. I went to KLCC to wander around doing nothing.

055. Waiting for: Nothing. wait to finish this survay

056. Energy Level: 50%, stomach empty la.

057. Thinking of someone: A purty girl I saw at KLCC.

058. Want kids?: I want, but not obsessed la, I am not a pedo.

059. Want to get married?: Yes? Hey, why this question comes after question 58?

060. When?: I really don't know la. If can before 28? and beforeafter I get rich.

061. How many kids do you want: I think 3 is good. 2 boys and 1 girl like my parents did. kaka.

062. Any name on the mind: Erm, erm, Shewern

063. What do you want to do: Finish the project I intend to do.

065. Mellow future or wild: Mellow. Find a girl, marry, have kids, and live until ripe age. = =. Hahaha.

066. Something you would never try: Drink until I am drunk and try to enter the college.

067. When do you want to die: I want one thing, that is to see the Halley Comet. Which means is 80 or 90. = =

068. Lips or Eyes: Eyes are the nipples of the face, according to Shirley of House Bunny

069. Romantic or Funny?: Funny. Romantic is so geli.

070. Shorter or Taller?: Me ???? I want taller.

071. Protective or Caring?: I am caring.

072. Romantic or Spontaneous?: I don't understand la.

073. Nice Stomach or Nice Arms?: Me? My stomach is bulgy, arm is skinny. ><

074. Sensitive or Loud?: Sensitive.

075. Hook-up or Relationship?: Relationship.

076. Trouble Maker or Hesitant?: Hesitant.

077. Muscular or normal: Normal.

078. Kissed a stranger: No

079. Broken a bone: No.

080. Lost glasses or contacts: No, but I wear glasses.

081. Ran away from home: Why would I do that, only stupid people do it.

082. Held a gun/knife for self defence: No.

083. Killed somebody: Erm, if something is accplicable, yes, ants and cockroaches.

084. Broken some one's heart: Skip

085. Had your heart broken: Skip

086. Been arrested: Arrested where?

087. Cried when someone died: Depend on who la. Haiyah. so choi la.

088. Liked a friend more than a friend: No.

089. Yourself: I like myself

090. Miracles: I don't believe in this crap la. We are living in a scientific worlds, not mystical.

091. Love at first sight: I believe it.

092. Heaven: I don't believe this, I believe in Nirvana.

093. Santa Claus: Fake, but surprisingly, Santa can appear in so many place at a time during Chirstmas.

094. Tooth Fairy: Fake la, Who will trade money with some broken tooth?

095. Kiss in the first date: Haha, I want one.

096. Angels: I don't believe.

097. Is there 1 person you want to be with right now? : Yeah.

098. Are you seriously happy with where you're in life now? : Serious? I can say I am content.

099. Do you believe in God? : Not really, I believe in Enlightment.

100. Post as 100 truths and tag 10 people


Tags:

01. Estina Yap and Azu

02. Zara

03. Xinying

04. VOON SOON PING

05. Babysiaozz - If you have not finish this, please do.

06. Zulika

07. SheWern

08. Cannot find liao, sorry.

Sunday, April 26, 2009

My Diploma Is Finally Over

By the end of the last paper, Microprocessor, ends with it my Diploma.
Attach not thy self to the surround and thy will not feel the Dukkha.

Here are the graduation audit
UDB1312 ENGLISH PROFICIENCY 2
CE 200620071
UDB1322 ENGLISH FOR ACADEMIC COMMUNICATION 2
CE 200620071
DDE1103 LITAR ELEKTRIK 3 A
200620071
DDE1702 WORKSHOP ELEKTRONIK / ELEKTRIK 2 A
200620071
DDS1012 GEOMETRI & TRIGONOMETRI 2 A
200620071
DDS1112 ALJABAR 1 2 A
200620071
DDS1713 FIZIK 3 A
200620071
UDP1152 HUBUNGAN ETNIK 2 A-
200620071
UDU1051 PERTOLONGAN CEMAS I 1 A
200620071
DDC1012 PENGATURCARAAN 2 A+
200620072
DDE1313 ELEKTRONIK DIGITAL I 3 A+
200620072
DDE1412 PENGALATAN DAN PENENTUKURAN 2 A+
200620072
DDE1711 MAKMAL KEJURUTERAAN ELEKTRIK 1 1 A+
200620072
DDS1212 KALKULUS I 2 A+
200620072
DDS2112 ALJABAR II 2 A+
200620072
UDT1022 TITAS 2 A+
200620072
DDE2023 PERISIAN KEJURUTERAAN 3 A+
200720081
DDE2113 TEORI LITAR I 3 A+
200720081
DDE2323 ELEKTRONIK DIGITAL II 3 A+
200720081
DDE2721 MAKMAL KEJURUTERAAN ELEKTRIK II 1 A+
200720081
DDJ2901 WOKSYOP MEKANIKAL 1 A+
200720081
DDS2212 KALKULUS II 2 A+
200720081
UDB2332 ENGLISH FOR PROFESIONAL COMMUNICATION 2 A
200720081
UDP2152 ETIKA PROFESIONAL 2 A
200720081
DDB2732 MAKMAL KEJURUTERAAN MEKATRONIK I 2 A
200720082
DDE2123 TEORI LITAR II 3 A+
200720082
DDE2213 ELEKTRONIK I 3 A+
200720082
DDJ2102 STRUKTUR & MESIN 2 A+
200720082
DDJ2502 LUKISAN KEJUTERAAN BERBANTU KOMPUTER 2 A
200720082
DDK2603 TEKNOLOGI ELEKTRIK 3 A+
200720082
UDT2032 INSTITUSI-INSTITUSI ISLAM 2 A-
200720082
DDB3742 MAKMAL KEJURUTERAAN MEKATRONIK II 2 A
200820091
DDE3223 ELEKTRONIK II 3 A+
200820091
DDE3422 INSTRUMENTASI 2 A
200820091
DDE3433 SISTEM KAWALAN 3 A+
200820091
DDE3452 PENGAWAL LOGIK BOLEH ATUR CARA (PLC) 2 A+
200820091
DDE3802 PENGURUSAN KEJURUTERAAN 2 A+
200820091
DDJ3312 KUASA BENDALIR 2 A+
200820091
UDT3052 PERKEMBANGAN KENDIRI 2 B+
200820091
And for the last semester, I took, Makmal Kejuruteraan Mekatronik III, Rekabentuk Komponen, Mikropemproses, Mesin and Pemacu Elektrik, Automasi Industri dan Robotik.

Khinhooi

Weird Dream

I was in a journey to visit a tribe. I guess it is an African Tribe or something like that. The air plane drop us in a desert and it was dawn, the sun has not yet risen. I came down by parachute. After landing, I have to run as fast as I could through the desert to get to the next area before the sun has fully risen. I ran and finally I reached an place with trees. The place is quite nice and there are some ruins there. I saw a native there and I ask so politely for water. He gave me something that looks like a coconut the the shell is soft. I drank up. Then I continue my journey. I came to a tar road. After crossing, I came across some soldiers. I don't know what they are doing there. After the road, there was a casino area. It was big and some what looks like a shop lots or commercial area. I continue ahead and finally reached a beach. It was very beautiful. I could not find the tribe so I asked an old lady. She asked me to turn right and go along the coast. I walked and finally found the tribe.

Saturday, April 25, 2009

Robotic Project Presentation


We load the project into the car to bring it to campus. Courtesy to the car owner.


Our presentation is after the Machine Drive Examination.


Setting up the project. It takes time though to calibrate the system so it is accurate and yet it turned out not accurate.


To demonstrate the project before presenting.


This is after the presentation. Not happy but content.


Our group who does the project. The mastermind is at the center, whahahaha. Hmm.

Now I am planning to upgrade the project from PLC to Microcontroller. Planned to use a password system and improve the positioning of the closed loop control. I wanted to make a full PID controller, with I gain and D gain. Which is tedious, not hard but tedious work.

We could integrate it into a car parking system where you need to punch in your car plat number and enter a password. And a few other functions. Hmmm.

Khinhooi

Saturday, April 18, 2009

Closed Loop Control System for Automated Parking Space

This is a so called closed loop control for my project. It is all in the 'Control Box'.

Input to the box is the sequence control of Programmable Logic Controller (PLC) and the output is the motor driver. Also the input for the box is feedback for the motor position.


This is how the inside looks like. We have three motors to control. We have a input set value and the main brain is the three tiny black things.


This is the project. The motor at the top is to control the up down movement. Motor at the middle is to control in out movement. Motor at the base is to control left right movement.


It is basically a storage system with a pickup and drop off point. Three of the motors will run to store the 'cars' with instructions from the PLC.

Khinhooi

Tuesday, April 14, 2009

Closed Loop Control System


It has been a few days I been doing this thing as above. A simple closed loop control system. A closed loop system is actually like a system that gives what you want. If you want the temperature to be 30 degree Celsius, it will give you 30 degree Celsius.

Making this system is actually simple if you know the basic in control system. I am doing two closed loop control for my robotic project. One for up and down motion, another is for rotating position. Sorry no picture for the project now.

The system is actually called Proportional and Integrator On Off controller. This system will give you a control with no steady state error, means the output you want will be very accurate. Till now the system explained. Sorry for those who do not understand.

Khinhooi.
P.S. Picture will be at the next post.

Sunday, April 12, 2009

Robotics Goes Smoothly

After some ups and downs for the robotics project, it is coming to some steady state but it is not done yet. Everything is smooth now. The structure is done thanks to the team. It is now comes to the circuit. I have designed the closed loop control system (not design la, taken only). The circuit is completed save for the feedback part. Of course in a closed loop control system, you need a feedback. Tomorrow Azu is going to get the multi turn potentiometer which cost a freaking RM 25.00. After getting the feedback, we need to tune the gain of the control system to suite the motor. And this is for the up and down, motor. The rotary motor is still not done, the in and out motor is still not yet done. The sensor is not yet done. The program is not yet done. Darn.

Khinhooi

Friday, April 10, 2009

Time Do Flies

Have you ever feel so peace and so calm, then suddenly all those have to go. And when you are back, you are bombarded with jobs and tasks and responsibilities. And it was the only chance you can relax and enjoy the time, when you are back to the things you are suppose to do.

I do not know why I am always in the responsibility. Well, at least as I think I am in one. Why do not I get the chance to live the carefree live. Maybe in this life, there is no carefree life unless you are damn filthy rich.

Why I am the one who always concerns? If I care less about the other stuff, maybe I won't be that tensed. I meant tensed, not stressed. Why I am the one who wants everything to be perfect and high quality. I can feel the difference there. Why I am the idealist thinker?

Who knows one day a cable in high tension will reach its fatigue life cycle and breaks.

Tuesday, April 7, 2009

Need to Concentrate on Robotics

Since the Component Design today (or yesterday) officially finish, I mean the subject is finished, no more class, no more presentation, no more test, no final.

And I have done my microcontroller project, I need to concentrate on the Robotics project now.

The structure is done and now we are left with the circuitry and programming.

Now, there is two paths, to use closed loop control system or limit switches?

I am venturing into closed loop control and the others is into limit switches.

Not sure which one to choose.

Khinhooi

Wednesday, April 1, 2009

A Completion of Project

Today, we have done another project. Microcontroller 8051.

The task is to make a password system. Turn on switch 1, it will show three digits on the 7 segment display. Then turn on switch 2, we need to enter the three digits correctly.

If the password is wrong, it will display a 'H' at the seven segment display. If it is correct, the LED need to blink five times.

So much for a credit of Microcontroller 8051.

Khinhooi
P.S. Here are the language
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;
; NG KHIN HOOI
; MARCH 06, 2009
; PROJECT FOR MICROCONTROLLER
; SECOND VERSION
;
; DIP SWITCH BUFFER 4000, PORT0
; KEYPAD BUFFER 4000,
; LED LATCH 6000, PORT2
; 7SEGMENT PORT1
;
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;

ORG 2200H
CODE_1 EQU 0F9H ; HEXADECIMAL FOR NUM '1' COMMON ANODE
CODE_2 EQU 0A4H ; HEXADECIMAL FOR NUM '2' COMMON ANODE
CODE_3 EQU 099H ; HEXADECIMAL FOR NUM '4' COMMON ANODE
BUFFER EQU 4000H ; ADDRESS FOR BUFFER
LATCH EQU 6000H ; ADDRESS FOR LATCH

INITIAL: MOV R3,#00H ; FIRST CODE
MOV R4,#00H ; SECOND CODE
MOV R5,#00H ; THIRD CODE

MOV R6,#0FFH ; ENTER 0

MOV DPTR,#BUFFER ; TO READ THE BUFFER

READ_1: MOVX A,@DPTR ; READ THE DIP SWITCH
;MOV A,P0 ; SIMULATION ONLY FOR BUFFER

JB ACC.0,DISP_CODE ; DISPLAY CODE IS SWITCH '1' IS ON
SJMP READ_1 ; KEEPS DETECTING SWITCH '1'

READ_2: MOVX A,@DPTR ; READ THE DIP SWITCH
;MOV A,P0 ; SIMULATION ONLY FOR BUFFER

JB ACC.1,ENTER_CODE; ENTER CODE MODE
SJMP READ_2 ; KEEP READING SWITCH '2'

;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
; THIS IS THE SECTION FOR DISPLAY CODE
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;

DISP_CODE: MOV P1,#CODE_1
LCALL DELAY

MOV P1,#CODE_2
LCALL DELAY

MOV P1,#CODE_3
LCALL DELAY

MOV P1,#0FFH

SJMP READ_2

;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
; THIS IS THE SECTION FOR GET CODE
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;

ENTER_CODE: NOP
ENTER_1: MOV DPTR, #BUFFER ; TO READ THE BUFFER
MOVX A,@DPTR ; GET THE KEYPAD INPUT
;MOV A,P0 ; SIMULATION ONLY FOR BUFFER

JNB ACC.3, ENTER_1 ; KEEP READING UNTIL DV IS ON
LCALL DELAY
MOVX A,@DPTR ; IF DV IS ON, READ THE DATA AGAIN
;MOV A,P0 ; SIMULATION ONLY FOR BUFFER
LCALL SWAPPING ; BRING THE HIGHER-4 BIT DOWN

MOV DPTR,#TABLE ; TO GET THE DEFINED BYTES
MOVC A,@A+DPTR ; GET THE CORESPONDING HEXADECIMAL

MOV P1,A ; DISPLAY THE ENTERED NUMBER

MOV R3,A ; STORE THE NUMBER IN REGISTER

MOV DPTR,#LATCH ; TO DISPLAY AT LATCH
MOV A,#01H ; DISPLAY ONE LED
MOVX @DPTR,A ; DISPLAY ONE LED
;MOV P2,A ; SIMULATION ONLY FOR LATCH

ENTER_2: MOV DPTR, #BUFFER ; TO READ THE BUFFER
MOVX A,@DPTR ; GET THE KEYPAD INPUT
;MOV A,P0 ; SIMULATION ONLY FOR BUFFER

JNB ACC.3, ENTER_2 ; KEEP READING UNTIL DV IS ON
LCALL DELAY
MOVX A,@DPTR ; IF DV IS ON, READ THE DATA AGAIN
;MOV A,P0 ; SIMULATION ONLY FOR BUFFER
LCALL SWAPPING ; BRING THE HIGHER-4 BIT DOWN

MOV DPTR,#TABLE ; TO GET THE DEFINED BYTES
MOVC A,@A+DPTR ; GET THE CORESPONDING HEXADECIMAL

MOV P1,A ; DISPLAY THE ENTERED NUMBER

MOV R4,A ; STORE THE NUMBER IN REGISTER

MOV DPTR,#LATCH ; TO DISPLAY AT LATCH
MOV A,#03H ; DISPLAY TWO LED
MOVX @DPTR,A ; DISPLAY TWO LED
;MOV P2,A ; SIMULATION ONLY FOR LATCH

ENTER_3: MOV DPTR, #BUFFER ; TO READ THE BUFFER
MOVX A,@DPTR ; GET THE KEYPAD INPUT
;MOV A,P0 ; SIMULATION ONLY FOR BUFFER

JNB ACC.3, ENTER_3 ; KEEP READING UNTIL DV IS ON
LCALL DELAY
MOVX A,@DPTR ; IF DV IS ON, READ THE DATA AGAIN
;MOV A,P0 ; SIMULATION ONLY FOR BUFFER
LCALL SWAPPING ; BRING THE HIGHER-4 BIT DOWN

MOV DPTR,#TABLE ; TO GET THE DEFINED BYTES
MOVC A,@A+DPTR ; GET THE CORESPONDING HEXADECIMAL

MOV P1,A ; DISPLAY THE ENTERED NUMBER

MOV R5,A ; STORE THE NUMBER IN REGISTER

MOV DPTR,#LATCH ; TO DISPLAY AT LATCH
MOV A,#07H ; DISPLAY THREE LED
MOVX @DPTR,A ; DISPLAY THREE LED
;MOV P2,A ; SIMULATION ONLY FOR LATCH

ENTER_0: MOV DPTR, #BUFFER ; TO READ THE BUFFER
MOVX A,@DPTR ; GET THE KEYPAD INPUT
;MOV A,P0 ; SIMULATION ONLY FOR BUFFER

JNB ACC.3, ENTER_0 ; KEEP READING UNTIL DV IS ON
LCALL DELAY
MOVX A,@DPTR ; IF DV IS ON, READ THE DATA AGAIN
;MOV A,P0 ; SIMULATION ONLY FOR BUFFER
LCALL SWAPPING ; BRING THE HIGHER-4 BIT DOWN

CJNE A,#09H,ENTER_0
SJMP CHECK

;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
; THIS IS THE SECTION FOR CHECKING THE CODE
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;

CHECK: CLR A ; CLEAR A FOR CHECKING

CHECK_1: CJNE R3,#CODE_1,CHECK_2 ; IF CODE ENTERED IS CORRECT
SETB ACC.0 ; THEN SET BIT
SJMP CHECK_2 ; ELSE CHECK SECOND NUMBER

CHECK_2: CJNE R4,#CODE_2,CHECK_3 ; IF CODE ENTERED IS CORRECT
SETB ACC.1 ; THEN SET BIT
SJMP CHECK_3 ; ELSE CHECK THIRD NUMBER

CHECK_3: CJNE R5,#CODE_3,AND_GATE ; IF CODE ENTERED IS CORRECT
SETB ACC.2 ; THEN SET BIT
SJMP AND_GATE ; ELSE AND WITH 7

AND_GATE: ANL A,#00000111B ; ONLY CORRECT BITS WILL PRODUCE 7
CJNE A,#00000111B,HASH ; ONLY 7 IN A WILL MAKE LED BLINK
SJMP BLINK

;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
; THIS IS THE SECTION FOR SHOWING THE RESULT
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;

BLINK: MOV DPTR,#LATCH
MOV P1,#0FFH ; CLEAR THE PORT 1 OF ANY DIGIT
MOV R7,#05H ; BLINK 5 TIMES
ROTATE: MOV A,#0FFH ; LED HIGH
MOVX @DPTR,A ; SHOW AT LED
;MOV P2,A ; SIMULATION ONLY FOR LATCH
LCALL DELAY

MOV A,#00H ; LED LOW
MOVX @DPTR,A ; TURNS OFF LED
;MOV P2,A ; SIMULATION ONLY FOR LATCH
LCALL DELAY

DJNZ R7,ROTATE ; ROTATE UNTIL 5 TIMES IS OVER

ENDING: MOV A,#00H ; MAKE IT END HERE
MOVX @DPTR,A
;MOV P2,A ; SIMULATION ONLY FOR LATCH
SJMP ENDING


HASH: MOV DPTR,#LATCH
MOV A,#00H ; CLEAR THE LED OF ANY LIGHTS
MOVX @DPTR,A
MOV P2,A

ENDING_2: MOV P1,#089H ; DISPLAY THE WORD 'H'
LCALL DELAY
MOV P1,#0FFH ; DISPLAY NOTHING
LCALL DELAY
SJMP ENDING_2 ; KEEPS LOOPING



;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
; THIS IS THE SECTION FOR SUBROUTINES
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;

SWAPPING: SWAP A
ANL A,#0FH
RET

DELAY: MOV R0,#05 ; 0FFH FOR SIMULATION 5 FOR REAL
MOV R1,#0150 ; 0FFH FOR SIMULATION 150 FOR REAL
MOV R2,#05 ; 0FFH FOR SIMULATION 5 FOR REAL
L1: DJNZ R0,L1 ; DJNZ-DEC AND JUMP TO 'L1 IF 'R0' IS NOT ZERO
DJNZ R1,L1 ; DJNZ-DEC AND JUMP TO 'L1 IF 'R1' IS NOT ZERO
DJNZ R2,L1 ; DJNZ-DEC AND JUMP TO 'L1 IF 'R2' IS NOT ZERO
RET ;

TABLE: DB 0F9H,0A4H,0B0H,8EH,99H,92H,82H,86H,0F8H,80H,98H,0C0H,88H,0C0H,80H,0C6H

END

;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
; THIS IS THE END OF THE PROGRAM
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
How amazing it is to know different kind of 'language'
And copyright NG KHIN HOOI.