My Profile
Active Members
TodayLast 7 Days
more...
Awards & Gifts
Online Exams
Fresher Jobs
Our fresher job section is exclusively for fresh graduates! Find jobs for freshers in major Indian
cities including Bangalore, Chennai, Hyderabad, Pune or Kochi
Resources
Find educational articles, blogs, discussion threads and other resources.
Colleges
Find details about any college in India or search for courses.
|
Hardware Interaction Through C-Display text using Bios routines
Posted Date: 14 Jun 2008 Resource Type: Articles/Knowledge Sharing Category: Computer & Technology
|
Posted By: Lenin Member Level: Diamond Rating: Points: 1
|
Display text using Bios routines
#include #include #include void main() { union REGS in,out,ins,oust; int i,j,row=0,col=0,colaux; char sentence[80]; clrscr(); gotoxy(1,1); printf("ENTER A STATEMENT : "); gets(sentence); clrscr(); in.h.ah=0x00;in.h.al=0x12;int86(0x10,&in,&out); in.h.ah=0x0F; int86(0x10,&in,&out); printf("
Video Mode = %u",out.h.al); printf(" Number Of Chararowers Column On Screen = %u",out.h.ah); printf(" Page Number = %u
",out.h.bh); gotoxy(1,1); printf("%s",sentence); in.h.ah=0x0D; in.h.bh=0; ins.h.ah=0x0C;ins.h.bh=0; for(i=0;i<15;i++) { row=0;col=0; for(j=0;j<640;j++) { in.x.dx=i; in.x.cx=j; ins.h.al=i+1; colaux=col*3; //adjusting text width if(colaux%640==0) { row+=55; col=0; } ins.x.cx=colaux; ins.x.dx=i*3+150+row; //adjusting text height;'150':-point where text starts
int86(0x10,&in,&out); if(out.h.al!=0) int86(0x10,&ins,&oust); //printf("%u,",out.h.al); col++; } } getch(); in.h.ah=0x00;in.h.al=3;int86(0x10,&in,&out); }
|
Responses
|
No responses found. Be the first to respond and make money from revenue sharing program.
|
|
Watch TV Channels
|