Assignment 1

The assignment is due Tuesday, September 20, 6.59 pm EDT, to be submitted via CourseWorks.

Some of the questions below are research questions, where you are asked to find information about a particular issue. You may use the Engineering Library, any text books you have, one of the paper from the class readings, or the web to come up with answers. Be sure to cite your sources. Generally, a paragraph or two should be sufficient to answer the question. There is no need to write a tutorial.



  1. Gather your project team and decide on the project topic. As part of this "exercise", list the team members and provide a few paragraphs of the project goals and architecture (e.g., OS and development platform, standards, key functionality.)
  2. Name two other common examples of a non-electrical interface standards (in the sense discussed in class) that have been in common usage for at least ten years. Describe which parts of the respective industry it "connects".
  3. We discussed the economics of peer-to-peer systems. Estimate the cost to an end user of a P2P system if the system is on continuousaly, 24/7. State your assumptions and source with respect to system energy consumption. For simplicity, assume that each kWh costs $0.10.
  4. Recently, there has been a lot of interest in virtualization and cloud computing. What aspects of cloud computing mimic the attractive features of peer-to-peer systems? What aspects differ?
  5. What are the advantages and disadvantages of implementing multicast at the network layer vs. the application layer? Describe briefly how you would envision multicast (one-to-many transmission) at the application layer.
  6. Programming problem: This is the first part of the semester project of building a video application, although you'll only re-use parts of this project later. The goal of this programming assignment is to (re)-acquaint you with basic unicast socket programming and timer handling, which you will need for the following projects.

    Build a "ping-pong" application that uses threads, select() or poll() to receive UDP packets sent to port 5000. Upon receiving the packet, your application should return it to the sender, after waiting for 500 ms. The packet contains a text string with a counter, which is incremented on each transmission, e.g., a node that receives a packet with counter value 17 would return one with counter 18.

    You can use any port number you like, but 5000 is recommended.

    The cycle repeats, so that an observer would see packets echoing back and forth between the two systems.

    To get things started automatically, each system should start a timer when waiting for a packet. The timer value should be chosen randomly, i.e., differently for each invocation of your client, and range between 2 and 5 seconds. If there is no packet within that interval, the client initiates the ping-pong. There is a slight chance that both sides will start transmiting, but this should be rare.

    Each side should print out the counter (sequence number) in the packet and the timestamp when the packet was received and the answer was sent.

    The destination address for the packets is specified as a commandline argument -d, as in

    (berlin)$   pingpong -d
    (chicago)$  pingpong -d

    if you want the two machines, berlin and chicago, to play ping-poing with each other.

    The application can be written in C, C++, C# or Java. You may choose either Linux, Solaris or Windows (XP). The programming style guidelines apply.

    You should also capture the exchange for about 10 packets, including the start-up, using Ethereal or tcpdump. Include the dump, as a text file or dump file, with your assignment.