Me218c s21 Project Spec Rev2

You might also like

Download as pdf or txt
Download as pdf or txt
You are on page 1of 10

ME 218c Spring 2021: Revenge Of The ZIF

The Rising Edge of Darkness


Project Preview on May 20 from 1-5 pm. Grading Session on May 25 from 1-5 pm.
Project Presentation on May 26 starting at 5:00 pm.
Revision 2: 5/4/21

Goal:
The goal of this project is to provide a framework in which you can apply your knowledge of microcontrollers
and multi-processor communications to a task that will provide an enjoyable experience for the users and
the observers. This quarter, we are going to leverage the power of the Internet to make this project a reality!

Purpose:
The underlying purpose of this project is to provide you with an opportunity to integrate all that you have
learned in the ME218 course sequence, with an emphasis on the new material in ME218c.
The Task:
Design and build a Tachyon Ray Intrastellar Armored Craft (TRIAC), composed of a Tachyon Ventral System
station (TVS station), a Zero-Entropy Non-Euclidian Rudder station (ZENER station), and an Orthogonal
Power Allocation Management Platform station (OPAMP station), each constructed and operated by one
of your crewmembers. All of the TRIACs will navigate in the Linear Region1 . During games, each team will
attempt to control their TRIAC to locate, and attack the other TRIACs, to rescue the Chancellor.
Hello there!
Obi-Wan Kenobi
General Kenobi, you are a bold one!
General Grievous
1 Virtually, via an IRC channel.
ME 218c Spring 2021: Revenge Of The ZIF

Specifications
General:
□ Each member of each team will construct a station—either the ZENER, OPAMP, or TVS.
□ A team shall coordinate the design and construction of each station such that each team member’s
station can assume the role of ZENER, OPAMP, or TVS via run-time configuration.
□ The crew of each team will act in a coordinated way to control the navigation, sensing, and weapons
capabilities of their TRIAC using their respective stations.
□ The TRIACs are the latest in tele-operated vacuum-rated ordnance carriers, having all of substantial
size, speed, and firepower.
□ The stations are I/O devices which control various aspects of the TRIAC functions, and will contain an
SPDL supplied ESP32 device to communicate through an IRC channel between the various stations and
TRIACs.

Basic Game Play:


□ A game round will be a battle royale among all operational TRIACs.
□ A game round proceeds in real time, with no turn-taking.
□ The goal of the game is for each TRIAC to locate and destroy all other TRIACs to emerge victorious.
□ The game ends when only one TRIAC remains undamaged in the Linear Region, or when people get
bored.

Figure 1: The Linear Region. Two axes, x and y, are defined as shown. The x axis has a length of 512 000 km and the y axis a
length of 256 000 km. The largest value x can have is an infinitesimally small amount below 512000, and the largest value y
can have is an infinitesimally small amount below 256000. The moment x reaches 512000, it wraps around (or ”overflows”)
to 0, and likewise the moment y reaches 256000, it wraps around to 0. This is exactly equivalent to playing on the toroidal
space pictured at left.

The Linear Region:


□ The Linear Region comprises a section of empty 2D space measuring 512 000 km × 256 000 km. Due
to the extreme curvature of space in this Linear Region, the edges of the space wrap in both the Left-
Right and Up-Down directions such that travelling beyond the upper-most position causes your TRIAC
to appear at the lower-most position. (see Figure 1).
□ At the beginning of each game the participating TRIACs will be initialized to an assigned starting cell
(TBD) in the Linear Region.
□ Each cell can be occupied by more than one TRIAC or other relevant object.

2
ME 218c Spring 2021: Revenge Of The ZIF

□ The speed of light is 300 000 000 m/s. No TRIAC can exceed this speed.2

The TRIACs and Stations:


□ Each TRIAC is a collection of stations constructed and operated by a team of three.
□ Each TRIAC is equipped with a maneuvering system controlled by the ZENER, a tachyon-beam energy
weapon controlled by TVS in collaboration with the OPAMP and a Shield monitored and controlled by
the OPAMP.
□ Each TRIAC keeps track of its own velocity vector. This vector can be modified only by applying thrust
with the TRIACs engines.
□ The ship may accelerate at no more than 64 000 km/s2 .
□ Each TRIAC may fire its TVS at a rate specified in further subsections, in any direction, independent of
the direction of its own velocity vector.
□ Further details and constraints on these actions are provided in the respective station specification
section. The Game Details section provides more information on the relative timing of these actions
during a turn.
□ All stations must provide the user a method of selecting and initiating an action, as well as selecting
the parameters of that action.
□ All stations must provide the user a display of information relevant to that crew-member’s role.
□ Stations may use serial terminal I/O, but must incorporate at least 1 physical input, and at least 1 LED
output. It is preferred that these physical I/O devices are used for the most dramatic of functions.
□ Each station must be capable of operating as any of the three roles (ZENER, OPAMP, TVS) via a run-
time configuration. In order to maintain battle readiness, each station must be able to take on additional
roles in the event another station on their TRIAC fails to operate correctly.3 At minimum, the communi-
cation requirements to the other TRIACs must be upheld in the event of station dropout or malfunction.
It is acceptable to pre-define which station takes on the responsibilities of the failed station; this does
not need to be determined dynamically.
□ Each station may only serve one role if all of its TRIAC’s stations are functional.
□ Each station must implement the class-wide protocol for coordinating game information (See Commu-
nications).
□ The stations will use lab-provided ESP32 communication modules to communicate over the Internet;
further details are provided in the Communications section.
□ Crewmembers of a single TRIAC will need to maintain a separate shared audio channel to verbally co-
ordinate their actions.

The ZENER:
□ The ZENER is responsible for the navigation of the TRIAC, and is responsible for keeping the authori-
tative record of the TRIAC’s current location (position coordinates) and velocity.
□ The ZENER controls a thrust vector to maneuver the TRIAC. Thrust may be applied in any direction,
irrespective of the TRIAC’s current velocity direction. Thrusting requires 0.001 GW/km/s2
□ The ZENER is responsible for periodically integrating its velocity to calculate its position. It must also
transmit the current cell it occupies over the Internet at a rate specified in the Game Details section.
2 This galaxy happens to be in a region of space where relativity does not apply; your craft behaves perfectly Newtonian until it reaches the speed of

light.
3 The configuration may be performed via serial commands from a terminal or by the configuration of physical switches. It should be possible to achieve

role configuration without requiring a station reset in order for dynamic reallocation during an ongoing battle.

3
ME 218c Spring 2021: Revenge Of The ZIF

□ Whenever the ZENER receives a WEAPONFIREDE notification, it must determine a potential hit by cal-
culating the shortest distance from its current position to (any point on) the tachyon beam vector. If
the calculated distance is less than 1250 km, the TRIAC has been hit.
□ If the ZENER determines the ship has been hit, it will notify all stations of the hit damage on the next
periodic message to other stations.
The OPAMP:
□ The OPAMP is responsible for apportioning the energy resources of the TRIAC between the shields,
weapons, and engines.
□ The OPAMP is responsible for keeping track of the TRIAC’s current structure damage and shield charge
level.
□ The TRIAC shield may not exceed full charge capacity of 200 GJ.
□ The TRIAC additionally has a hull strength of 100 GJ. The hull strength does not recharge.
□ The OPAMP also maintains and manipulates the energy flows from the TRIACs reactor to thrusters,
weapons and shields.
□ There are 64 GW (GJ/s) available to be distributed among the three ship subsystems. Any fraction of the
total reactor power may be diverted to any subsystem, as long all subsystems together do not exceed
64 GW of power draw.
□ At any time, the OPAMP may change the power distribution from the reactor depending on the needs
of the crew.
□ The OPAMP must report the current power allocation to the other stations on their TRIAC at a rate
specified in the Communications section. The ZENER and TVS stations shall update their current power
status from these messages.
□ If the OPAMP receives a message from the ZENER that the TRIAC has been hit, the OPAMP must decre-
ment the current shield charge level by the damage caused by the tachyon beam. If the shield charge
reaches 0, any extra damage is applied to the hull. If hull integrity reaches 0, the TRIAC is disabled and
must immediately cease all actions.
□ In the event that the TRIAC becomes disabled, the OPAMP must send a status message noting this to
the other stations.
□ It is acceptable to design the input of the OPAMP station in such a way that there are several discrete
presets for energy allocation. There is no requirement that the allocation be continuously variable.
The TVS:
□ The TVS is responsible for managing weapons systems and attacking other TRIACs.
□ The TVS maintains the charge status of the capacitor bank connected to the TRIACs offensive systems.
□ The capacitor bank is recharged using power directed from OPAMP. The TVS is responsible for period-
ically integrating the power it receives to update the charge status.
□ The capacitor bank may not exceed a maximum charge of 200 GJ.
□ Firing the TRIACs offensive systems decrements the capacitor bank charge by an amount proportional
to the selected target range.
□ Any time a FIREA action is taken, the TVS must send a WEAPONFIREDE notification containing the
location of this TRIAC, and the vector of the tachyon beam.
□ Tachyon beams instantaneously strike any TRIAC within the envelope of the beam, causing 100 GJ of
impact damage.4
4 This is due to mysterious resonant effects for shorter-range beams. No one has yet found an explanation of why the damage is curiously constant.

4
ME 218c Spring 2021: Revenge Of The ZIF

□ The TVS is allowed to set the range of the tachyon beam system arbitrarily from 4096–128 000 km.
□ The energy required to fire the tachyon beam scales linearly with the selected range, from 6 GJ to 200 GJ.

Game Details:
□ The game progresses in real time, and thus all TRIACs are to broadcast their current position at a rate
of 5 Hz.
□ Messaging between stations is also limited to 5 Hz per link. That is to say that a single station will
transmit two messages every 0.2 s, with the ZENER station transmitting one additional global broadcast
during this period.
□ Because of the inherent unpredictability in Internet latency, stations must be able to accept any message
at any time, and may not have a fixed time window in which they are open to message reception.
□ Human inputs, such as button presses and direction changes, may only take effect on the following
transmitted message. Extra messages (and thus a greater than 5 Hz message rate) may not be generated
as a result of a human action.
□ Any TRIAC whose hull has dropped to 0 GJ of integrity or lower must cease to broadcast its position.
A TRIAC that has ”gone dark” is therefore correctly assumed to have been permanently disabled by
weapons fire.
□ There is no collision damage between TRIACs. Despite their immense size, the TRIACs incorporate the
latest in starship collision avoidance technology: the third dimension (on a very limited basis).
□ The game concludes when there is one TRIAC left in the Linear Region, or when the teaching staff decide
that it’s time for a new round.

Communications:
□ Communications among the stations will take place over an SPDL-supplied channel on an Internet Relay
Chat (IRC) server.
□ Each station shall use an SPDL provided ESP32 board to connect to the IRC channel.
□ Each station shall communicate with the ESP32 over an asynchronous communications channel using
9600 baud, 8N1 at 3.3V levels.
□ Any other hardware or implementation requirements or recommended practices are left to the Com-
munications Committee.
□ The details of the communications protocol will be defined and specified by a Communications Com-
mittee, which will consist of a designated representative of each project group. The specification must
be in a written form and with sufficient detail that someone skilled in ME218 material could implement
it.
□ The class communications protocol must be defined to support the functional requirements listed ear-
lier in this document. The Communications Committee is free to write a protocol of any complexity
that fulfills the functional requirements. If a particularly clever messaging definition reduces overhead
while maintaining the required functionality, this is perfectly acceptable. Or, if the Communications
Committee implements a superset of the functionally required messaging, that would also pass.
□ The communication protocol must define any addressing and packet formats if required.5
□ The communication protocol shall cover all communication handled through the ESP32, including traf-
fic between stations of a single TRIAC as well as traffic two and from stations of different TRIACs.
□ While a clear division of labor is not obvious, we strongly encourage making an effort to have the team
5 That is, Layer 3 of the OSI model.

5
ME 218c Spring 2021: Revenge Of The ZIF

members who did not serve on the Communications Committee implement the majority of the com-
munications in software.

General Requirements:
□ Automation of the setting of any control input is prohibited. That is to say that an algorithm may shall
not set thrust magnitude, direction, fire a shot, allocate power, etc. An algorithm may advise the human
operator of a station how to set the various controls to achieve a desired outcome, however, in the end
it is the human who must dial the setting, using the inputs provided, that generates a measurable effect
in the TRIAC.
□ There is no class-imposed upper limit on the number of processors employed; however, you must use
only the PIC32MX170F256B or PIC10F322. Tivas, Arduinos, Raspberry Pis, Teensys, and other micro-
controllers are not permitted.
□ You are limited to an expenditure of $220.00/team for all materials and parts used in the construction
of your project. Materials supplied to each team by SPDL, from the lab kit, or the Cabinet Of Freedom
do not count against the limit. All other items count at their fair market value. If it’s an issue with
something from the kit, we will provide a replacement for free, but we can’t guarantee latency.
Be careful with your components.
□ A project logbook must be maintained for each group. A blog is appropriate to meet this requirement as
long as it is made available to the teaching staff for review. This log should reflect the current state of
the project, planning for the future, results of meetings, designs as they evolve, etc. The project logbook
will be reviewed at irregular intervals for evaluation.
□ A report describing the technical details of the system will be required. The report should be of sufficient
detail that a person skilled at the level of ME218c could understand, reproduce, and modify the design.
The report must be in website format, and be suitable for posting on the SPDL site.
□ Stations based substantially on purchased platforms are not allowed.
□ All projects must respect the spirit of the rules. If your team is considering anything that may violate
the spirit of the rules, you must consult a member of the teaching staff.

Safety:
□ The stations should be safe, both to the user and the spectators.
□ Caution: being on a TRIAC may cause spacesickness.
□ Intentionally disabling or damaging other TRIACs is encouraged. However, prohibited actions include,
but are not limited to, jamming communications between stations. Unless it’s raspberry.
□ No part of the TRIAC may become ballistic. Only the TVS emission may be super-relativistic.
□ Approved small portable electronic devices may now be used while at sublight speeds.
□ There have been no proven negative health effects due to radiation from 5G networks, so feel free to
use those to connect your station to the IRC channel.
□ The teaching staff reserves the right to disqualify any device considered unsafe.

Checkpoints
Design Review:
On 5/4/21 we will conduct a design review, one team at a time. Each team should prepare a few images
showing your proposed designs for the stations. You will have 5 minutes to walk us through your ideas.
The focus should be on system level concepts6 , not detailed hardware or software. We will spend
6 I/O, signal conditioning architecture, etc.

6
ME 218c Spring 2021: Revenge Of The ZIF

the balance of the time giving feedback and asking questions. In addition to your concepts, you must
present, as a PDF, your plan for the development, integration and testing steps that you will follow to
complete the project. The plan must identify what functionality you will demonstrate at the two check-
points and the project preview along with the test procedures that you will use to prove that your team has
met the checkpoint. Checkpoint tests must follow an incremental integration strategy with each successive
checkpoint demonstrating all of the functionality of the prior checkpoint(s) as well as the new functionality.
This plan must be approved by the teaching staff. If we feel that it is seriously flawed, we will ask you to
revise and resubmit the following day.
Have you ever heard of the tragedy of Darth Plagueis The Wise?
Chancellor Palpatine
First Draft of Communications Standard:
Due by 5:00 pm on 5/4/21. This draft will be made available to the entire class, so that everyone is ready
to deliver feedback at the in-class review.
When I got to them, we went into aggressive negotiations.
Anakin Skywalker
In-Class Communications Standard Review:
In class on 5/5/21 we will conduct a top-to-bottom review of the Communications Committee’s draft proto-
col. Bring your prepared questions, concerns, and suggestions for improvement! Everyone should attend,
if possible—the more eyes we can put on the protocol early, the earlier we can catch the weird edge cases.
”Aggressive negotiations”? What’s that?
Padme Amidala
Communications Standard:
Due by 5:00 pm on 5/6/21. This is the working draft of the communications standard.
Well, negotiations with a lightsaber.
Anakin Skywalker
First Checkpoint:
On 5/8/21, you must demonstrate your approved 1st checkpoint functionality according to your defined
testing procedure. Note: this is a functional evaluation only. The focus should be on demonstrating func-
tional hardware and software. You may submit for approval a final revision of your checkpoint plan at this
time.
The final working version of the communications standard is due. No further changes are allowed to the
standard. This protocol will be evaluated with respect to its completeness and suitability for the proposed
system.
That’s not how the Force works!
Han Solo
Second Checkpoint:
On 5/15/21, you must demonstrate your approved 1st and 2nd checkpoint functionality according to your
defined testing procedure. The functionality demonstrated at this time must include full implementation
of the communications protocol.
Mechatronics is a pathway to abilities some may consider un-natural.
Chancellor Carryer
Project Preview:
At the Project Preview on 5/20/21, each team must demonstrate (in addition to the 1st & 2nd checkpoints’
functionality) your approved project preview functionality. The functionality demonstrated at this time
must include a demonstration of interaction between at least 2 teams’ TRIACs and stations.
The greatest teacher, failure is.
Yoda

7
ME 218c Spring 2021: Revenge Of The ZIF

Grading Session:
During the Grading Session on 5/25/21, each team will be required to demonstrate the ability to success-
fully participate in a game. This will include

1. Commencing a game with at least one other TRIAC;


2. Demonstrating all required functionality of all stations, including user interface and implementation
of the Communications Committee-designed communications protocol, including:
(a) Navigating across the Linear Region while another TRIAC tracks your position;
(b) Striking another TRIAC with your TVS’s tachyon beam;
(c) Registering shield damage when struck by another TRIAC’s tachyon beam, and subsequent recharge
of the shield.
3. Successful execution of at least sixty seconds of play.

A detailed grading check-off procedure will be published at a later date.


I know what I have to do, but I don’t know if I have the strength to do it.
Kylo Ren
Public Presentation:
This will take place on 5/26/21 starting at 5:00 pm on the Internet (aka the Linear Region). At this event,
members of the public will be encouraged to watch you fight for the reward on Chancellor Carryer’s safe
return.
It’s over, Anakin! I have the high ground!
Obi-Wan Kenobi
You underestimate my power!
Anakin Skywalker
Report:
Draft due on 5/31/21 by 4:00 pm. The final version (with revisions incorporated) is due by 5:00 pm on
6/4/20.
Amazing. Every word of what you just said was wrong.
Luke Skywalker
Celebration:
A celebration of the past 3 quarters of ME218 may take place at the Alpine Inn on 6/03/2021 starting at
3:00 pm. Mark your calendars now and save the date.
Who are you?
Tatooine Elder
I’m Rey.
Rey
Rey who?
Tatooine Elder
Rey Sistor.
Rey

Evaluation
Performance Testing Procedures:
Each team member will demonstrate their station during the first & second checkpoints and project pre-
view. Members of the teaching team will randomly assign roles to each station during the grading session.

8
ME 218c Spring 2021: Revenge Of The ZIF

Figure 2: Historical document depicting the origin of one of the three fundamental electronic passive components

9
ME 218c Spring 2021: Revenge Of The ZIF

Grading Criteria:
□ Concept (15 %) This will be based on the technical merit of the design and coding for the machine.
Included in this grade will be evaluation of the appropriateness of the solution, as well as innovative
hardware, software and use of physical principles in the solution.
□ Implementation (15 %) This will be based on the prototype displayed at the evaluation session. In-
cluded in this grade will be evaluation of the physical appearance of the prototype and quality of con-
struction. We will not presume to judge true aesthetics, but will concentrate on craftsmanship and
finished appearance.
□ First Checkpoint (10 %) Based on the results of the performance demonstrated on 5/8/21.
□ Second Checkpoint (10 %) Based on the results of the performance demonstrated on 5/15/21.
□ Preliminary Performance (10 %) Based on the results of the performance demonstrated during the
Project Preview.
□ Performance (20 %) Based on the results of the performance testing during the Grading Session.
□ Report (10 %) This will be based on an evaluation of the report. It will be judged on clarity of explana-
tions, completeness and appropriateness of the documentation.
□ Report Review (5 %) These points will be awarded based on the thoroughness of your review of your
partner team’s report. Read the explanations, do they make sense? Review the circuits, do they look
like they should work?
□ Log Book (5 %) This will be evaluated by the evidence of consistent maintenance as well as the quality
and relevance of the material in the log book.

Resources
Websites:
SparkFun Seeed Studio Jameco Mouser
Newark Ponoko Adafruit Hackaday
DigiKey McMaster-Carr HobbyKing ServoCity
You may also find PlantUML and PlantText helpful for creating message sequence diagrams.
Local Stores (Not applicable while quarantine is in effect):
J&M Hobby House in San Carlos
Jameco in Belmont
TAP Plastics in various locations
Gems of Wisdom:
Be sure to check out The ME218 Archive for guidance from past generations.
Communication is relatively more fundamental this year than most years; however, keep in mind that
there’s still plenty to be doing while one of your teammates is getting the Comm Protocol sorted. Make
effective use of this time to develop and test other systems.
Revision History
Revision 0: Out for review (3/9/21)
Revision 1: Release to students (4/28/21)
Revision 2: Clarifications added regarding communication (baud rate, station takeover, comm protocol), automa-
tion (prohibited), station roles as outcome of design review meetings. (5/4/21)

10

You might also like