Wang Shuang << assembly language >> Experiment 14

Source: Internet
Author: User

1 ;in "Year/month/day: minutes: Seconds" format, display the current date, time2AssumeCS:Code3 Code Segment4 Main:5         movAl96          out70h,al;tells the CMOS RAM which memory unit number to access7         inchal,71h;read data from this storage unit8         9         movAh,alTen         movCl4 One         SHRAL,CL A         Addal,30h;10-bit ASCII code for the displayed year -          andAh00001111b -         Addah,30h;ASCII code for the digit of the year displayed the          -         movbx,0b800h -         movES,BX -         movbyte ptres:[ the* A+ -*2],al +         movbyte ptres:[ the* A+ to*2],ah;Show Year -          +         movbyte ptres:[ the* A+ +*2],'/' ;Show '/' A          at         movAl8 -          out70h,al;tells the CMOS RAM which memory unit number to access -         inchal,71h;read data from this storage unit -          -         movAh,al -         movCl4 in         SHRAL,CL -         Addal,30h;10-bit ASCII code for the displayed year to          andAh00001111b +         Addah,30h;ASCII code for the digit of the year displayed -          the         movbyte ptres:[ the* A+ -*2],al *         movbyte ptres:[ the* A+ the*2],ah;Show Month $         Panax Notoginseng         movbyte ptres:[ the* A+ **2],'/' ;Show '/' -          the         movAl7 +          out70h,al;tells the CMOS RAM which memory unit number to access A         inchal,71h;read data from this storage unit the          +         movAh,al -         movCl4 $         SHRAL,CL $         Addal,30h;10-bit ASCII code for the displayed year -          andAh00001111b -         Addah,30h;ASCII code for the digit of the year displayed the          -         movbyte ptres:[ the* A+ $*2],alWuyi         movbyte ptres:[ the* A+Panax Notoginseng*2],ah;Display Day the          -         movbyte ptres:[ the* A+ -*2],' ' ;display "' Wu          -         movAl4 About          out70h,al;tells the CMOS RAM which memory unit number to access $         inchal,71h;read data from this storage unit -          -         movAh,al -         movCl4 A         SHRAL,CL +         Addal,30h;10-bit ASCII code for the displayed year the          andChn00001111b -         Addah,30h;ASCII code for the digit of the year displayed $          the         movbyte ptres:[ the* A+ the*2],al the         movbyte ptres:[ the* A+ +*2],ah;when displayed the          the         movbyte ptres:[ the* A+ A*2],':' ;Show ': ' -          in         movAl2 the          out70h,al;tells the CMOS RAM which memory unit number to access the         inchal,71h;read data from this storage unit About          the         movAh,al the         movCl4 the         SHRAL,CL +         Addal,30h;10-bit ASCII code for the displayed year -          andAh00001111b the         Addah,30h;ASCII code for the digit of the year displayedBayi          the         movbyte ptres:[ the* A+ the*2],al the         movbyte ptres:[ the* A+ +*2],ah;Display points -          -         movbyte ptres:[ the* A+ -*2],':' ;Show ': ' the          the         movAl0 the          out70h,al;tells the CMOS RAM which memory unit number to access the         inchal,71h;read data from this storage unit -          the         movAh,al the         movCl4 the         SHRAL,CL94         Addal,30h;10-bit ASCII code for the displayed year the          andChn00001111b the         Addah,30h;ASCII code for the digit of the year displayed the         98         movbyte ptres:[ the* A+ $*2],al About         movbyte ptres:[ the* A+ $*2],ah;Show Seconds -              101         102         movax,4c00h103         int21h104 code ends theEnd Main

Wang Shuang << assembly language >> Experiment 14

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.