Presentation is loading. Please wait.

Presentation is loading. Please wait.

AP CSP: Sending Binary Messages with the Internet Simulator

Similar presentations


Presentation on theme: "AP CSP: Sending Binary Messages with the Internet Simulator"— Presentation transcript:

1 AP CSP: Sending Binary Messages with the Internet Simulator
August 26-27, 2016

2 Introduction Last class we built devices that could we could use to communicate with each other. The device was supposed to be able to communicate as many options as possible. The idea was to create a very simple system that can accomplish this goal. Can you send a message in binary to someone you’ve never before communicated with? If yes, how? If no, what does the person receiving a message need to know in order to successfully decode the message? Why did you choose your particular message encoding strategy? List at least two reasons that justify your decision. List two issues or problems that could be improved in your encoding strategy.

3 Definitions Binary: Bit:
A way of representing information using only two options Bit: A contraction of “Binary Digit”. A bit is the single unit of information in a computer, typically represented as a 0 or 1.

4 Getting Started In order to interpret the message we needed to know we: Knew which signal represented A and which meant B And we knew there was some kind of mapping between sequences of signals and a possible message. What we were beginning to do in our last lesson was developing a communication protocol. Today we are going to develop a more in- depth protocol to solve a different problem. First I want you to decode a message that I will send you using a flashlight. Light on means state A, Light off means state B. Write down the sequence I send you on your paper.

5 Flashlight Discussion
Did the second message make you think about your answer to the first question? Do you want to change your answer to the first question? What assumptions did you make in interpreting these messages? Is this protocol specific enough to allow useful communication of a binary message? If not what information would need to be added to it?

6 More Vocabulary Protocol: Bit:
For our purposes today a “protocol” is simply a set of rules about sending, receiving and interpreting binary messages. Bit: We call each element of a binary message a bit. “Bit” is short for binary digit. So for example if you have a binary message A B B A , we would say this is a 4-bit message.

7 Internet Simulator Activity:
Today we’re going to be using the Internet Simulator on the code.org website to explore some of the challenges of sending bits on the internet. The internet Simulator helps enforce “the binary rule” for sending messages – it will present challenges that they will need to problem solve around. Before I describe the instructions on how to use the simulator, I want you to try and figure out on your own with your partner. Click any and everything to figure it out. Don’t worry you cannot break the simulator. The challenge of today’s activity is to figure out a way to coordinate actions with your partner to make this tool into a functioning two-way bit-sending device.

8 Internet Simulator Activity: Goals
You will practice relaying a 2-bit sequence with their partners. The goal is to exchange 2-bit messages (partner sends a 2-bit message, other partner sends a 2-bit message back) as quickly and accurately as possible. In other words, students are trying to get the fastest bit rate possible. Each initial sender should be able to confirm that the message was received correctly and resent because the message that they have received is the same as the original. As students iterate and perfect their protocol, they should try to extend their protocol to send more bits or send them more quickly, while maintaining accuracy. When each group has a working protocol and has time to practice (~10 minutes), have an all-class showdown to see who can do it the fastest.

9 Internet Simulator Rules /:
Student pairs can decide who sends first. I’ll reveal the sequence of bits to be sent. Partner A of each group may enter this sequence of bits into Internet Simulator but may not begin sending them. I will tell you when to start and then partners will exchange messages. During the challenge students may not communicate with one another. Students say “STOP” once they have completed their exchange. I will verify that each partner received what the other sent by checking outgoing and incoming messages.

10 Wrap-Up How has today’s activity added to or altered your definition of a bit? A major focus of today’s activity was timing and coordination. What things did you need to coordinate or agree about ahead of time in order for your protocol to work? How fast do you think computers transmit bits?


Download ppt "AP CSP: Sending Binary Messages with the Internet Simulator"

Similar presentations


Ads by Google