LTR-559 on Raspberry Pico, via Thonny

I am trying to run the LTR-559 example code on a Pico using microPython and Thonny and am having problems. Has anyone else succeeded with this.

Thonny is version 3.3.3

When I try installing the ltr559 library using ‘tools/manage packages’ I get Warning: SSL certificate is not validated.

I manually installed the library via pip3.7 and the System Shell which went ok except that micropython cannot then find the library and help(‘modules’) does not show it either, so how do I access it?

The above is also true for other library modules I have tried loading via the same routes.

Not knowing how this tool chain is constructed I also loaded into pip and pip3, which made no difference.

What example code and what library?
I don’t believe the Python code will work in Micro Python, and vise versa.

Well, in Thonny under the tool “Manage Packages for Raspberry Pi Pico” there is a selector for a ltr559 library entry. This has the description:

Latest stable version: 0.1.1

Summary: Python library for the LTR559 light and proximity
Author: Philip Howard
PyPI page: ltr559 · PyPI
Requires: i2cdevice (>=0.0.6)

If I try to install it I get a 3 line error message (that won’t copy/paste) telling me that the SSL certificate is invalid. So I am looking for a way round that. I am also assuming that as it points to the Pimoroni home page that it is their version of the library for the Pico. Maybe not though!

The PyPi page links to here,
pimoroni/ltr559-python: Python library for the LTR-559 optical presence/proximity sensor (

Which, as far as I know is the Pi Python driver. It’s the one I use in Python on my Raspberry Pi Breakout garden setup.

Thanks for your help but am not sure I have the patience for tool chain/compatibility and version problems considering that what I am doing is evaluating different range sensors. Last time I used the ltr559 it was for an ATTiny MCU/application and I found it quicker and simpler overall just to write the limited functionality I needed straight from the device spec. This time I thought that as the driver is written for Python and I am using a Pico that it would be relatively simple to take a Python driver “out of the box”.