1

When buying a barometer for my current project at work, I chose the MikroElektronika click 3 barometer. However, as it turns out, the library for it doesn't exist for Arduino. I know it uses I2C communication, so I tried connecting the board to my Arduino UNO R3 as follows:

schematic

simulate this circuit – Schematic created using CircuitLab

However, I do not know how to use the output of the sensor. Is there a way to access the raw data measured by the sensor and post-process it myself, or is a library needed?

Thanks for your help

2
  • 1
    Of course there is a way. There is a document called "Data Sheet" for your barometer IC and there should be everything about communication.
    – KIIV
    Commented Jun 28, 2022 at 8:58
  • 1
    The datasheet for DPS368 is available at infinion site. You can use wire library to read the i2c data from it. There are also some information on Mikroe about the board configuration and some c snippets.
    – hcheung
    Commented Jun 28, 2022 at 14:19

1 Answer 1

1

I have found MikroElektronika library for the barometer 3. You can get basic idea how to communicate with the sensor. MikroElektronika c libraray

You can develop your own library based on that one for Arduino or you can read the data sheet of the sensor for more details.

5
  • You have an invalid link
    – hcheung
    Commented Jun 28, 2022 at 14:20
  • I have fixed the link
    – Arslan
    Commented Jun 28, 2022 at 15:49
  • Hi Arslan, thank you for your answer. However, it seems this library is only usable with MikroE compilers? Or is ther a way to import it on Arduino?
    – Kajitrim
    Commented Jun 29, 2022 at 8:05
  • The code is in C, however, a quick looks at the library source file, it does allows to be compiled in C++. So you need to copy the barometer3.c and barometer3.h into your arduino project file, copy the main.c to your project folder and rename it to barometer3.ino (or your project_name.ino), and modify it to the Arduino sketch format, and if compiler complains, do the modification to the source code or your sketch to make it work.
    – hcheung
    Commented Jun 30, 2022 at 2:55
  • You need to modify the file to be able to use them
    – Arslan
    Commented Jun 30, 2022 at 9:38

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.