EoY (chapter 2: Data Packets, Data Transmission Methods, Error Checking Methods (Not ISBN or Modulo11) Flashcards
Basic info about data packets
- sometimes called datagrams
- usually 64KiB (quite small data) since it’s easier to control than large amounts
packet structure?
- packet header
- payload
- trailer
what is in the packet header?
- IP address of the sending device
- IP address of the receiving device
- sequence number of the packet (to make sure the packets can be reassembled)
- packet size (to check if all the packets have arrived intact)
- value indicating how many total packets there are in the transmission
what is in the payload?
- the actual data being sent in the packet (usually around 64KiB)
what is in the trailer?
- some way of identifying the end of the packet
- an error checking method (CRCs)
what is packet switching?
a method of data transmission in which a message is broken up into a number of packets
how does packet switching work?
- file is split into packets
- each packet follows it’s own route
- routers determine the route of each packet (it always chooses the shortest possible path available)
- packets reach the destination and are reassembled
benefits of packet switching
- no need to tie up a single communication line
- possible to overcome failed or busy lines by re-routing packets
- relatively easy to expand packet usage
- high transmission rate
drawbacks of packet switching
- packets can get lost and need to be re-sent
- prone to errors with real-time streaming
- there is a delay while packets are being re-ordered at the destination
types of data transmission
- simplex
- (full) duplex
- half duplex
- serial
- parallel
- asynchronous
- synchronous
- USB
simplex?
data is transmitted one way only (ex. computer to printer)
duplex?
data transmitted both was at the same time (ex. online gaming or face chatting)
half duplex?
data transmitted both ways, but NOT at the same time (ex. walkie-talkie)
serial?
- one bit sent at a time over a single wire
- (ex. computer to printer)
- sending data externally between devices
parallel?
- multiple bits sent at the same time using multiple wires
- (ex. computer to modem)
- sending data internally
why is serial used instead of parallel to connect devices to PCs?
- single wire has less chance of corruption
- single wire is less expensive
- more reliable over distances
- bits are still synchronized after transmission
asynchronous?
- data transmitted in an agreed bit pattern
- data bits (1s and 0s) are grouped together and sent with CONTROL BITS
- retriever of the data knows where the data starts and ends
- prevents data becoming mixed up
- control bits make it possible to separate groups of data as they arrive
synchronous?
- continuous stream of data
- data is accompanied by timing signals (generated by an internal clock) to ensure the sender and receiver are synchronized
- the receiver counts how many bits were sent and then reassembles them into bytes of data
- it is faster than asynchronous
USB?
- USB = universal serial bus
- it is a data transmission method
- bits are sent one at a time
- devices are automatically detected
- USB only fits one way so it can’t connect incorrectly
- it’s industry standard
- backwards compatible
what are the error checking methods?
- parity checking
- automatic repeat request (ARQ)
- checksum
- check digits
- echo checking
why do we need to error check?
- there is always a risk that the data has been corrupted or changed after transmission
why do errors happen?
- interference
- problems during packet switching (leads to data loss)
- skewing of data (causes bits to be out of synchronization)
parity check?
- checks a byte of data
- a parity bit is added
- counts the number of 1s
- can be odd or even
- if parity is incorrect error is detected
when will parity check not work?
- if two bits are interchanged (swapped)
- if there are multiple errors in the same byte
ARQ?
- ARQ = automatic repeat request
- uses acknowledgment ( a message sent but he receiver saying that the data was received)
- checks performed on receiving data
- if an error is detected a request is sent to resent data
- the resend request is repeated until data is sent correctly
- the acknowledgment that data is received is sent
- if the acknowledgment is not received in the set time the data is resent
checksum?
- value calculated from the data just before transmission
- it is added and transmitted with the data
- the value of recalculated after the transmission
- values are compared to check for any errors
echo check?
- when data is sent to another device, the data is sent back until it receives the correct data
- echo checks has A LOT of problems (it can’t know where the error occurred and is very repetitive and time consuming)
check digits?
- check digit = final digit included in a code
- used to identify errors in data entry caused by mistyping or mis-scanning