i am doing a clock that is operated using a 80x86 MP. it has a setting function, mine is a complete mess, please help

SET: ;START OF SET
MOV AH,00H
INT 16H
CMP AL,'6' ;6 WITH QUOTES OR WITHOUT? - CHECK IF THE NUMBER IS GREATER THAN OR EQUAL 6
JAE SET

SET: ;START OF SET
MOV AH,00H
INT 16H
CMP AL,'6' ;6 WITH QUOTES OR WITHOUT? - CHECK IF THE NUMBER IS GREATER THAN OR EQUAL 6
JAE SET

SHL Ax, 1 ;Multiply AL by two ;alot faster than mul
MOV bx, Ax ;Save 2*AL for later
shl Ax, 1 ;Multiply AL by four
shl Ax, 1 ;Multiply AL by eight

MOV BL,AL

MOV AH,00H
INT 16H

in this part i am trying to save the minutes, but i guess there is an issue with usig ascii

• : i am doing a clock that is operated using a 80x86 MP. it has a
:
: SET: ;START OF SET
: MOV AH,00H
: INT 16H
: CMP AL,'6' ;6 WITH QUOTES OR WITHOUT? - CHECK IF
: THE NUMBER IS GREATER THAN OR EQUAL 6
: JAE SET
:
:
:
: SET: ;START OF SET
: MOV AH,00H
: INT 16H
: CMP AL,'6' ;6 WITH QUOTES OR WITHOUT? - CHECK IF
: THE NUMBER IS GREATER THAN OR EQUAL 6
: JAE SET
: [color=Red]In this ^^^ case WITH quotes, because[/color]
: [color=Red]INT 16h Function 00h will input ASCII symbol[/color]
:
: SHL Ax, 1 ;Multiply AL by two ;alot faster
: than mul
: MOV bx, Ax ;Save 2*AL for later
: shl Ax, 1 ;Multiply AL by four
: shl Ax, 1 ;Multiply AL by eight
:
:
: MOV BL,AL
:
: MOV AH,00H
: INT 16H
:
: in this part i am trying to save the minutes, but i guess there is
: an issue with using ascii
:
[color=Blue]To convert ASCII digit into binary digit is simple - just add/subtract the value of zero character '0' and it is done:
[/color]
[code]
MOV AL, '7'
SUB AL, '0' ; Now AL contains binary value of 7

MOV AL, 3
ADD AL, '0' ; Now AL contains ASCII symbol '3'
[/code]
{"ft_lang_label":"__label__en","ft_lang_prob":0.76544744,"math_prob":0.873945,"size":1811,"snap":"2021-43-2021-49","text_gpt3_token_len":634,"char_repetition_ratio":0.10293304,"word_repetition_ratio":0.49739584,"special_character_ratio":0.33793485,"punctuation_ratio":0.2184874,"nsfw_num_words":0,"has_unicode_error":false,"math_prob_llama3":0.973263,"pos_list":[0],"im_url_duplicate_count":[null],"WARC_HEADER":"{\"WARC-Type\":\"response\",\"WARC-Date\":\"2021-10-16T02:31:15Z\",\"WARC-Record-ID\":\"<urn:uuid:b940e053-6f22-4555-bd0c-c6196eb7aa7f>\",\"Content-Length\":\"57951\",\"Content-Type\":\"application/http; msgtype=response\",\"WARC-Warcinfo-ID\":\"<urn:uuid:d7ce4b59-2445-4b3a-852a-0838fe168937>\",\"WARC-Concurrent-To\":\"<urn:uuid:5386384d-6bdc-4b9b-99b8-46177e13de10>\",\"WARC-IP-Address\":\"100.26.66.101\",\"WARC-Target-URI\":\"https://programmersheaven.com/discussion/369153/problem-with-numbers-please-help\",\"WARC-Payload-Digest\":\"sha1:VBNENGZYGGHH4JB26NRN2HURH76BRP2B\",\"WARC-Block-Digest\":\"sha1:TOKYKEYZJSXRNR2FCG4F6OLZTZ2M2VO6\",\"WARC-Identified-Payload-Type\":\"text/html\",\"warc_filename\":\"/cc_download/warc_2021/CC-MAIN-2021-43/CC-MAIN-2021-43_segments_1634323583408.93_warc_CC-MAIN-20211016013436-20211016043436-00523.warc.gz\"}"}