cs - base conversions, logic gates

0.0(0)
studied byStudied by 1 person
GameKnowt Play
learnLearn
examPractice Test
spaced repetitionSpaced Repetition
heart puzzleMatch
flashcardsFlashcards
Card Sorting

1/21

encourage image

There's no tags or description

Looks like no tags are added yet.

Study Analytics
Name
Mastery
Learn
Test
Matching
Spaced

No study sessions yet.

22 Terms

1
New cards

digital values are ____

discrete

2
New cards

binary:

1 represents a ___ ____

0 represent a ____ _____

1 - high voltage

0 - low voltage

3
New cards

how to convert binary to denary

  • Starting from the rightmost digit (least significant bit), assign powers of 2.

    • The rightmost bit is 202^020, the next is 212^121, then 222^222, and so on.

  • Multiply each binary digit (0 or 1) by its corresponding power of 2.

    • Add up all the results.


<ul><li><p>Starting from the <strong>rightmost digit</strong> (least significant bit), assign powers of 2.</p><ul><li><p>The rightmost bit is 202^020, the next is 212^121, then 222^222, and so on.</p></li></ul></li><li><p>Multiply each binary digit (0 or 1) by its corresponding power of 2.</p><ul><li><p>Add up all the results.<br><br><br></p></li></ul></li></ul><p></p>
4
New cards

convert 10110110 into denary

knowt flashcard image
5
New cards

how to convert denary to binary (small numbers) e.g. 15

  1. write out powers of 2

  2. write 1 under biggest power that can fit into denary number

  3. same for remainder

<ol><li><p>write out powers of 2</p></li><li><p>write 1 under biggest power that can fit into denary number</p></li><li><p>same for remainder</p></li></ol><p></p>
6
New cards

how to convert denary to binary (larger numbers) e.g.185

  1. by 2 and note the remainders:

  2. Write the remainders from bottom to top

<p></p><ol><li><p>by 2 and note the remainders:</p></li><li><p>Write the remainders from <strong>bottom to top</strong></p></li></ol><p></p>
7
New cards

convert 228 into binary

knowt flashcard image
8
New cards

write out conversion table for den/hex/bin

knowt flashcard image
9
New cards

how to convert hex to denary (by positional value) e.g. 38B

knowt flashcard image
10
New cards

how to convert hex to binary (by positional value) e.g. 38B

knowt flashcard image
11
New cards

how to convert binary to hex (by nibbles) e.g. 011111010010

knowt flashcard image
12
New cards

how to convert denary to hex e.g. 23

  • Divide 23 by 16:

    • 23÷16=1 remainder 7.

    • (7÷ (16^0 so 1)) = 7

  • Write the result:

    • Quotient = 1, Remainder = 7.

  • Combine the digits: 17 (Hexadecimal).

<ul><li><p>Divide 23 by 16:</p><ul><li><p>23÷16=1 remainder 7.</p></li><li><p>(7÷ (16^0 so 1)) = 7</p></li></ul></li><li><p>Write the result:</p><ul><li><p>Quotient = 1, Remainder = 7.</p></li></ul></li><li><p>Combine the digits: <strong>17 (Hexadecimal)</strong>.</p></li></ul><p></p>
13
New cards

how to convert denary to hex e.g. 458

  1. write out powers of 16, as many digits as denary number

  2. how many 162 fit into 458, 458÷256 = 1, remainder 202

  3. how many 161 fit into 202, 202÷16 = 12, remainder 10

  4. so you have 1, 12 (C in hex), and 10 (A in hex)

  5. 1CA

<ol><li><p>write out powers of 16, as many digits as denary number</p></li><li><p>how many 16<sup>2  </sup>fit into 458, 458÷256 = <strong>1</strong>, remainder 202</p></li><li><p>how many 16<sup>1 </sup>fit into 202, 202÷16 = 12, remainder 10</p></li><li><p>so you have 1, 12 (C in hex), and 10 (A in hex)</p></li><li><p>1CA</p></li></ol><p></p>
14
New cards

binary addition rules (each combo for 1, 0)

  • 0 + 0 = 0

  • 1 + 0 = 1

  • 1 + 1 = 10

  • 1 + 1 + 1 = 11

carry over

15
New cards
<p></p>

knowt flashcard image
16
New cards

4 reasons to use hex

  • less display space, faster to enter data (16 bytes as just 4 hex digits)

  • EASIER to identify values

  • EASIER to spot errors

  • (more human friendly)

  • easier to convert back to binary if necessary

17
New cards

4 uses of hex

  • colour coding e.g #FFFFF

  • low level programming (e.g. assembly): quicker, easier, less error prone

  • addresses: both IP and MAC (IPv6 uses hex)

  • error messaging: in embedded systems e.g. lifts, bc hex takes up less screen space than long binary strings

18
New cards

what are the 4 logic gates

NOT
AND
OR
XOR

19
New cards

NOT gate symbol and truth table

20
New cards

AND gate symbol and truth table

knowt flashcard image
21
New cards

OR gate symbol and truth table

at least one:

<p>at least one:</p>
22
New cards

XOR gate symbol and truth table

Exclusive or (only 1)

<p>Exclusive or  (only 1)</p><p></p>