Chapter 1: Duty cycle is the percentage when the signal was high

Digital vs. analog

analog represents the fractions in between and offers a wider range of frequencies
digital is more immune to noise (distortion and interferences), and is more flexible and scalable, and can be stored and transferred without loss.

Quantization

The process of converting a continuous analog signal to a discrete digital values.

Chapter 2

Digits

every digit has its own weight

Ex: 23 = (2x100)+(3x100)=20+3=23 For integers: 10 to the power of the digits order, starting from zero.
Case: 421: 1 is 100, 2 is 101, etc…
Whereas decimals start from 10-1, and goes down as you go to the right.
Case: 0.21: 2 is 10 pow(-1), and 1 is 10-2

HW: Determine the value of each digit in 67.924?

Binary Numbers

This actually shares some notes from CSC300’s truth table systematic insertion!

How it compares:

Binary can only be 0’s and 1’s, so the base number will be 2, and the power of it will depend on the digits placement within the table:

Ex:

-first column will be 20= 1
alternate the binary every 1 row
-second column will be 21= 2
alternate the binary every 2 rows
etc…

Table Demonstration:
Decimal NumberBinary NumberBinary NumberBinary NumberBinary Number
10000
20001
30010
40011
50100
60101
70110
80111

MSB->110111LSB.MSB->1101LSB

Converting Binary Numbers

Decimal Base: 10

Binary Base: 2

Case: convert 1101101 to decimals:

1101101: 26+25+24+23+22+21+20

0.1011 binary to decimal

2-1+2-3+2-4 = 0.6875

Decimal-to-Binary Conversion

Method 1: Sum of Weights

9 = 8+ 1 = 23 + 20 (the rest are missing so they’re replaced with zero)
= 1001

Homework: Convert 125 to binary

125 = 64 + 32 + 16 + 8 + 4 + 1
26+25+24+23+22+20 (21 is missing so it’s subsituted with zero)

Binary = 1111101

Application on Decimals

0.45 = 0.25 + 0.125 + 0.0625 etc…

Method 2: Repeated Divsion

Binary for 125:
125/2 = 62: remainder = 1 (LSB)
62/2 = 31: remainder = 0
31/2 = 15: remainder = 1
15/2 = 7: remainder = 1
7/2 = 3: remainder = 1
3/2 = 1: remainder = 1
1/2 = 0: remainder = 1 (MSB)

Binary = 1111101 (same as Method 1)

Application on Decimals

Differences:

-Division becomes multiplication
-Instead of taking the remainder, we take the total.
-We keep going until the fractional part is all 0’s (like 1.00).
-MSB/LSB are inverted (the signficance drops as you go to the right).
-If the result is 1.n, n is the number you procceed the calculations with, and the 1 goes into the binary number

Exercise using Method 1:

45.5 = 32 + 8 + 4 + 1 + 0.5
Weight: 24
0.375

Using Method 2:

Binary Addition

0 + 0 = 0
0 + 1 = 1
1 + 0 = 1
1 + 1 = 0 and carries 1 (just like decimals)

Review Binary Addition

needs to be practiced on paper/tablet

Binary Subtraction

0 - 0 = 0
1 - 0 = 1
1 -1 = 0
0 - 1 = 1 **and a borrow of 1