Stanford Solar Car Project-How it all started

How it all started

The Challenge: Design and Build a Solar-Powered Race Car in One Year

The Stanford Solar Car Project (SSCP) is a student-run, non-profit organization that is fueled by its members' passion for environmentally sustainable technology – and a great challenge. The team of students designs, builds, and races a solar-powered car in the World Solar Challenge, a cross-continent (about 2,000 miles) race across the Australian Outback that occurs every two years. All energy for the car must come from the sun or be recovered from the kinetic energy of the car. One of the most complex issues that solar car teams address is getting optimum efficiency from the power electronics and collecting real-time data from systems such as tires, array, battery, and suspension to be able to detect problems in real time during the race.

In the 2011 race, the SSCP "Xenith" car competed in a field of 37 teams from 21 countries, placing fourth in its class and eleventh overall. The Xenith car is controlled by an electrical system based on STMicroelectronics' STM32® ARM® Cortex™-M MCUs. The Xenith electrical system includes about 20 subsystems, from complex power electronics such as maximum power point trackers, to low power in wheel wireless pressure sensors. The project is challenging, especially considering that members of the SCCP are typically undergraduates with minimal engineering backgrounds who gradually build their knowledge while working on a vehicle. But the project's timeframe is another kicker. "We work on a really short time cycle," said Gregory Hall, a senior in computer science and the project's engineering director. "Once the rules come out, you have less than a year to design and build your car."

Infrastructure upgrade included switch to IAR Embedded Workbench

Once the 2011 race was over, the team took advantage of a short downtime before the next Challenge to make infrastructure upgrades. This year, the team has switched to the IAR Embedded Workbench compiler and debugger tool suite to program the 2013 car and to maintain the 2011 car. Hall explained the criteria the team used in choosing IAR Systems development tools: "What you care about is that a tool set is easy to use and really fast to develop. A lot of tool sets might have a debugging suite, but if there's a long pause and it takes me an hour to step through a section of code rather than five minutes, that's a really big difference." After evaluating IAR Systems development tools, Hall added, "We were really impressed. We wanted a stable tool set that was easy to use and that was really fast to debug with. IAR Embedded Workbench is almost like desktop debugging, or the closest thing I've found, at least in the embedded world."

With such a tight design schedule, another important criterion was that the design tools were easy to learn, and here IAR Embedded Workbench also excelled. "It was really quick to get up and running," Hall stated. "From the time I originally downloaded it to the time I had a project from a different tool set running in IAR Embedded Workbench and debugging, it was about an hour and forty-five minutes. It was really simple and fast."

A few of IAR Systems development tools stood out as particularly useful for the team. With the IAR Embedded Workbench software, printf calls in code are directed through the programmer and into a built-in console window, creating one of the easiest and most lightweight debugging tools available. IAR Embedded Workbench also provides debugging support for FreeRTOS, the real-time operating system used by the SSCP. FreeRTOS provides multithreading and thread-safe queues, which allowed the team to more cleanly encapsulate code and integrate modules from one board into others on the car. The flipside of this ability is that debugging can become much more complicated. Fortunately, IAR Embedded Workbench monitors the state of running threads and queues and makes that information available in the debugging view. The team was also impressed with the tools' warnings for compiler code, which raised issues that the team had missed in their testing – and that the previously used compiler had also missed.

Hall also noted that while many other tool vendors use the GCC open source compiler, IAR Systems writes its own compiler for embedded development, which offers valuable compiler flags such as the ability to turn on more strict C standards used for real-time, high-reliability, or safety-critical applications. "We write some of that code sometimes, so we found that really useful," Hall explained. "And their compiler performance is better, so it's nice to not spend time optimizing your code because your compiler does it for you."

With more than 20 subsystems, all based on the STM32 family of microcontrollers, IAR Systems' close collaboration with STMicroelectronics was also a key element in the team's tool suite of choice. While SSCP legacy hardware uses STM32 F1 chips, the car that will race in the 2013 World Solar Challenge uses STM32 F4 devices exclusively. The team was impressed with the speed at which IAR Systems was able to roll out compiler and register updates to support these new chips, which was four or five months faster than previous tools vendors were able to respond to updates.

Team members take skills learned into industry

Since 1989, the Stanford Solar Car Project has fostered nine generations of award-winning vehicles. And members who graduate from SSCP go on to work with some of the most cutting-edge technologies and firms today, such as Tesla Motors and Nanosolar, Inc., and in fields as diverse as cancer therapeutics research and software marketing. Since the team only produces one car, they often use innovative new technologies long before they are seen in production automobiles. For example, the team has used carbon fiber extensively for over two decades, and used lithium ion batteries in its packs since the early 2000s – more than five years before they would appear in a production car.

Former team members leverage many of the skills they first develop working with SSCP. As team members graduate and move into industry, IAR Systems' support for the broadest range of silicon and operating system vendors will allow them to take that experience and apply it directly to company projects, regardless of platform.

With the support of industry leaders such as IAR Systems, the Stanford Solar Car Project has access to some of the most innovative technologies available today, to help them create solutions for tomorrow. About IAR Embedded Workbench, Hall says, "We have a difficult task, but now we have the best tools to do it."