From 56fdf3d26fee236b3a2bb73d890fce97010e1146 Mon Sep 17 00:00:00 2001 From: Jet Hughes Date: Wed, 2 Nov 2022 13:17:25 +1300 Subject: [PATCH] vault backup: 2022-11-02 13:17:25 --- content/notes/01-bits-and-bytes.md | 2 +- content/notes/ASCII.md | 28 ----------------- content/notes/characters.md | 47 ++++++++++++++++++++++++++++ content/notes/combinatorial-logic.md | 21 ++++++------- content/notes/cosc-204.md | 3 +- content/notes/digital-data.md | 12 ------- content/notes/unicode.md | 20 ------------ 7 files changed, 59 insertions(+), 74 deletions(-) delete mode 100644 content/notes/ASCII.md create mode 100644 content/notes/characters.md delete mode 100644 content/notes/unicode.md diff --git a/content/notes/01-bits-and-bytes.md b/content/notes/01-bits-and-bytes.md index 7d8996e95..dd9e25f92 100644 --- a/content/notes/01-bits-and-bytes.md +++ b/content/notes/01-bits-and-bytes.md @@ -11,7 +11,7 @@ sr-ease: 230 [memory](notes/memory.md) [unicode](notes/unicode.md) -[ASCII](notes/ASCII.md) +[characters](notes/characters.md) [digital-data](notes/digital-data.md) diff --git a/content/notes/ASCII.md b/content/notes/ASCII.md deleted file mode 100644 index b96192262..000000000 --- a/content/notes/ASCII.md +++ /dev/null @@ -1,28 +0,0 @@ ---- -title: "ASCII" -aliases: -tags: -- cosc204 ---- - -# ASCII Character Code -![ascii code](https://i.imgur.com/NbBtm1v.png) - -1. The computer uses ch as a integer index into a pre-existing table -2. the computer screen is made up of a thousand little dots called pixels. theyre in a rectangular grid like a table.a - -- [ascii code example](https://i.imgur.com/9uvKRVo.png) - -- There are several tables that describe what to draw - - fonts describe how to draw them -- ASCII (american standard code for information) describes what should be drawn for Roman (english like) alphabets -- e.g., - - A 1000001 (65) - - B 1100001 (97) - - 9 0111001 (57) -- There are only a few letter numbers and punctuation marks. The remaining ASCII code are non-printing and have other meaning (line feed, for feed, tab etcc) -- ASCII characters are stored using 7-bits - - so there are 128 (2^7) possible characters - - stored as a byte with the 8th bit set to zero - - For sorting purposes characters are compared on their numeric value (called the *collating sequence*) - - 'A' is before 'Z' but 'a' is after 'Z'! \ No newline at end of file diff --git a/content/notes/characters.md b/content/notes/characters.md new file mode 100644 index 000000000..876335e16 --- /dev/null +++ b/content/notes/characters.md @@ -0,0 +1,47 @@ +--- +title: "characters" +aliases: +tags: +- cosc204 +--- + +# Characters +- A written symbol. +- In english are represented as a single byte, (other languages use 2 bytes or more) +- e.g., [different types of characters](https://i.imgur.com/DBLVhw8.png) + +- characters are joined together to make human readable numbers and words + +- `char ch` +- ch is a variable name (identifier) +- used to label a location in the computer's memory where a byte is stored +- when the code is compile, the name is assigned an address, in memory. The meaning of that data depends on how a human interprets it. it might be small integer, or a character, or a color etc.d + +- each byte (or group of bytes) represents a number which maps to a character using a mapping like [Unicode](notes/characters.md#Unicode) or [ASCII](notes/characters.md#ASCII) + +# ASCII +![ascii code|300](https://i.imgur.com/NbBtm1v.png) + +A char is a 7-bit number (usually stored as a byte with the 8th bit set to zero) used as an index into a table of characters. The font describes how to draw these characters + +- ASCII (american standard code for information) describes what should be drawn for Roman (english like) alphabets +- ASCII characters are stored using 7-bits + - so there are 128 (2^7) possible characters + - stored as a byte with the 8th bit set to zero + - For sorting purposes characters are compared on their numeric value (called the *collating sequence*) + - 'A' is before 'Z' but 'a' is after 'Z'! + +# Unicode +![unicode|300](https://i.imgur.com/GEtVItW.png) + +A 21-bit code with 144,697 characters from 159 scripts + +- Other non roman languages + - greek, arabic, chinese, hebrew, japanese, thai etc. + - atrology symbols + - emoji etc +- Unicode + - developed by the Unicode Consortium + - coordinated with ISO/IEC 10646 + - unicode maps from character numbers (code points) into glyphs (graphical representations) + - Some(many) are reserved \ No newline at end of file diff --git a/content/notes/combinatorial-logic.md b/content/notes/combinatorial-logic.md index 8495b27ba..eda0abeac 100644 --- a/content/notes/combinatorial-logic.md +++ b/content/notes/combinatorial-logic.md @@ -7,7 +7,7 @@ tags: > [!Definition] > Combinatorial Logic Circuit is a circuit whose digital outputs are dependent only on its digital inputs -They can be described using logic expressions and therefore logic gates. We assume the outputs respond immediately^[1] +They can be described using logic expressions and therefore logic gates. We assume the outputs respond immediately - current flows from + to - - input to a unit (e.g., LED) is at the + end @@ -18,19 +18,18 @@ They can be defined: - Using graphical symbols # Adders -![1 Bit half adder](https://i.imgur.com/mjCVU4I.png) -![1 Bit full adder: (includes carry input)](https://i.imgur.com/yu6kS83.png) -![Ripple carry adder](https://i.imgur.com/HtEIZ5t.png) +![1 Bit half adder|300](https://i.imgur.com/mjCVU4I.png) +![1 Bit full adder: (includes carry input)|300](https://i.imgur.com/yu6kS83.png) +![Ripple carry adder|300](https://i.imgur.com/HtEIZ5t.png) # Parity Generator -- 3 Bit parity Generator - - Adds an extra bit to the input data so that the number of ones in the output is always odd - - Used for error checking - - [truth table](https://i.imgur.com/KDUiJbN.png) - - [boolean equation](https://i.imgur.com/mwBpnlO.png) - - [circuit](https://i.imgur.com/tsgDISC.png) +Adds an extra bit to the input data so that the number of ones in the output is always odd. Used for error checking + +![truth table|300](https://i.imgur.com/KDUiJbN.png) +![boolean equation|300](https://i.imgur.com/mwBpnlO.png) +![circuit|300](https://i.imgur.com/tsgDISC.png) # Demux # 7 Segment -- ![7 segment displlay](https://i.imgur.com/qtPmtwR.png) \ No newline at end of file +![7 segment displlay|300](https://i.imgur.com/qtPmtwR.png) \ No newline at end of file diff --git a/content/notes/cosc-204.md b/content/notes/cosc-204.md index 19917b8af..fff1b08ab 100644 --- a/content/notes/cosc-204.md +++ b/content/notes/cosc-204.md @@ -11,8 +11,7 @@ tags: [page](https://cosc204.cspages.otago.ac.nz) # Notes -- [ASCII](notes/ASCII.md) -- [unicode](notes/unicode.md) +- [characters](notes/characters.md) - [digital-data](notes/digital-data.md) - [memory](notes/memory.md) - [boolean-equations](notes/boolean-equations.md) diff --git a/content/notes/digital-data.md b/content/notes/digital-data.md index 1952fd389..d9656963e 100644 --- a/content/notes/digital-data.md +++ b/content/notes/digital-data.md @@ -39,15 +39,3 @@ Data is stored in [memory](notes/memory.md) - [amount of bits for different devices](https://i.imgur.com/nHrz1zX.png) # Characters -- A written symbol. -- In english are represented as a single byte, (other languages use 2 bytes or more) -- e.g., [different types of characters](https://i.imgur.com/DBLVhw8.png) - -- characters are joined together to make human readable numbers and words - -- `char ch` -- ch is a variable name (identifier) -- used to label a location in the computer's memory where a byte is stored -- when the code is compile, the name is assigned an address, in memory. The meaning of that data depends on how a human interprets it. it might be small integer, or a character, or a color etc.d - -- each byte (or group of bytes) represents a number which maps to a character using a mapping like [unicode](notes/unicode.md) or [ASCII](notes/ASCII.md) \ No newline at end of file diff --git a/content/notes/unicode.md b/content/notes/unicode.md deleted file mode 100644 index 69a470ec7..000000000 --- a/content/notes/unicode.md +++ /dev/null @@ -1,20 +0,0 @@ ---- -title: "unicode" -aliases: -tags: -- cosc204 ---- - -## Unicode -![unicode](https://i.imgur.com/GEtVItW.png) - -- Other non roman languages - - greek, arabic, chinese, hebrew, japanese, thai etc. - - atrology symbols - - emoji etc -- Unicode - - developed by the Unicode Consortium - - coordinated with ISO/IEC 10646 - - a 21-bit code with 144,697 characters from 159 scripts - - unicode maps from character numbers (code points) into glyphs (graphical representations) - - Some(many) are reserved \ No newline at end of file