# Connecting MS5637 to Pico

**URL:** <https://forum.core-electronics.com.au/t/connecting-ms5637-to-pico/12481>\
**Category:** Core Electronics\
**Created:** [15 December 2021 04:13 UTC](https://forum.core-electronics.com.au/t/connecting-ms5637-to-pico/12481 "2021-12-15T04:13:42Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![Tyrel158702](https://avatars.discourse-cdn.com/v4/letter/t/3d9bf3/32.png) [@Tyrel158702](https://forum.core-electronics.com.au/u/Tyrel158702)\
**Post date:** [15 December 2021 04:13 UTC](https://forum.core-electronics.com.au/t/connecting-ms5637-to-pico/12481/1 "2021-12-15T04:13:42Z")

</div>

Hi Guys,  
I’m trying to connect the PiicoDev Pressure Sensor to the Pico and for my project I need to wire them directly. I’m just having trouble with which pins I should be connecting to.  
I’ve tried connecting SDA and SCL to both pins 1 & 2 and 5 & 6 and when I run the provided code I get the following error:

```auto
Traceback (most recent call last):
  File "<stdin>", line 8, in <module>
  File "PiicoDev_MS5637.py", line 69, in __init__
  File "PiicoDev_Unified.py", line 56, in write8
OSError: [Errno 5] EIO

```

Having a bit of a dig around and I can’t see if I should be connecting to something else.

Thanks for your help.

---

<div class="post-metadata">

**Author:** ![Oliver](https://yyz2.discourse-cdn.com/flex028/user_avatar/forum.core-electronics.com.au/oliver/32/3315_2.png) [@Oliver](https://forum.core-electronics.com.au/u/Oliver)\
**Post date:** [15 December 2021 04:40 UTC](https://forum.core-electronics.com.au/t/connecting-ms5637-to-pico/12481/2 "2021-12-15T04:40:57Z")

</div>

Hi Tyrel, welcome to the forums!

Just to check, are you following this guide and have correctly installed all the libraries?

> **[PiicoDev Pressure Sensor MS5637 - Raspberry Pi Pico Guide - Tutorial](https://core-electronics.com.au/tutorials/piicodev-pressure-sensor-ms5637-raspberry-pi-pico-guide.html)**
>
> Introduction
> This guide will help you read barometric pressure from your PiicoDev® Pressure Sensor and a Raspberry Pi Pico
> To follow along, it's best to have:
> 
> A Raspberry Pi Pico with pins soldered (pointing down)
> A PiicoDev Pressure Sensor MS5637
> A...

And have you setup Thonny as per this guide?

> **[How to Setup a Raspberry Pi Pico and Code with Thonny - Tutorial](https://core-electronics.com.au/tutorials/how-to-setup-a-raspberry-pi-pico-and-code-with-thonny.html)**
>
> Let's get set up with scripting in Thonny for the Raspberry Pi Pico. 
> We'll install Thonny, configure for Pico and write our first script. To follow along you'll need:
> 
> A Raspberry Pi Pico
> A USB micro B lead
> 
> 
> Contents
> 
> Install Thonny
> Set up...

If you’re not using the [Piicodev Expansion Board for Raspberry Pi Pico](https://core-electronics.com.au/piicodev-expansion-board-for-raspberry-pi-pico.html) you’ll need to connect SDA and SCL to GPIO Pins 8 and 9, respectively (Physical Pins 11 and 12) if you want to stick with the defaults (checkout the [schematic for the Expansion board](https://github.com/CoreElectronics/CE-PiicoDev-Expansion-Board-for-Raspberry-Pi-Pico/raw/main/Documents/schematic.pdf)).

You’ll also need to make sure you’ve connected the I2C power pin to 3.3v output on the Pi Pico (physical pin 36), and not VBUS (Physical Pin 40) as this is connected to the +5v V\_BUS pin from the USB power input, and doing so may damage your Piicodev module, and/or your Pico.

A [quick google](https://www.google.com/search?q=OSError%3A+%5BErrno+5%5D+EIO+i2c+pico) for that error code shows [someone else had a similar problem](https://forums.raspberrypi.com/viewtopic.php?t=318848) - they were not specifying the device address correctly. Note that 0x10 is not the same as 10; 0x10 (ie 10 base 16) == 16 base 10. See:

> **[Hexadecimal](https://en.wikipedia.org/wiki/Hexadecimal)**
>
> In mathematics and computing, the hexadecimal (also base 16 or hex) numeral system is a positional numeral system that represents numbers using a radix (base) of 16. Unlike the decimal system representing numbers using 10 symbols, hexadecimal uses 16 distinct symbols, most often the symbols "0"–"9" to represent values 0 to 9, and "A"–"F" (or alternatively "a"–"f") to represent values from 10 to 15.
> Hexadecimal numerals are widely used by computer system designers and programmers because they p...

Hope this helps! 🙂

---

<div class="post-metadata">

**Author:** ![Robert93820](https://avatars.discourse-cdn.com/v4/letter/r/ac91a4/32.png) [@Robert93820](https://forum.core-electronics.com.au/u/Robert93820)\
**Post date:** [15 December 2021 04:56 UTC](https://forum.core-electronics.com.au/t/connecting-ms5637-to-pico/12481/3 "2021-12-15T04:56:25Z")

</div>

Hi All  
You have connected the ground wire haven’t you ???  
You have not mentioned that and at this end we have no way of knowing. All the software fiddles in the world will not help if basic connections are not correct.  
Cheers Bob

---

<div class="post-metadata">

**Author:** ![Liam](https://yyz2.discourse-cdn.com/flex028/user_avatar/forum.core-electronics.com.au/liam/32/3562_2.png) [@Liam](https://forum.core-electronics.com.au/u/Liam)\
**Post date:** [15 December 2021 05:06 UTC](https://forum.core-electronics.com.au/t/connecting-ms5637-to-pico/12481/4 "2021-12-15T05:06:05Z")

</div>

Hi Tyrel,

Welcome to the forum!!

@Liam120347 make something use a similar method to what you look to be using on this forum topic: [High pitch screeching coming from a board - #3 by Liam120347](https://forum.core-electronics.com.au/t/high-pitch-screeching-coming-from-a-board/11533/3)

You can refernce the green pinout card you should have received in your order as a quick sanity check - making sure to solder all of the connections that Olver and Bob have mentioned ensuring that there arent any shorts. Yellow being SCL or clock and blue being SDA or Data for the PiicoDev cables.

If you could send through a photo of how you have everything connected that would be great to make sure your hardware is all good!

Liam.

---

<div class="post-metadata">

**Author:** ![Tyrel158702](https://avatars.discourse-cdn.com/v4/letter/t/3d9bf3/32.png) [@Tyrel158702](https://forum.core-electronics.com.au/u/Tyrel158702)\
**Post date:** [15 December 2021 05:56 UTC](https://forum.core-electronics.com.au/t/connecting-ms5637-to-pico/12481/5 "2021-12-15T05:56:12Z")

</div>

Thanks for the help everyone! Seems to be working now.  
Yep, power and ground were connected as above - I’ll keep in mind to mention that sort of stuff in the future.

Ty

---

<div class="post-metadata">

**Author:** ![Oliver](https://yyz2.discourse-cdn.com/flex028/user_avatar/forum.core-electronics.com.au/oliver/32/3315_2.png) [@Oliver](https://forum.core-electronics.com.au/u/Oliver)\
**Post date:** [15 December 2021 05:59 UTC](https://forum.core-electronics.com.au/t/connecting-ms5637-to-pico/12481/6 "2021-12-15T05:59:13Z")

</div>

Great to hear! 😃

I’d love to see some pics of what you make, and just let us know if you get stuck on anything again
