Hey there, welcome to yet another blog from Formula Student Team Delft. My name is Quinten van Wingerden, and as you might remember form last time, I’m responsible for the sensor(nodes) in the car. Just this weekend I started with the 3D-design sensor node PCB. In this blog I will discuss how to process analogue and digital sensor data.
The sensor node get to process all types of data. A lot of data is analogue. In order to process analogue data, an ADC has to be used. An ADC (analogue-to-digital-converter) is used to, as the name suggests, convert analogic data to digital data. Digital data can be more easily read and therefore is easier to analyse. Before an analogic signal can be converted to digital, it has to be filtered. If this filtering is not done, all sorts of strange things happen. The signal can even be mixed with itself. When this happens there is no way to make sense of the data. Our sensornode-chip has ADC’s on-board, but the filtering had to be made from scratch.
Digital sensor data is already digital, so there is not ADC needed. There are multiple protocols for sending data digitally. For sensors, the most used are SPI and I2C. We use both these protocols on the sensor node.
SPI consists of four channels. This might not seem a lot. But, for comparison, I2C and analogue signals only use two channels. So why use SPI? Compared to I2C, SPI is, in theory, faster. But it’s complex to set up if the microcontroller has no I2C controller. Luckily our microcontroller has both controllers on-board.
But why do we use both protocols and not just stick to one? Well, each line as a certain bandwidth. If all sensors are attached to the same line they have to share bandwidth. So we made a choice: we use SPI internally and we are able to connect I2C sensors through the main connector.
I hope this blog has taught you guys something about analogue and digital sensor data. Take care!