IC221: Systems Programming (SP17)


Home Policy Calendar Units Assignments Resources

Prior Exam Material

Prior Written Exams

Prior Practicums

Sending Programming Questions via Email

Your instructors encourage you to send emails with questions about your programs. You may be surprised by our responsiveness and ability to help, and we do very much want to help. So, please send us your questions.

However, not all email questions are as easy to answer as others, and to make the process smoother for you, here is some guidelines (— credit to Dr. Dan Roche for the points!)

  1. Clearly indicate what class, assignment, reading, etc you are talking about. Probably a good idea to put the class and the assignment number in the subject of the email, along with a short description.
  2. Try to ask a clear question that probably has a definite answer. If your message says "I'm lost and don't know where to start", there's nothing I can do for you over email. In that case, you should schedule a time to talk in person.
  3. Explain (briefly) what you've already tried to solve your problem. That way we don't tell you something you already know!
  4. If you are asking about programming, include the short (maybe 10 lines) segment of code, and (if applicable) the exact error message you are seeing, in the plain-text body of the email. You should also attach the entire source code file(s) in case the error is not in the part of the code that you think it is and I need to look elsewhere.
  5. If you don't understand the response, or it's not helpful, email your instructor again so that they can try to explain it better. Keep in mind that the goal is to guide you to the solution, not just tell you how to do it.
  6. If you haven't received a response within 48 hours, email your instructor again to remind them of your query because your message has probably been buried in a large stack. (It is unlikely that this should happen!)

Latex HW Submissions

There is a 5 point bonus available for submitting a Latex formatted Homework.

Installing Latex on your VM or using an online Latex editor

Install latex using apt-get on your Ubuntu VM by issuing the following command

sudo apt-get install texlive-latex-*

This will take some time to complete, and it is a rather large installation, so be patient. You can then compile your tex file into a pdf with the following command:

pdflatex hw.tex

Alternatively, you could use an online Latex editor, such as sharelatex or overleaf. Both are simple, easy, and free to use. And generally, there is a wealth of information online as references for using Latex.

How Bonus Points will be Applied

  1. You can receive up to a 5 point bonus on your HW for formatting with Latex

    For the first HW, 10 points will still be used, but we will apply a 5 points bonus going forward, which is more reasonable if the bonus is going to exist for each assignment.

  2. You may receive bonus deductions for formating errors in your latex … but will never affect your overall grade (only deductions within the bonus points)

    You are expected to learn latex if you are trying to get the bonus. This means, you should learn the formatting ticks of latex; for example, that > formats to ¿ and you need to use $ > $. You can find a lot of information of how to correct formatting problems via google, and soon, you'll find that you just know how to do things in Latex.

  3. Templates will be provided for early homeworks, but not for latter ones.

    To encourage you all to participate in the bonus points, I'll continue to provide templates through 8 weeks in the course, half the year, but will stop in the second half of the course. It's on you at that point to adapt the template for each homework. Formatting deductions will still apply.

  4. Additional bonus points may be available for creative Latex formatting

    If you happen to get really good at Latex, and many of you will, I hope, then if you come up with some impressive formatting and styles, bonus-bonus points beyond the 5 points may be available. Essentially, impress us and you'll be rewarded.

Code Management System

Connecting to Lab Computers

To run any of the ic221 scripts you must be logged into a Michelson Hall, CS lab computer that is running Linux. It will NOT work on your VM on your laptop. Fortunately, access to a lab machine is rather easy from your laptop's VM using ssh, the secure remote shell.

To ssh into a lab computer, note a computer number when you visit lab and issue the following command in your terminal:

ssh -Y username@michROMcsd##u.academy.usna.edu

where:

  • username is replaced with your username (e.g., m189999)
  • ROM is replaced by the Michelson lab room number (e.g., mich302)
  • ## is replaced by the machine number you want to connect to (e.g., 02)

So, for example, for user m189999 to connect to lab computer number 02 in mich302, they will use the following ssh command:

ssh -Y m189999@mich302csd02u.academy.usna.edu

In that terminal, now connected to the remote machine, you can perform all your work and you can also run emacs/vi and it should pop up as a new window in your VM.

Updating your ic221 directory

To retrieve new course code, run the update script while connected to a lab computer:

~aviv/bin/ic221-up

This will put new files in your home directory under the ic221 folder. You will complete all your work in this directory, and only files in this directory on a lab computer can be submitted for credit.

Submitting your ic221 labs

To submit your labs, you'll use the ic221 submit script by executing the following program:

~aviv/bin/ic221-submit

The submit script will prompt you for what assignment you want to submit, so selct the right one. Then it will confirm submission.

You can submit multiple times before a deadline. It will not overwrite previous submissions, but only your last submission will be graded.

Checking Submission Success

You can check if your submission succeeded and which files you submitted using the following script:

~aviv/bin/ic221-check

The program will list all your submissions and times submitted