Pynq Instrument Cluster, as we call it, is an Automotive Hybrid Dashboard built with the purpose of being a platform demonstrator of Xilinx Cost Optimized Portfolio as well as a medium to develop building blocks for customer applications inside Avnet's Applications Team in GDL. The intention is to show the ease of software development in Python for Xilinx devices and how to develop proof of concepts by connecting hardware modules to existing development boards.This is an on going project expected to continuously increase its functionality by supporting more devices and hardware expansion.
We got some automotive stepper motors, indicator needles and a couple of scrapped dashboard face plates. They were functional so we decided to spend some time building a mechanical structure for support them alongside the corresponding light indicators. It was originally made in carved wood which limited a lot the functionality. After several tests, it was redesigned in Fusion 360, partitioned in 4 assembled blocks and 3D printed in white PLA. This provided a stable, functional and better looking structure and helped to develop basic 3D modelling skills as well :)
For this very first version, it was decided to use WS2812 neopixel LEDs which have several benefits over traditional top LEDs used in real clusters:
1. No drivers required.
2. Individual addressable devices on a chain.
3. Single I/O for programming.
4. Very bright LEDs and RGB colors available in a single unit.
5. Available IP from Adam Taylor.
Even though the 55 LEDs can be programmed using a single chain and would require only a single GPIO from the Zynq, we decided to split the chain in four parts so we can exercise IP replication and also ease a little bit the wiring and the organization of the mapping in software.
In order to show the PS-PL integration and take advantage of the fair amount of logic resources in the Zynq device, the stepper control IP was designed to run on PL and requires the use of a level translator/ current driver due to the motors operating at 5V. Four L293D devices were soldered down on a breadboard and provided an external 5V power supply to them.
For demonstration purposes, a BLE to UART module was used to connect the Zynq device to an Android application developed in the MIT ai2 app inventor platform. The app is pretty simple and just sends ASCII data over the BLE connection to the module which in turn communicates with Zynq via UART. These ASCII data is then read by the Python program which performs an action on the cluster hardware. We can change back light colors for the 4 dials, turn on and off the telltales and turn signals and move the stepper motors within the printed range in the face plate.
Initially the IP for the stepper motors were developed, simulated and tested only in PL. Fortunately the PynqZ1 and Z2 design allowed to so. The IP core required the use of an USB to UART module so we can set the angle and direction for the stepper motor to move. The clock for the stepper control was initially tested at 200 kHz which probes to be functional but quite slow. Further testing was performed at 400 and 500 kHz which provided better motion.
In order to get the PS to access the neopixels and the motor control IPs several BRAM interfaces and AXI to BRAM modules were added.
Allows quick overlay updates on running designs.Future Upgrades/Expansions
1. It is planned to replace the Pynq-Z2 with the shiny Ultra96 V2. however we still require the 5V level shifting for the steppers.
2. Enable the central display and speaker.
3. Add interior/rear camera.
4. Add several environmental sensors.
5. Support Spartan-7 devices running either MicroBlaze or Arm Cortex cores for the sensor integration C code development.