Massachusetts Institute of Technology Department of Electrical Engineering and Computer Science 6.111 - Introductory Digital Systems Laboratory Laboratory 2 – Car Anti-Theft System (Spring 2009) Issued: February 18, 2009 FSM Diagram Due: February 23, 2009 in class Check-Off Due: March 2, 2009 at 10PM in lab Report Due: March 6, 2009 in class Porsche Anti-Theft System A recent MIT grad just completed a very successful IPO of her Cambridge startup and celebrated by purchasing a new Porsche. Though the car has a built in anti-theft system, she is concerned since this is a standard factory unit and many people know how to disable it. So she's looking for someone to design and build a system with some hidden security features only you two will know about! Your job is to create a working prototype and a written report that will win you the job. In this lab you will implement an anti-theft system that uses several interacting FSMs to process sensor inputs and generate the appropriate actuator control signals. This lab provides you with a design methodology that will be useful in future labs and your final project. Although not required, it is suggested that you schedule a conference with a member of the teaching staff to review your design. This will help catch any major mistakes early in the process. Procedure 1. Read through the lab to understand the desired functionality, determine your approach and complete a design. Although not required, you may find it helpful to schedule a conference with a member of the course staff to review your design. This will help catch any major mistakes early in the process. 2. Turn in a copy of your preliminary FSM design to the staff (see Due Date above). 3. Prototype your design using the labkit. After you verify the anti-theft system's functionality get a member of the course staff to check you off. Be ready to demonstrate the functionality of your implementation and to answer the questions proposed in the Checkoff List. Send your Verilog code to one of the TAs as an e-mail attachment. 4. Write a detailed report (see the writing guidelines at the end of this writeup) that will satisfy the written portion of the EECS CI-M requirement. You'll submit a draft of the report for evaluation by the Writing Across the Curriculum Program and then, based on their comments, submit a final revision for grading. Description of Anti-Theft System Since your client is completely focused on her start-up, she wants an anti-theft system that's highly automated. The system is armed automatically after she turns off the ignition exits the car(i.e., the driver's door has opened and closed). The system arms itself T_ARM_DELAY after all the doors have been closed; that delay is restarted if a door is opened and reclosed before the alarm has been armed. Once the system has been armed, opening the driver's door the system begins a countdown. If the ignition is not turned on within the countdown interval (T_DRIVER_DELAY), the siren sounds. The siren remains on as long as the door is open and for some additional interval (T_ALARM_ON) after the door closes, at which time the system resets to the armed but silent state. If the ignition is turned on within the countdown interval, the system is disarmed. Always a paragon of politeness, your client opens the passenger door first if she's transporting a guest. When the passenger door is opened first, a separate, presumably longer, delay (T_PASSENGER_DELAY) is used for the countdown interval, giving her extra time to walk around to the driver's door and insert the key in the ignition to disarm the system. There is a status indicator LED on the dash. It blinks with a two-second period when the system is armed. It is constantly illuminated when either the system is in the countdown waiting for the ignition to turn on or if the siren is on. The LED is off when the system is disarmed. So far this all is ordinary alarm functionality. But you're worried that a knowledgable thief might disable the siren and then just drive off with the car. So you've added an additional secret deterrent -- control of power to the fuel pump. When the ignition is off power to fuel pump is cut off. Power is only restored when first the ignition is turned on and then the driver presses both a hidden switch and the brake pedal simultaneously. Power is then latched on until the ignition is again turned off. The diagram below lists all the sensors (inputs) and actuators (outputs) connected to the system.The system timings are based on four parameters (in seconds): 1. the delay between exiting the car and the arming of the alarm (T_ARM_DELAY), 2. the length of the countdown before the alarm sounds after opening the driver's door (T_DRIVER_DELAY) 3. the length of the countdown before the alarm sounds after opening the passenger door (T_PASSENGER_DELAY), 4. and the length of time the siren sounds (T_ALARM_ON). The default value for each parameter is listed in the table below, but each may be set to other values using the Time_Parameter_Selector, Time_Value, and Reprogram signals. Time_Parameter_Selector switches specify the parameter number of the parameter to be changed. Time_Value switches are a 4-bit value representing the value to be programmed -- a value in seconds between 0 and 15. Pushing the Reprogram button tells the system to set the currently selected parameter to Time_Value. Note that your system should behave correctly even if one or more of the parameters is set to 0. Default Timing Parameters Interval Name Symbol Parameter Number Default Time (sec) Time Value Arming delay T_ARM_DELAY 00 6 0110 Countdown, driver's door T_DRIVER_DELAY 01 8 1000 Countdown, passenger door T_PASSENGER_DELAY 10 15 1111 Siren ON time T_ALARM_ON 11 10 1010Block Descriptions/Implementation The following diagram illustrates a possible organization of your design into modules. This diagram is a high level view and does not show every necessary signal. You should implement this lab by programming each module individually and then instantiating and connecting the modules together in the toplevel labkit.v module. Then compile your implementation using the Xilinx tools, download it to your kit's FPGA, and demonstrate its operation. Please use the following labkit devices for the various sensors and actuators: Sensor/Actuator Labkit deviceHidden switch button0 Brake depressed switch button1 Driver door switch button2 Passenger door switch
View Full Document