How to use the XENSIV PAS CO2 Sensor with a Raspberry Pi?

Announcements

Measure CO2 When It Matters - Infineon’s XENSIV™ PAS CO2 now comes in SparkFun Red. Check it now!

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
lock attach
Attachments are accessible only for community members.
modo
Level 1
Level 1
First question asked First reply posted Welcome!

Hi there,

we got some CO2-sensor-kits for our school (HTL) in Tirol, Austria. We usually work with raspberry pi's. I worked through all the suggested materials and documentations but could not find any hint regarding the connection to a raspberry pi. The only clou seemed to be the GitHub-repository https://github.com/Infineon/AQM-RaspberryPi, which unfortunately is empty.
 
According to the documents I found (Infineon-programming_guide_PAS_CO2_evaluationkit-ApplicationNotes-v02_00-EN), it is possible to control the XENSIV PAS CO2 via I2C or UART. To my knowledge, I need another microcontroller for I2C. But the problem is that the 10 pins on the kit are not easy to connect (the same goes for UART). I also don't think that's the real idea, otherwise there wouldn't be a separate kit for the school with an additional USB Type-A port (see the image on the first page inImport.Configure.Flash.using.WICED-Studio.v6.4.pdf). The mentioned programming guide refers to the Sensor2Go Evaluation Kit, which obviously provides pins that are very easy to connect (not so with our school kit).

Instead, our "school kit" includes a USB Type-A and a micro-USB port. The micro USB port should be used to communicate with the PC (or Raspberry Pi?). Why then do we need the Type-A port, which is even missing from the Sensor2Go Evaluation Kit? Can I simply connect the "school kit" to the Raspi via USB and then communicate directly with it, e.g. with Python? If so, with what protocol? Is there a library for this?

Unfortunately, I could not download the GUI on my Macbook because it is apparently not available for macOS. Under the search term "XENSIV PAS CO2 Sensor2Go GUI" I could not find a corresponding entry in the Toolbox Launcher, so I could not test the sensor yet on my Macbook.
Instead I downloaded the "XENSIV PAS CO2 Sensor2Go GUI" on a Windows notebook and paired the device via bluetooth. But I could not find it within the software in the window with the title "Environmental Fusion GUI", I tried everything, that came into my mind.
 

I was able to successfully download, install and open the Android app. My smartphone could also connect to the sensor via Bluetooth, but no connection could be established inside the app. After touching the one and only button inside the app, the button changed to grey and after a few seconds it aborted without a comment.

I would be very pleased if you could give me some help in this regard. Do I need additional hardware? Can I establish a connection directly via USB or only via a wireless connection? Does the whole thing work with Raspberry Pi's at all? Thank you very much!


With kind regards,
Dominik
0 Likes
1 Solution
Yashraj_P
Moderator
Moderator
Moderator
10 likes given 250 sign-ins 25 likes received

Hi @modo ,

In general it is possible to communicate with the XENSIV PAS CO2 sensor via I2C or UART, however the XENSIV PAS CO2 SensorHub/SensorNetwork already interfaces to the sensor via I2C. Both USB Ports on the board (USB A and Micro USB) are purely for powering the board and the measured data is only provided via the Bluetooth Low Energy interface. The 10 pin connector is typically used to initially program/debug the board and is typically not necessary for further usage. All Hardware and Software files for the board specifically are available at the SensorHub Github (see: https://github.com/Infineon/AQM-Sensorhub).

For the Bluetooth communication either the Windows GUI (see: https://github.com/Infineon/AQM-Windows-App) or the Android App (see: https://github.com/Infineon/AQM-Android-App) can be used. Sadly there is currently no option available for MacOS. When using an Android device, no additional pairing is needed prior to using the App, simply open the app and connect to the device found by tapping on it. Should there be no devices found at all in your Android App, please make sure to follow the installation instructions found with the latest App release (see: https://github.com/Infineon/AQM-Android-App/releases). When no devices at all are found, typically the permissions for Bluetooth and location haven’t been manually set yet.  

Of course, any device capable of Bluetooth Low Energy can be used to communicate with the XENSIV PAS CO2 SensorNetwork board. We are still working on a basic example for the connection via RaspberryPi (soon to be found here: https://github.com/Infineon/AQM-RaspberryPi). In principle you can connect to the device via Bluetooth on your Raspberry Pi and then read the corresponding Bluetooth Low Energy UUIDs for the required data (CO2 concentration, ambient pressure, temperature and humidity). The UUIDs can be found in the software part of the SensorHub Github mentioned above.

Thanks and regards,
Yashraj

View solution in original post

0 Likes
2 Replies
Yashraj_P
Moderator
Moderator
Moderator
10 likes given 250 sign-ins 25 likes received

Hi @modo ,

In general it is possible to communicate with the XENSIV PAS CO2 sensor via I2C or UART, however the XENSIV PAS CO2 SensorHub/SensorNetwork already interfaces to the sensor via I2C. Both USB Ports on the board (USB A and Micro USB) are purely for powering the board and the measured data is only provided via the Bluetooth Low Energy interface. The 10 pin connector is typically used to initially program/debug the board and is typically not necessary for further usage. All Hardware and Software files for the board specifically are available at the SensorHub Github (see: https://github.com/Infineon/AQM-Sensorhub).

For the Bluetooth communication either the Windows GUI (see: https://github.com/Infineon/AQM-Windows-App) or the Android App (see: https://github.com/Infineon/AQM-Android-App) can be used. Sadly there is currently no option available for MacOS. When using an Android device, no additional pairing is needed prior to using the App, simply open the app and connect to the device found by tapping on it. Should there be no devices found at all in your Android App, please make sure to follow the installation instructions found with the latest App release (see: https://github.com/Infineon/AQM-Android-App/releases). When no devices at all are found, typically the permissions for Bluetooth and location haven’t been manually set yet.  

Of course, any device capable of Bluetooth Low Energy can be used to communicate with the XENSIV PAS CO2 SensorNetwork board. We are still working on a basic example for the connection via RaspberryPi (soon to be found here: https://github.com/Infineon/AQM-RaspberryPi). In principle you can connect to the device via Bluetooth on your Raspberry Pi and then read the corresponding Bluetooth Low Energy UUIDs for the required data (CO2 concentration, ambient pressure, temperature and humidity). The UUIDs can be found in the software part of the SensorHub Github mentioned above.

Thanks and regards,
Yashraj

0 Likes
Yashraj_P
Moderator
Moderator
Moderator
10 likes given 250 sign-ins 25 likes received

Hi @modo ,

Hope your query is resolved. 
We are closing this thread due to inactivity. Please create a new thread for further queries.

Thanks and regards,
Yashraj

0 Likes