I want to build a simple communication system including transmitter, receiver an
ID: 3633688 • Letter: I
Question
I want to build a simple communication system including transmitter, receiver and the media which applies parity check error detection method to test if the data gets any corruption while transmitting from the transmitter to the receiver through the media.At the transmitter side, the program should receive the message from the user, convert the message to the ASCII code and make the even parity check. It should receive the text message from the user and save it in order to process it. The transmitter converts the message (characters) to ASCII code.
Note: before you start doing your own coding to build a function to convert the letters to ASCII, try to check if the programming language that you are going to use had built in function. It is easier to use the function, if available, rather than spend some time coding your own function. Make the parity check for each of character's ASCII code.
Note: assume that the program use even parity check. After that, the message is ready to be transmitted through the media.
The media can affect the data by making corruption to some of the bits (change the bit from 0 to 1 or from 1 to 0). Error function design should be implemented as follows: Choose a random number r1 -> [0, 1], this random number is used to determine if the media will add error to the data or not. Assume that the probability the media will add error is equal 0.5. This means the probability the media add error is the same as the probability does not add any error to the data.
If r1 > 0.5
The media will add error to the data
Else
The media will not add error to the data
add_error () {
r2 -> [0, size] // this random number is used to determine the bit that has been corrupted.
If bit[r2] = 0 ;
bit[r2] = 1;
else
bit[r2] = 0;
}
At the receiver side, you have to do the opposite of what you have done at the transmitter side. Divide the received binary message to bytes (8 bits). Count the number of 1's that you have in each byte. The byte that has odd number of 1's is regarded as corrupted. While the bytes that have even number of 1's is regarded as received correctly. Remove the bit number 8 (last bit) from each byte (the bit that had been added by the transmitter). Convert the code from ASCII to character. Show the received message.
I would like all coding preferably in Java. Thanks! Will definitely rate!!!
Explanation / Answer
check this... http://davis.foulger.info/research/unifiedModelOfCommunication.htm http://www.informit.com/articles/article.aspx?p=1087655
Related Questions
Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
drjack9650@gmail.com
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.