Day 3: Roswell Innovation Center: Programming the Self-Driving Vehicle

Roswell Innovation Center — Autonomous Systems Division

You spent two days working with your hands — engines, transmissions, generators, diagnostics. Today you work with code. The self-driving vehicle is the fastest-growing sector in automotive and it runs entirely on software.

Your assignment: program a prototype vehicle to navigate real-world driving scenarios autonomously. Five challenges. Get through as many as you can.

📋 Mission Brief — What You're Actually Building

Modern vehicles have systems that assist or replace human driving decisions. The umbrella term is ADAS — Advanced Driver Assistance Systems. You've experienced some of these every time you've been in a car.

Automatic Emergency Braking
Detects an imminent collision and brakes without driver input
Adaptive Cruise Control
Maintains a set following distance behind the vehicle ahead
Lane Keeping Assist
Detects lane markings and corrects drift before it becomes a problem
Brake Light Logic
Electronic systems that read deceleration rate, not just the pedal

You're going to program a Sphero Bolt to replicate each of these — not simulate them, but actually implement the decision logic. The sensor is different. The physics is identical.

⚙️ Setup — Pair Your Sphero
Instructions
Part I: Connect + calibrate
  1. Open Sphero Edu — tap the + to create a new program
  2. Tap the Sphero icon to connect via Bluetooth — your Sphero has a number on it, find the matching one in the app
  3. Calibrate aim: hold the Sphero, open the aim tool, rotate until the blue tail light faces directly away from you
  4. Test: program a 1-second roll forward. If it goes sideways, recalibrate aim.
Yesterday you used Sphero for braking experiments. If it's already calibrated and connected, skip straight to Challenge 1.
🚨 Challenge 1 — Automatic Emergency Braking (AEB)

Real-world system: AEB uses radar or cameras to detect obstacles ahead. When a collision is imminent, it brakes automatically — no driver input. Required on all new US vehicles as of 2024.

Instructions
Part I: The challenge

Program your Sphero to roll toward a wall and stop completely within 15 cm — without touching it.

Use the Sphero's infrared proximity sensor to detect the wall. When the sensor fires, your braking program triggers. Build the braking sequence using what you learned yesterday — graduated stop, not a hard stop.

Hint: in Sphero Edu block coding, look for the "when infrared" or "distance" event block.

Instructions
Part II: Acceptance test

Three consecutive successful stops within 15 cm = challenge complete. One touch = restart the count.

Extension: Place a box in the path instead of a wall. Program it to detect the box and stop — that's the pedestrian detection scenario. Same logic, different object.

🚗 Challenge 2 — Adaptive Cruise Control (ACC)

Real-world system: ACC uses radar to maintain a set following distance from the vehicle ahead. It automatically speeds up and slows down to keep the gap constant — even in stop-and-go traffic.

Instructions
Part I: The challenge

Program your Sphero to follow another Sphero at exactly 30 cm — not closer, not farther.

This requires two pairs working together: one Sphero is driven manually (the lead vehicle), one is programmed to follow (your Sphero). Your program must read the distance to the Sphero ahead and continuously adjust speed.

This is harder than it sounds. The gap needs to stay constant even when the lead Sphero speeds up, slows down, or stops suddenly.

Instructions
Part II: The real question

What happens if the lead Sphero stops suddenly? Does yours brake in time? How fast does your system need to update to prevent a collision?

A car's radar for ACC updates 50–100 times per second. Sphero's sensor updates slower. That gap is why real ACC systems sometimes fail in heavy stop-and-go.

🛣️ Challenge 3 — Lane Keeping Assist

Real-world system: Lane keeping cameras watch for painted lane lines. When the vehicle drifts toward a line, the system steers back to center — or alerts the driver. Required on most new vehicles sold in Europe, increasingly standard in the US.

Instructions
Part I: The challenge

Tape a lane 30 cm wide on the floor. Program your Sphero to travel its length without touching either edge — and to self-correct if it drifts.

Use the Sphero's color sensor or gyroscope to detect drift. When drift is detected, your program corrects heading. The Sphero must complete the lane without boundary contact.

The lane is only 30 cm wide. That's a tight margin. Your correction has to be fast enough to work but subtle enough not to overcorrect and hit the other side.

Instructions
Part II: The real question

What happens on an unmarked road? What does Tesla's lane keeping do when there are no painted lines? What does your system do?

💡 Challenge 4 — Brake Light Logic

Real-world system: Electronic brake light systems read the accelerometer — not just whether the pedal is pressed. In emergency stops, brake lights flash rapidly at high deceleration rates to warn following drivers.

Instructions
Part I: The challenge

Program your Sphero's LED matrix to display RED when decelerating and GREEN when accelerating. No other colors while moving.

Read the accelerometer. Set LED state conditionally based on acceleration direction. The color change must happen in real time as the Sphero moves.

Sounds simple — gets complex at the edges. What counts as "decelerating"? What about coasting? What about turning?

Instructions
Part II: Extension

Add emergency flash mode: if deceleration is above a set threshold (hard braking), the LEDs flash red rapidly instead of staying solid. That's the emergency brake light feature on Mercedes, BMW, and Volvo vehicles. Program it.

🔀 Challenge 5 — Intersection Protocol (Advanced)

Real-world system: This one isn't solved yet. Two autonomous vehicles approaching the same intersection from perpendicular directions need to negotiate right-of-way without a traffic light and without colliding. V2V (vehicle-to-vehicle) communication is one proposed solution. Some cities are piloting V2I (vehicle-to-infrastructure) where the intersection talks to the cars.

Instructions
Part I: The challenge

Two Spheros approach the same point from perpendicular directions. Program them to negotiate who goes first — without collision, without a pre-assigned right of way.

You have to design a communication or sensing protocol between the two Spheros. They need to detect each other and make a decision. There's no correct answer — only solutions that work and solutions that don't.

This challenge will not be solved by every pair. That's intentional. The unsolved problem is the point.

Instructions
Part II: The question worth asking

If you got your two Spheros to negotiate successfully — what would your protocol look like at scale? 10 intersections? 10,000? What breaks first?

The companies working on this problem — Waymo, Mobileye, NVIDIA — are hiring software engineers right now. The people who solve it will be in a room a lot like this one, asking exactly this question.

🎓 Where This Week Could Take You

Automotive is mid-transition. The skills that matter most right now are a mix of what you did Monday and what you did today. Here's the honest picture of what careers in this field actually look like.

Career Spotlight
ASE Certified Automotive Technician

Diagnose and repair vehicles using OBD-II systems, service manuals, and hands-on mechanical skill. Monday's teardown, Tuesday's fault code — that's this job. Path: NMJC automotive program (2 years) → ASE certification → employment. Pay in Hobbs: $20–21/hr entry, $30–40/hr with certifications.

Career Spotlight
EV / High Voltage Technician

Specialize in electric drivetrains, battery systems, and charging infrastructure. The generator challenge you built Tuesday is the generator principle inside every EV. Path: ASE certification + EV-specific training (Tesla, GM, Ford all offer it). Pay: $35–55/hr — highest-demand specialty in automotive right now. Dealerships are desperate for these.

Career Spotlight
Oil Field Equipment Mechanic

Maintain and repair engines on pump jacks, compressors, generators, and drilling rigs across the Permian Basin. Monday's engine teardown is exactly this job — except you do it on equipment worth millions of dollars. Path: Diesel/small engine certification. Pay: $35–50/hr in Hobbs — premium because the Permian Basin never stops.

Career Spotlight
Automotive Software Engineer

Write the code that runs ADAS systems — AEB, ACC, lane keeping, the intersection protocol you tried today. This is today's job but with C++, Python, and millions of test miles. Path: Computer Science or Electrical Engineering degree (4-year). New Mexico Tech, UNM, NMSU. Pay: $90,000–$150,000+ nationally. Remote-capable — you can live in Hobbs and work for Waymo.

Career Spotlight
Fleet Manager / Service Writer

The person at NPS who received your engine service report and repair estimate — that's a fleet manager. Manage maintenance schedules, approve repairs, track costs across dozens or hundreds of vehicles. Path: Business or automotive management degree, or work up from technician. Pay: $55,000–$85,000/year. Every government agency, company, and school district that operates vehicles needs one.

The honest takeaway: There are 280 million registered vehicles in the US and most run on gas. ICE mechanic jobs aren't disappearing tomorrow. But every career in this list has a path from Hobbs, and most of those paths start at NMJC — which is down the road.

🎤 Showcase — Tell Us What You Learned

Each person gets 1–2 minutes. No slides. No preparation needed. Just answer one or two of the questions below — whichever ones you actually have something to say about.

Choose one or two to answer:
01 What surprised you most across the three days — something you didn't expect to learn or do?
02 What connection did you make that you didn't see coming — between something from Monday and something from today, or between what we did and something in your real life?
03 How might you apply something you learned here — in school, in a future job, or just in your life?
04 Where do you want to take this? What would you want to learn next if you had another week?
05 If someone asked you what you did at NSEP this week — what's the one thing you'd tell them?

You tore down a real engine. Built a transmission you're taking home. Generated electricity from scratch. Diagnosed a vehicle fault. Programmed autonomous driving logic that the automotive industry is spending billions to get right.

That's three days of real engineering work. The people who built the vehicles outside this room started somewhere exactly like this.