Printers: Impact vs. Non-Impact Technology Explained

Understanding Printers and Their Types

Printers are output devices used to produce permanent output on paper. Printers can be divided into two main categories:

Impact Printers

Impact printers use hammers or pins that strike against a ribbon and paper to print text. This mechanism is known as electro-mechanical. There are two main types:

Character Printers

Character printers print one character at a time and have a relatively slower speed. An example is the dot matrix printer.

Dot Matrix Printers

Dot matrix

Read More

UML Diagrams: Sequence and Class Diagrams

Sequence Diagram

This tool is part of the UML diagrams and allows dynamic plot the sequence of steps or activities that are run on a particular use case. Elements are:

  • Objects: Represented by a rectangle with the name at the bottom, a broken line which we call lifeline. On this is placed a vertical rectangle which call activities which indicates when an object is in operation.
  • Messages: Represent information sent from the lifeline of an object to the lifeline of another. They can be of three different
Read More

Understanding Link Layer Networks: Protocols, Components, and Configurations

Chapter 9: Link Layer Networks

  1. What is the role and responsibility of the Level 2 Link Layer Network?
  2. What are the components addressed by the link layer so that it develops its responsibilities?
  3. What are the 3 types of configuration that a link can be implemented?
  4. What are the differences between the IP address and MAC address (Media Access Control)?
  5. In which part of the network protocol is Ethernet used?
  6. What were the reasons for the success of the Ethernet protocol compared to its competitors: Token
Read More

Binary Representation, Matrices, Algorithms, and Sorting

Binary Repartition

Binary Representation:

  • Signed Magnitude: The first bit determines if the number is negative (the sign bit). The rest of the bits represent the magnitude (mantissa).
  • One’s Complement: Similar to signed magnitude, but if the number is negative, all bits in the magnitude are inverted.
  • Two’s Complement: Similar to one’s complement, but 1 is added to the inverted magnitude if the number is negative.
  • Biased Representation: Similar to signed magnitude, but a bias is added to the target number.
Read More

C++ Operator Overloading and Polymorphism

Member Operators

Member operators are functions that define the behavior of operators when used with a class’s objects.

  • Unary: One operand. Examples: ++i, --i, +value, -value. Declaration: return_type operator ++/--()
  • Binary: Two operands. Examples: =, +=, -, *, /, ==, &&. Declaration: return_type operator symbol (type [identifier])
  • Ternary: Three operands. Example: condition ? expression1 : expression2

Operators can be overloaded as:

  • Member operators: Defined within the class, with access to
Read More

Assembly Code Examples: Periodic Interrupts and Keypad Access

Example 1: Periodic Interrupt and Counter

This program demonstrates a periodic interrupt that increments a counter (0 to 99) and prints its value to the text display.


JMP boot
JMP isr

stackTop EQU 0xFF
txtDisplayTens EQU 0x2E0
txtDisplayUnits EQU 0x2E1

counter: ; the counter
 DW 0

boot:
 MOV SP, stackTop ; Set SP
 MOV A, 2 ; Set bit 1 of IRQMASK
 OUT 0 ; Unmask timer IRQ
 MOV A, 0x20 ; Set timer preload
 OUT 3
 STI
 HLT

isr:
 PUSH A
 PUSH B
 PUSH C
 MOV A, [counter] ; Increment the
 INC A ; counter
Read More