Skip to content

CS609 - System Programming

19 Topics 76 Posts
  • 0 Votes
    3 Posts
    603 Views
    wajiha AsifW
    Solution://Header Files #include<stdio.H> #include<DOS.H> #include<BIOS.H> void interrupt (*oldint65)(); //To store current interrupt char far *scr=(char far* ) 0xb8000000; void interrupt newint65();//NewInt prototype void main() { oldint65 = getvect(0x65); setvect(0x65, newint65); getch(); keep(0, 1000); } void interrupt newint65() {clrscr(); *scr=8; (*scr)=0x174D; (*(scr+2))=0x1743; (*(scr+4))=0x1731; (*(scr+6))=0x1739; (*(scr+8))=0x1730; (*(scr+10))=0x1734; (*(scr+12))=0x1730; (*(scr+14))=0x1736; (*(scr+16))=0x1734; (*(scr+18))=0x1730; (*(scr+20))=0x1734; }

    429e7ece-92cc-4cef-a09c-e90f8b391518-image.png
    3e679fbc-5b4c-4ac1-a4c8-107d83737325-image.png

  • 0 Votes
    2 Posts
    590 Views
    Ganza NadiG

  • 0 Votes
    2 Posts
    216 Views
    M

    Please discuss idea solution

  • 0 Votes
    4 Posts
    130 Views
    zareenZ

    Defragmentation is the process of locating the noncontiguous fragments of data and rearranging the fragments and restoring them into fewer fragments or into the whole file.
    In terms of computer performance File fragmentation directly affects the access and write speed of that hard disk. All computers suffer from fragmentation. We use defragmentation to resolve this issue.Performance of system degraded during defragmentation but improve after it’s completion as compared to previous

  • 0 Votes
    3 Posts
    146 Views
    zareenZ

    Solution:

    // Header Files #include<stdio.h> #include<conio.h> #include<BIOS.H> #inlcude<DOS.H> void interrupt (*oldTimer)(*void); // To store current Timer vector void interrupt newTimer(); //New Timer Function char far *scr= (char far *)0xB8000000; //Screen segment int in, t=0; void main() { clrscr(); oldTimer=getvect(8); setvect(8,newTimer); getch(); } void interrupt newTimer(); { *(scr+t)=0x2A; t++; if(t>=126) { for(i=0;i<4000;i+=2) { *(scr+i)=0x20; // Blank screen *(scr+i+1)=0x07; } t=0; } (*oldTimer)(); } }
  • 0 Votes
    2 Posts
    263 Views
    zaasmiZ
    #include <dos.h> #include <conio.h> char st [80]; int SendKbdRate(unsigned char data , int maxtry) { unsigned char ch; do { do { ch=inport(0x64); }while (ch&0x02); outport(0x60,data); do { ch = inport(0x64); }while (ch&0x01); if (ch==0xfa) { puts("success\n"); break; } maxtry = maxtry - 1; } while (maxtry != 0); if (maxtry==0) return 1; else } return 0; void main () { //clrscr(); SendKbdRate(0xf3,3); SendKbdRate(0x68,3); gets(st); }
  • 0 Votes
    4 Posts
    207 Views
    zaasmiZ

    CS609 Assignment 1 Solution Idea!..

    #include<BIOS.H> #include<DOS.H> char st1[80] ={"Virtual University of Pakistan$"}; char st2[80] ={"Washi Ali$"}; char st2[80] ={"Tufail$"}; void interrupt (*oldint65)( ); void interrupt newint65( ); void main() { oldint65 = getvect(0x65); setvect(0x65, newint65); keep(0, 1000); } void interrupt newint65( ) { switch (_AH) { case 0: _AH = 0x09; _DX = (unsigned int) st1; geninterrupt (0x21); break; case 1: _AH = 0x09; _DX = (unsigned int) st2; geninterrupt (0x21); break; case 2: _AH = 0x09; _DX = (unsigned int) st3; geninterrupt (0x21); break; } } }```
  • 1 Votes
    16 Posts
    3k Views
    mehwishM

    @zareen said in CS609 Quiz No.2 Solution and Discussion:

    What are the 3 types of viruses?

    Resident Virus. Resident viruses live in your RAM memory. …

    Multipartite Virus. …

    Direct Action Virus. …

    Browser Hijacker. …

    Overwrite Virus. …

    Web Scripting Virus. …

    Boot Sector Virus. …

    Macro Virus.

  • 0 Votes
    3 Posts
    5k Views
    zareenZ

    Question : 1 of 10 ( Marks: 1 ) - Please choose one
    14h include __________ which is used to send a byte.
    ►Service #0
    ►Service #1 (Page 121)
    ►Service #2
    ►Service #3
    Question : 2 of 10 ( Marks: 1 ) - Please choose one
    The status register _____ is the main control register.
    ►B (Page 146)
    ►A
    ►C
    ►D
    Question : 3 of 10 ( Marks: 1 ) - Please choose one
    _________ is used to identify the cause of interrupt.
    ►Interrupt ID Register (Page 116)
    ►PC Register
    ►AC Register
    ►None of All These
    25
    Question : 4 of 10 ( Marks: 1 ) - Please choose one
    In NTFS, up to ________ characters are used to store files names,
    ►30
    ►48
    ►255 (Page 283)
    ►510
    Question : 5 of 10 ( Marks: 1 ) - Please choose one
    A cluster is a collection of contiguous _______.
    ►Blocks (Page 242)
    ►Sectors
    ►Bytes
    ►None of Given
    Question : 6 of 10 ( Marks: 1 ) - Please choose one
    In BPB, root directory is saved in _________.
    ►Cluster#0
    ►Cluster#1
    ►Cluster#2
    ►Cluster#3
    Question : 7 of 10 ( Marks: 1 ) - Please choose one
    In NTFS, total sizes of MFT entries are _______.
    ►16-bytes (Page 303)
    ►20-bytes
    ►26-bytes
    ►32-bytes
    Question : 8 of 10 ( Marks: 1 ) - Please choose one
    In NTFS, _______ store the contents of file.
    ►Both small & large file Record
    ►Small record
    ►Large Record
    ►None of given

    26
    Question : 9 of 10 ( Marks: 1 ) - Please choose one
    In NTFS, contents and indexed of file is stored in _____.
    ►Small record
    ►Large Record
    ►Both small & large file Record
    ►None of given
    Question : 10 of 10 ( Marks: 1 ) - Please choose one
    Total No. of bytes that can be stored in Keyboard Buffer is
    .
    ►16
    ►32 (Page 54)
    ►64
    ►128
    Question : 1 of 10 ( Marks: 1 ) - Please choose one
    BIOS support _____________UARTS as COM ports.
    ►6
    ►4 (Page 113)
    ►3
    ►2
    Question : 2 of 10 ( Marks: 1 ) - Please choose one
    DCE stands for __________.
    ►Data communication equipment (Page 109)
    ►Distributed Computing Environment
    ►Data Communications Equipment
    ►Data Carrier Equipment
    Question : 3 of 10 ( Marks: 1 ) - Please choose one
    In counter register bit no. 3 changes its value between 0 and 1 with in ____clock cycles
    ►1
    ►2
    ►4
    ► 16 (Page 69)

    27
    Question : 4 of 10 ( Marks: 1 ) - Please choose one
    In ____________each byte is needed to be encapsulated in start and end.
    ►Synchronous communication
    ►Asynchronous communication (Page 106)
    ►Both
    ►None of given
    Question : 5 of 10 ( Marks: 1 ) - Please choose one
    The ______ service # is not used in any interrupt.
    ►01
    ►02
    ►03
    ►FF
    Question : 6 of 10 ( Marks: 1 ) - Please choose one
    If we want to send printing on the printer then we have to perform following steps.
    ►Initialize printer
    ►Read Status
    ►Check Error
    ►All of the given
    Question : 7 of 10 ( Marks: 1 ) - Please choose one
    DTE is ____________.
    ►Data terminal equipment (Page 109)
    ►Data transmitting equipment
    ►Dual terminal equipment
    ►None of the given.
    Question : 8 of 10 ( Marks: 1 ) - Please choose one
    If printer is _____ then printer sends back the ACK signal to the printer interface
    ►idle (Page 97)
    ►busy
    ►Out of paper
    ►None of the given

    28
    Question : 9 of 10 ( Marks: 1 ) - Please choose one
    DSR stands for __________ .
    ►Data set ready (Page 111)
    ►Data service ready
    ►Data stock ready
    ►None of the given
    Question : 10 of 10 ( Marks: 1 ) - Please choose one
    At IRQ 7 Interrupt # ___ is used.
    ► 0x0A
    ►0x0B
    ► 0x0C
    ►0x0F (Page 95)
    Question : 1 of 10 ( Marks: 1 ) - Please choose one
    The memory addresses of COM ports remain same for all computers
    ►True
    ►False
    Question : 2 of 10 ( Marks: 1 ) - Please choose one
    In keyboard status byte bit no. 2 and 3 are used for ctrl and alt keys respectively. which of the following
    condition is used to check that Ctrl + Alt keys are pressed. Where: unsigned char far * scr = (unsigned char far
    *)(0x00400017);
    ►if (((*scr)&12)==12)
    ►if (((*scr)&8)==8)
    ►if (((*scr)&4)==4)
    ►if (((*scr)&2)==2)

    Question : 3 of 10 ( Marks: 1 ) - Please choose one
    In case of synchronous communication a timing signal is required to identify the start and end of a bit.
    ►True (Page 105)
    ►False
    Question : 4 of 10 ( Marks: 1 ) - Please choose one
    The baud rate is set in accordance with the divisor value loaded within the UART internal registers base +0 and
    base +1.
    ►TRUE (Page 114)
    ►FALSE
    29
    Question : 5 of 10 ( Marks: 1 ) - Please choose one
    Software based flow control make use of -------- control characters
    ►Xon
    ►XOFF
    ►Both (Page 135)
    ►None
    Question : 6 of 10 ( Marks: 1 ) - Please choose one
    ------------ is used to read time from RTC
    ►1A\02H (Page 137)
    ►1A\03H
    ►1A\04H
    ►1A\05H

    Question : 7 of 10 ( Marks: 1 ) - Please choose one
    Int_____________ service 0 can be used to set the line parameter of the UART or COM port.
    ►14H (Page 119)
    ►15H
    ►13H
    ►None of the given option
    Question : 8 of 10 ( Marks: 1 ) - Please choose one
    When LBA is equal to zero (0), it means ________.
    ►First block of the disk (Page 240)
    ►First block of the logical drive
    ►First block of the hidden block
    ►None of the given
    Question : 9 of 10 ( Marks: 1 ) - Please choose one
    In IRQ2 and IRQ3 which one has the highest priority?
    ►Can’t be determined
    ►Both have same priority
    ►IRQ3
    ►IRQ2 (Page 47)

    30
    Question : 10 of 10 ( Marks: 1 ) - Please choose one
    Following is not a method of I/O
    ►Programmed I/O
    ► Interrupt driven I/O
    ►Hardware Based I/O (Page 4)
    ►None of given
    Question : 1 of 10 ( Marks: 1 ) - Please choose one
    It is possible to perform I/O operations from three different methods.
    ►True (Page 7)
    ►False
    Question : 2 of 10 ( Marks: 1 ) - Please choose one
    The Function of I/O controller is to provide ____________.
    ►I/O control signals
    ►Buffering
    ►Error Correction and Detection
    ►All of given (Page 5)
    Question : 3 of 10 ( Marks: 1 ) - Please choose one
    Which of the following are types of ISR __________.
    ►BIOS (Basic I/O service ) ISR
    ►DOS ISR
    ►ISR provided by third party device drivers
    ►All of the given (Page 13)
    Question : 4 of 10 ( Marks: 1 ) - Please choose one
    Interrupt service number is usually placed in ____________ register.
    ►CH
    ►CL
    ►AH (Page 26)
    ►AL

    31
    Question : 5 of 10 ( Marks: 1 ) - Please choose one
    NMI Stand for
    ►Non Maskable Interrupt (Page 46)
    ►Non Multitude Interrupt
    ►Non Maskable Instruction
    ►None of Given
    Question : 6 of 10 ( Marks: 1 ) - Please choose one
    A single interrupt controller can arbitrate among ____ different devices.
    ►4
    ► 6
    ►8 (Page 47)
    ►10
    Question : 7 of 10 ( Marks: 1 ) - Please choose one
    The microprocessor package has many signals for data. Below are some incorrect priority order (Higher to
    Lower).
    ►Reset,Hold,NMI,INTR (Page 46)
    ►NMI, INTR,Hold,Reset
    ►INTR,NMI,Reset,Hold
    ►None of the Given
    Question : 8 of 10 ( Marks: 1 ) - Please choose one
    The following command “outportb (0x61,inportb(0x61) & 0xFC);” will
    ►Turn on the speaker
    ►Turn off the speaker (Page 75)
    ►Toggle the speaker
    ►None of the given
    Question : 9 of 10 ( Marks: 1 ) - Please choose one
    The following command “outportb (0x61,inportb(0x61) | 3);” will ________ .
    ►Turn on the speaker (Page 74)
    ►Turn off the speaker
    ►Toggle the speaker
    ►None of the above
    32
    Question : 10 of 10 ( Marks: 1 ) - Please choose one
    The PPI acts as an interface between the CPU and a parallel ________ .
    ►I/O device (Page 83)
    ►CPU
    ►BUS
    ►None of Given
    Question : 1 of 10 ( Marks: 1 ) - Please choose one
    BIOS DO NOT support ______.
    ►LPT1
    ►LPT2
    ►LPT3
    ►LPT4 (Page 91)
    Question : 2 of 10 ( Marks: 1 ) - Please choose one
    _____ bit is cleared to indicate the low nibble is being sent.
    ►D1
    ►D2
    ►D3
    ►D4 (Page 104)
    Question : 3 of 10 ( Marks: 1 ) - Please choose one
    The bit ______ of Line control register in UART, if cleared will indicate that DLL is the data register.
    ►1
    ►3
    ►5
    ►7 (Page 114)
    Question : 4 of 10 ( Marks: 1 ) - Please choose one
    ___________ file system is used in NTFS based systems.
    Contiguous Chained
    Indexed
    None of the given

    33
    Question : 5 of 10 ( Marks: 1 ) - Please choose one
    Communication between keyboard and keyboard controller is __________.
    ►Asynchronous serial
    ►Synchronous serial (P 77)
    ►Parallel communication
    ►None of the given
    Question : 6 of 10 ( Marks: 1 ) - Please choose one
    In NTFS, boot sector is stored at
    ►First and 6th sector
    ►First and Last sector
    ►Only at Last sector
    ►Only at First sector
    Question : 7 of 10 ( Marks: 1 ) - Please choose one
    Standard PC operates in two modes in terms of memory which are
    ►Real mode and Extended Mode
    ►Base mode and Memory Mode
    ►None of the given
    ►Real mode and protected mode (Page 6)
    Question : 8 of 10 ( Marks: 1 ) - Please choose one
    IVT is a table containing ______ byte entries each of which is a far address of an interrupt service routine.
    ►2
    ►4 (Page 20)
    ►8
    ►16
    Question : 9 of 10 ( Marks: 1 ) - Please choose one
    Each paragraph in keep function is ____ bytes in size.
    ►4
    ►8
    ►16 (Page 24)
    ►32

    34
    Question : 10 of 10 ( Marks: 1 ) - Please choose one
    A software interrupt does not require EOI (End of interrupt).
    ►True (Page 49)
    ►False
    Question : 1 of 10 ( Marks: 1 ) - Please choose one
    To store each character in keyboard buffer ____ bytes are required.
    ►2 (Page 54)
    ►4
    ►6
    ►8
    Question : 2 of 10 ( Marks: 1 ) - Please choose one
    Interrupt _____ is empty; we can use its vector as a flag.
    ►9H
    ►13H
    ►15H
    ►65H (Page 65)
    Question : 3 of 10 ( Marks: 1 ) - Please choose one
    Command register is an _____ bit register
    ►4
    ►8 (Page 71)
    ►16
    ►32
    Question : 4 of 10 ( Marks: 1 ) - Please choose one
    How many bytes can be used to store a file name in NTFS?
    ►128
    ►255
    ►510
    ►1024
    Question : 5 of 10 ( Marks: 1 ) - Please choose one
    ____ is the first logical sector of NTFS partition.
    ►DPB
    ►MFT
    ►Boot sector
    ►None
    35
    Question : 6 of 10 ( Marks: 1 ) - Please choose one
    In boot block BIOS parameter block starts from 03H
    ►05H
    ►08H
    ►0BH (Page 302)
    Question : 7 of 10 ( Marks: 1 ) - Please choose one
    IN NTFS, FAT and root directory is replaced by
    ►FCB
    ►MFT (Page 301)
    ►Hidden blocks
    ►Boot sector
    Question : 8 of 10 ( Marks: 1 ) - Please choose one
    Block # 2 is the safest block to store the backup of boot block.
    ►True
    ►False
    Question : 2 of 10 ( Marks: 1 ) - Please choose one
    The keyboards interface as discussed earlier uses the IRQ0 and the port 64H as data port.
    ►True
    ► False
    Question : 3 of 10 ( Marks: 1 ) - Please choose one
    FAT12 will have 12-bit wide entries and can have 2^12=4096 entries maximum
    ►True
    ► False
    Question : 4 of 10 ( Marks: 1 ) - Please choose one
    In order to produce the sound from PC internal Speaker we have to load the___bit divisor value at the ___port.
    ►8, 0x21
    ►16, 0x42
    ►32, 0x22
    ►64, 0x32

    36
    Some More MCQs and Quizzes
    Question : 1 of 10 ( Marks: 1 ) - Please choose one
    DMA stands for_________
    ►Direct Memory Access (Page 4)
    ►Distinct Memory Access
    ►Direct Module Access
    ►Direct Memory Allocation
    Question : 2 of 10 ( Marks: 1 ) - Please choose one
    UART stands for_______
    ►Universal Asynchronous Receiver Transmitter (Page 107)
    ►Universal Adjustment and Realigning Tool
    ►Unconventional Assisted Recovery Team
    ►None of these
    Question : 3 of 10 ( Marks: 1 ) - Please choose one
    Interrupt Vector Table (IVT) in short is a _______ bytes sized table.
    ►1024 (Page 10)
    ►2048
    ►3072
    ►4096
    Question : 4 of 10 ( Marks: 1 ) - Please choose one
    Hardware Interrupts are __________.
    ►Preemptive
    ►Non-Preemptive (Page 48)
    ►Both Preemptive and Non-Preemptive
    ►None of Given
    Question : 5 of 10 ( Marks: 1 ) - Please choose one
    Timer interrupt is a ___.
    ►Hardware Interrupt (Page 28)
    ►Software Interrupt
    ►Both of these
    ►None of These
    37
    Question : 6 of 10 ( Marks: 1 ) - Please choose one
    The keyboard makes use of interrupt number _______ for its input operations.
    ►9 (Page 34)
    ►10
    ►11
    ►12
    Question : 7 of 10 ( Marks: 1 ) - Please choose one
    Register can be used to divide frequency is _________
    ►Counter Register (Page 69)
    ►Accumulator Register
    ►None of these
    Question : 8 of 10 ( Marks: 1 ) - Please choose one
    Which port is known as Data Port

    ►60H (Page 177)
    ►61H
    ►64H
    ►69H
    Question : 9 of 10 ( Marks: 1 ) - Please choose one
    LPTs can be swapped.
    ►True (Page 92)
    ►False
    Question : 10 of 10 ( Marks: 1 ) - Please choose one
    PPI is used to perform parallel communication
    ►True (Page 81)
    ►False
    Question : 1 of 10 ( Marks: 1 ) - Please choose one
    __________is used to control the printer via the BIOS
    ►Int 16H
    ►Int 17H (Page 84)
    ►Int 18H
    ►Int 19H

    38
    Question : 2 of 10 ( Marks: 1 ) - Please choose one
    There are two main types of interrupts namely _________________.
    ►PC based and Window based
    ►Hardware based and Kernal based
    ►Hardware interrupts and Software interrupts (Page 10)
    ►None of the given
    Question : 3 of 10 ( Marks: 1 ) - Please choose one
    To set the interrupt vector means is to change the double word sized interrupt vector within the IVT.
    ►True (Page 22)
    ►False
    Question : 4 of 10 ( Marks: 1 ) - Please choose one
    The service number is usually placed in the ________ register.
    ►AL
    ►CL
    ►AH (Page 26)
    ►AX
    Question : 5 of 10 ( Marks: 1 ) - Please choose one
    The keyboard makes use of interrupt number _______ for its input operations.
    ► 9 (Page 34)
    ►10
    ►11
    ►12
    Question : 6 of 10 ( Marks: 1 ) - Please choose one
    The service _________ is called the keyboard hook service.
    ►15H/2FH
    ►15H/4FH (Page 44)
    ►15H/FFH

    Question : 7 of 10 ( Marks: 1 ) - Please choose one
    The BIOS interrupt ________ can be used to configure RTC.
    ►1AH (Page 136)
    ►2AH
    ►3AH
    ►4AH
    39
    Question : 8 of 10 ( Marks: 1 ) - Please choose one
    PPI stands for
    ►Parallel Programmable interface
    ►Peripheral Programmable interface (Page 76)
    ►Port Programmable interface
    ►None of the given
    Question : 9 of 10 ( Marks: 1 ) - Please choose one
    Int ________ is used to control the printer via the BIOS.
    ►17H (Page 84)
    ►18H
    ►20H
    ►21H
    Question : 10 of 10 ( Marks: 1 ) - Please choose one
    Counter register can be used to divide clock signal.
    ►True (Page 69)
    ►False

    Question : 1 of 10 ( Marks: 1 ) - Please choose one
    The bit number _______ of the coprocessor control word is the interrupt enable flag.
    ►7 (Page 168)
    ►8
    ►9
    ►6
    Question : 2 of 10 ( Marks: 1 ) - Please choose one
    There are __________ kinds of serial communication.
    ►2 (Page 105)
    ►3
    ►4
    ►5
    Question : 3 of 10 ( Marks: 1 ) - Please choose one
    ________ store the base address for LPT1.
    ►40:00H
    ►40:02H
    ►40:08H (Page 92)
    ►40:1AH

    40
    Question : 4 of 10 ( Marks: 1 ) - Please choose one
    The amount of memory above conventional memory (extended memory) can be determined using the service
    _______.
    ►15H/88H (Page 162)
    ►16H/88H
    ►17H/88H
    ►21H/88H
    Question : 5 of 10 ( Marks: 1 ) - Please choose one
    The output on the monitor is controlled by a controller called __________within the PC.
    ►Video controller (Page 30)
    ►Bus controller
    ►Ram controller
    ►None of the given
    Question : 6 of 10 ( Marks: 1 ) - Please choose one
    Interrupt 9 usually reads the _________ from keyboard.
    ►ASCII code
    ►Scan code (Page 34)
    ►Both ASCII and Scan code
    ►None of the above
    Question : 7 of 10 ( Marks: 1 ) - Please choose one
    NMI Stand for
    ►Non Maskable Interrupt (Page 46)
    ►Non Multitude Interrupt
    ►Non Maskable Instruction
    ►None of Given
    Question : 8 of 10 ( Marks: 1 ) - Please choose one
    A single interrupt controller can arbitrate among ____ different devices.
    ►4
    ►6
    ►8 (Page 47)
    ►10

    41
    Question : 9 of 10 ( Marks: 1 ) - Please choose one
    The microprocessor package has many signals for data. Below are some in Correct priority order (Higher to
    Lower).
    ►Reset,Hold,NMI,INTR (Page 46)
    ►NMI, INTR,Hold,Reset
    ►INTR,NMI,Reset,Hold
    ►None of the Given
    Question : 10 of 10 ( Marks: 1 ) - Please choose one
    The ________function initialize the COM port whose number is passed as parameter using BIOS services.
    ►Initializecom()
    ►Initialize() (Page 125)
    ►Recievechar()
    ►None of these option
    Question : 1 of 10 ( Marks: 1 ) - Please choose one
    There are two type of communication synchronous and Anti Synchronous
    ►True
    ►False (Page 105)
    Question : 2 of 10 ( Marks: 1 ) - Please choose one
    REGS is a Union
    ►True
    ►False
    Question : 3 of 10 ( Marks: 1 ) - Please choose one
    Keyboard Status Byte is located at the address
    ► 0040:0000H
    ► 0040:0013H
    ► 0040:0015H
    ► 0040:0017H (Page 29)
    Question : 4 of 10 ( Marks: 1 ) - Please choose one
    If we use keep (0, 1000) in a TSR program, the memory allocated to it is
    ► 64000 bytes
    ► 32000 bytes
    ► 16000 bytes
    ► 80000 bytes
    42
    Question : 5 of 10 ( Marks: 1 ) - Please choose one
    Maximum number of interrupts in a standard PC is
    ► 64
    ► 128
    ► 256 (Page 10)
    ► 512
    Question : 6 of 10 ( Marks: 1 ) - Please choose one
    The -------- function receive a byte and COM port number is passed as parameter using BIOS service
    ►Receivebyte ();
    ►Receive ();
    ►Receivechar (); (Page 125)
    ►None of the given option
    Question : 7 of 10 ( Marks: 1 ) - Please choose one
    ------------ whenever receive indicates the start of communication ………… whenever receive indicates the end
    of communication
    ►XON\XOFF (Page 135)
    ►XOFF\XON
    ►XON\YOFF
    ►YON\XOFF
    Question : 8 of 10 ( Marks: 1 ) - Please choose one
    ------------ is used to set time from RTC
    ►1A\02H
    ►1A\03H (Page 138)
    ►1A\04H
    ►1A\05H

    Question : 9 of 10 ( Marks: 1 ) - Please choose one
    Set the Interrupt vector means to change the double word sized interrupt vector within IVT.
    ►True (Page 22)
    ►False
    Question : 10 of 10 ( Marks: 1 ) - Please choose one
    If keyboard buffer is empty the head and tail points at the same location.
    ►True (Page 55)
    ►False
    43
    Question : 1 of 10 ( Marks: 1 ) - Please choose one
    Standard PC can have _____ PPI.
    ►1
    ►4 (Page 84)
    ►8
    ►16
    Question : 2 of 10 ( Marks: 1 ) - Please choose one
    By cascading two DMAs ____ bits can be transferred.
    ►4
    ►8
    ►16 (Page 186)
    ►32
    Question : 3 of 10 ( Marks: 1 ) - Please choose one
    PPI interconnection _______ bits is cleared to indicate low nibble is being sent.
    ►D1
    ►D2
    ► D3
    ► D4 (Page 101)
    Question : 4 of 10 ( Marks: 1 ) - Please choose one
    Display device (Monitor) performs _________ I/O.
    ►memory mapped (Page 30)
    ►Isolated
    ►Both of above
    ►None of these
    Question : 5 of 10 ( Marks: 1 ) - Please choose one
    Timer interrupt occurs _______ times every second by means of hardware.
    ►18.2 (Page 28)
    ►16.2
    ►15.2
    ►14.2
    Question : 6 of 10 ( Marks: 1 ) - Please choose one
    An I/O device cannot be directly connected to the busses so controller is placed between CPU and I/O.
    ►True (Page 83)
    ►False
    44
    Question : 7 of 10 ( Marks: 1 ) - Please choose one
    Tail of keyboard should get to get the start of buffer.
    ►True (Page 55)
    ►False

    Question : 8 of 10 ( Marks: 1 ) - Please choose one
    ____ No. of bytes are used to store the character in the keyboard buffer.
    ► 1
    ►2 (Page 54)
    ►4
    ► 8
    Question : 9 of 10 ( Marks: 1 ) - Please choose one
    We have set the bit No. 7 of IMR(Interrupt Mask Register) to unmask the Interrupt so that interrupt _____ can
    occur at ____ line.
    ►0xf ,IRQ 7
    ► 0xa, IRQ 6
    ► 0x8, IRQ 5
    ►0x6, IRQ 2

    Question : 10 of 10 ( Marks: 1 ) - Please choose one
    If we want to produce the grave voice from speaker phone then we have to load the ____ divisor values at Port
    ____.
    ►high, 0x42
    ►low, 0x22
    ►high, 0x22
    ►low, 0x42

  • 0 Votes
    2 Posts
    173 Views
    M

    @zaasmi said in CS609 GDB1 Solution and discussion:

    By increasing the surface area of hard disk there is an increase of data storage. Do you think whether there is any negative impact of increasing surface area as well?

    Yes, by increasing the surface area of hard disk there is an increase of data storage negative impact of increasing surface area as well As a greater amount of magnetic media can reside on the hard surface of the disk also because the surface area of the disk is increased by increasing the number of platters.
    Increasing the surface area clearly increases the amount of data that can reside on the disk as more magnetic media no resides on disk but it might have some drawbacks like increased seek time in case only one disk platter is being used.

  • CS609 GDB.1 Solution and Discussion

    Unsolved
    1
    0 Votes
    1 Posts
    457 Views
    No one has replied
  • 0 Votes
    4 Posts
    533 Views
    cyberianC

    @moaaz
    Another Idea solution

    #include <bios.h> #include <dos.h> FILE *fp; unsigned char buf[1024]; unsigned char st[60]; unsigned char headno[10]; unsigned char secno[10]; unsigned char trackno[10]; void main (void) { int i; for (i=0; i<1024; i++) buf[i]=0; gets(st); fp=fopeon(st,”wb”); printf(“Head”); gets(headno); puts(headno); printf(“/nsector ”); gets(secno); puts(secno); printf(“/ntrack ”); gets(trackno); puts(trackno); i = biosdisk(2, 0x80, atoi(headno), atoi(trackno), atoi(trackno), 2,buf); } if(*(((char *)(&i))+1)= =0) { fwrite(buf,2,1024,fp); fclose(fp); } else { printf(“Cannot Read Error# = %x” i); }
  • 0 Votes
    2 Posts
    315 Views
    M

    yes its true the memory addresses of COM ports remain same for all computers

  • PPI / MPI - What are the real differences?

    Solved
    4
    1 Votes
    4 Posts
    190 Views
    cyberianC

    @zaasmi Programmable Peripheral Interface (PPI)

  • CS609 Mid Term Past Paper By @Moaaz

    1
    0 Votes
    1 Posts
    366 Views
    No one has replied
  • 0 Votes
    4 Posts
    405 Views
    M

    @zaasmi

    CS609 Correct Solution: #include<conio.h> #include<BIOS.H> #include<stdio.h> #include<DOS.H> void interrupt (*oldTimer)(void); // To store current Timer vector void interrupt (*oldKey)(void);// To store current KeyVector void interrupt newTimer(); //New Timer Function void interrupt newKey(); //New Key Function char far *scr= (char far *)0xBS090200381; //Screen segment int i, t=0,m=0; char charscr[4000]; //Character Array void main() { clrscr(); for(i=0;i<4000;i++) *(scr+i)=0x41; // Displaying A on whole screen oldTimer=getvect(8); oldKey=getvect(9); setvect(8,newTimer); setvect(9,newKey); getch(); } void interrupt newTimer() { t++; if((t>=90) && (m==0)) { for(i=0;i<4000;i++) charscr[i]=*(scr+i); //Storing all characters in array for(i=0;i<4000;i+=2) { *(scr+i)=0x20; // Blank screen *(scr+i+1)=0x07; } t=0; m=1; } (*oldTimer)(); } void interrupt newKey() {int w; if (m==1) { for(w=0;w<4000;w++) *(scr+w)=charscr[w]; // Recovering all characters on screen. m=0;} (*oldKey)(); }