# Raspberry Pi Pico - why does free space show as 848 kB? (and advice on how to add an SD card to an enviro indoor)

**URL:** <https://forums.pimoroni.com/t/raspberry-pi-pico-why-does-free-space-show-as-848-kb-and-advice-on-how-to-add-an-sd-card-to-an-enviro-indoor/22038>\
**Category:** Support\
**Created:** [April 24, 2023, 5:52pm UTC](https://forums.pimoroni.com/t/raspberry-pi-pico-why-does-free-space-show-as-848-kb-and-advice-on-how-to-add-an-sd-card-to-an-enviro-indoor/22038 "2023-04-24T17:52:54Z")\
**Posts on this page:** 13\
**Page:** 1

<div class="post-metadata">

**Author:** ![Bjoern](https://avatars.discourse-cdn.com/v4/letter/b/46a35a/32.png) [@Bjoern](https://forums.pimoroni.com/u/Bjoern)\
**Post date:** [April 24, 2023, 5:52pm UTC](https://forums.pimoroni.com/t/raspberry-pi-pico-why-does-free-space-show-as-848-kb-and-advice-on-how-to-add-an-sd-card-to-an-enviro-indoor/22038/1 "2023-04-24T17:52:55Z")

</div>

The Raspberry Pi Pico has 2MB flash storage.

It’s not straight forward to google how much of that is taken up by micropython, but it seems it may be about 600 kB [pico memory - Raspberry Pi Forums](https://forums.raspberrypi.com/viewtopic.php?t=328354). Also, the image e.g. ‘rp2-pico-20220618-v1.19.1.uf2’ is about 600kB; I guess that might translate into that much flash usage.

I calculate 2\*1024-600 = 1448 kB.

However, under Thonny, the free space is reported as 848 kB.

Any ideas why it’s that low?

---

<div class="post-metadata">

**Author:** ![Nox](https://sea2.discourse-cdn.com/flex016/user_avatar/forums.pimoroni.com/nox/32/9205_2.png) [@Nox](https://forums.pimoroni.com/u/Nox)\
**Post date:** [April 24, 2023, 9:04pm UTC](https://forums.pimoroni.com/t/raspberry-pi-pico-why-does-free-space-show-as-848-kb-and-advice-on-how-to-add-an-sd-card-to-an-enviro-indoor/22038/2 "2023-04-24T21:04:18Z")

</div>

It’s an artifact of how python is stored in flash, 1mb is reserved for the python interpreter and running programs.the remainder is shown as available space for saved files and additional libraries.  
Ref: [Overview | Getting Started with Raspberry Pi Pico and CircuitPython | Adafruit Learning System](https://learn.adafruit.com/getting-started-with-raspberry-pi-pico-circuitpython/overview)

---

<div class="post-metadata">

**Author:** ![Bjoern](https://avatars.discourse-cdn.com/v4/letter/b/46a35a/32.png) [@Bjoern](https://forums.pimoroni.com/u/Bjoern)\
**Post date:** [April 25, 2023, 6:31am UTC](https://forums.pimoroni.com/t/raspberry-pi-pico-why-does-free-space-show-as-848-kb-and-advice-on-how-to-add-an-sd-card-to-an-enviro-indoor/22038/3 "2023-04-25T06:31:39Z")

</div>

Hi @Nox ,

thank you!

I suppose there isn’t anything that could be done about it? I’m running a data logging application where I’m about 200 kB short of storage for data. With 1448 kB, I’d have plenty, but with 848 kB, I don’t have enough.

Many thanks!

---

<div class="post-metadata">

**Author:** ![bablokb](https://avatars.discourse-cdn.com/v4/letter/b/ee59a6/32.png) [@bablokb](https://forums.pimoroni.com/u/bablokb)\
**Post date:** [April 25, 2023, 10:24am UTC](https://forums.pimoroni.com/t/raspberry-pi-pico-why-does-free-space-show-as-848-kb-and-advice-on-how-to-add-an-sd-card-to-an-enviro-indoor/22038/4 "2023-04-25T10:24:15Z")

</div>

For data-logging, get yourself a 3-4 Euro SD-card breakout and attach it using SPI. The internal flash is not optimal for this kind of usage.

---

<div class="post-metadata">

**Author:** ![Bjoern](https://avatars.discourse-cdn.com/v4/letter/b/46a35a/32.png) [@Bjoern](https://forums.pimoroni.com/u/Bjoern)\
**Post date:** [April 25, 2023, 11:44am UTC](https://forums.pimoroni.com/t/raspberry-pi-pico-why-does-free-space-show-as-848-kb-and-advice-on-how-to-add-an-sd-card-to-an-enviro-indoor/22038/5 "2023-04-25T11:44:10Z")

</div>

@bablokb - I am toying with that idea… what are the chances of soldering something to the SPI connector to the back of this: [Enviro Indoor (Pico W Aboard) - Enviro Indoor Only](https://shop.pimoroni.com/products/enviro-indoor) ? I’m thinking of trying of this… :)

---

<div class="post-metadata">

**Author:** ![bablokb](https://avatars.discourse-cdn.com/v4/letter/b/ee59a6/32.png) [@bablokb](https://forums.pimoroni.com/u/bablokb)\
**Post date:** [April 25, 2023, 2:55pm UTC](https://forums.pimoroni.com/t/raspberry-pi-pico-why-does-free-space-show-as-848-kb-and-advice-on-how-to-add-an-sd-card-to-an-enviro-indoor/22038/6 "2023-04-25T14:55:17Z")

</div>

Looking at the schematic, it seems that GP10-GP15 are not used. This is SPI1. and there is free space on the back (if the usb-connector is on the top, these pins are on the lower left side. You don’t need all of them).

I had success with single-row female sockets. The pins of these sockets are just at the correct height of the SMD-soldered Pico. Using pins instead of sockets works also, but sockets are easier because the socket is lying flat on the pcb. Don’t use excessive heat.

---

<div class="post-metadata">

**Author:** ![Bjoern](https://avatars.discourse-cdn.com/v4/letter/b/46a35a/32.png) [@Bjoern](https://forums.pimoroni.com/u/Bjoern)\
**Post date:** [April 25, 2023, 4:06pm UTC](https://forums.pimoroni.com/t/raspberry-pi-pico-why-does-free-space-show-as-848-kb-and-advice-on-how-to-add-an-sd-card-to-an-enviro-indoor/22038/7 "2023-04-25T16:06:00Z")

</div>

Only one side of the pico is free - the other side is covered by plastic. So that would mean that the female sockets cannot be soldered?

---

<div class="post-metadata">

**Author:** ![bablokb](https://avatars.discourse-cdn.com/v4/letter/b/ee59a6/32.png) [@bablokb](https://forums.pimoroni.com/u/bablokb)\
**Post date:** [April 25, 2023, 6:42pm UTC](https://forums.pimoroni.com/t/raspberry-pi-pico-why-does-free-space-show-as-848-kb-and-advice-on-how-to-add-an-sd-card-to-an-enviro-indoor/22038/8 "2023-04-25T18:42:38Z")

</div>

This is a misunderstanding. Of course the lower side of the pico is soldered to the board. But you would solder the socket to the side of the pico, not to the top. So the socket is flat on the board (“plastic” as you call it), the pins are facing to the pico and the openings for the wires are facing outside.

---

<div class="post-metadata">

**Author:** ![Bjoern](https://avatars.discourse-cdn.com/v4/letter/b/46a35a/32.png) [@Bjoern](https://forums.pimoroni.com/u/Bjoern)\
**Post date:** [April 25, 2023, 10:34pm UTC](https://forums.pimoroni.com/t/raspberry-pi-pico-why-does-free-space-show-as-848-kb-and-advice-on-how-to-add-an-sd-card-to-an-enviro-indoor/22038/9 "2023-04-25T22:34:45Z")

</div>

That’s really helpful. When you say ‘pins’, you mean a header, right, maybe a right-angle one? Or do you mean just solder thicker wires?

I’ve yet to check the pins, but probably they won’t be in the required order for the sd card holder anyway… Just to add, I’m thinking of e.g. this [Introduction | Micro SD Card Breakout Board Tutorial | Adafruit Learning System](https://learn.adafruit.com/adafruit-micro-sd-breakout-board-card-tutorial).

---

<div class="post-metadata">

**Author:** ![bablokb](https://avatars.discourse-cdn.com/v4/letter/b/ee59a6/32.png) [@bablokb](https://forums.pimoroni.com/u/bablokb)\
**Post date:** [April 26, 2023, 7:17am UTC](https://forums.pimoroni.com/t/raspberry-pi-pico-why-does-free-space-show-as-848-kb-and-advice-on-how-to-add-an-sd-card-to-an-enviro-indoor/22038/10 "2023-04-26T07:17:49Z")

</div>

I will post an image on Thursday. Then it should be clear.

---

<div class="post-metadata">

**Author:** ![bablokb](https://avatars.discourse-cdn.com/v4/letter/b/ee59a6/32.png) [@bablokb](https://forums.pimoroni.com/u/bablokb)\
**Post date:** [April 27, 2023, 11:13am UTC](https://forums.pimoroni.com/t/raspberry-pi-pico-why-does-free-space-show-as-848-kb-and-advice-on-how-to-add-an-sd-card-to-an-enviro-indoor/22038/11 "2023-04-27T11:13:38Z")

</div>

As promised, here are two images. This is not your board, it is the badger2040w, which is physically similar. As I have written in a previous post, I would recommend a simple single row socket.

Of course you could also solder wires, or pin-headers or whatever. This depends on your soldering skills and use-case. But IMHO socket solution is the simplest. You could also add some glue to give some additional support, but that is not really necessary.

In the following images the socket is not soldered yet. And it is also not the right location for your needs.

 ![pico-with-socket-2](https://us1.discourse-cdn.com/flex016/uploads/pimoroni/original/2X/8/83165e2045c3d42ab1a93f63c53d39c54cd3d581.jpeg)  
 ![pico-with-socket-1](https://us1.discourse-cdn.com/flex016/uploads/pimoroni/original/2X/b/bdeb9b1331d9c565f39a9fe421fdff7c6461a06b.jpeg)

---

<div class="post-metadata">

**Author:** ![Bjoern](https://avatars.discourse-cdn.com/v4/letter/b/46a35a/32.png) [@Bjoern](https://forums.pimoroni.com/u/Bjoern)\
**Post date:** [April 28, 2023, 5:44pm UTC](https://forums.pimoroni.com/t/raspberry-pi-pico-why-does-free-space-show-as-848-kb-and-advice-on-how-to-add-an-sd-card-to-an-enviro-indoor/22038/12 "2023-04-28T17:44:55Z")

</div>

@bablokb - that is really really helpful - I just couldn’t picture it, now I know what to do. Thank you!

---

<div class="post-metadata">

**Author:** ![Bjoern](https://avatars.discourse-cdn.com/v4/letter/b/46a35a/32.png) [@Bjoern](https://forums.pimoroni.com/u/Bjoern)\
**Post date:** [April 29, 2023, 9:48pm UTC](https://forums.pimoroni.com/t/raspberry-pi-pico-why-does-free-space-show-as-848-kb-and-advice-on-how-to-add-an-sd-card-to-an-enviro-indoor/22038/13 "2023-04-29T21:48:43Z")

</div>

Follow-up post here: [Low power consumption on Raspberry Pi Pico / Bader / Picowbell](https://forums.pimoroni.com/t/low-power-consumption-on-raspberry-pi-pico-bader-picowbell/22086)
