PiicoDev Buzzer Device driver

Hello all,

I have noticed that whenever I connect a PiicoDev Buzzer to a circuit I start getting intermittent problems.

I have isolated these to the PiicoDev Buzzer and when I run a I2C scan routine, it works OK the first time after power up and then either it deteriorates to finding only a few devices in the I2C bus or none at all !!!

When I remove the Buzzer everything works well no matter how many times I run the scan or the frequency of the bus - I tried many combinations and the result is consistently the same.

Thank you.

The I2C scan code:

Scan I2C Bus and Display Device Addresses In Hex & Decimal

import machine
sda=machine.Pin(8)
scl=machine.Pin(9)
i2c=machine.I2C(0,sda=sda, scl=scl, freq=100000)

print(‘Scanning i2c bus…’)
devices = i2c.scan()
print("I2C Configuration: " + str(i2c))
if len(devices) == 0:
print(“No i2c device !”)
else:
print(‘i2c devices found:’,len(devices))
for device in devices:
print("Hex address: “,hex(device),” | Decimal address: ",device)

1 Like

Hi Socrates,

Sorry to hear your gear is giving you trouble!

To start with:

  • What is your host device? (Pi, Pico, micro:bit etc.)
  • How many devices are you using at a time? There’s a small chance you’re overwhelming the onboard 3.3V regulator on your host.
  • Can you please post a photo of your setup? We might notice something you’ve missed.

Keen to get to the bottom of this one!
-James

1 Like

Hello James,

I use a standard Pico with the latest MicroPython v1.19.1 version.

The behaviour is the same regardless of how many devices are on the I2C bus. I have tried it on its own and with other modules and the behaviour is the same.

I have also tried it with alternate Pico boards and the result is the same.

I have also loaded MicroPython v1.18 and the result is exactly the same

The same behaviour is observed with the Pimoroni v1.19.8 MicroPython.

So all the tests point to the Buzzer module.

Hope this helps.

Regards
Socrates

1 Like

I can send a picture but it will be the Pico with the Buzzer module on the PiicoDev LIPO expansion board, so no additional help will come of it.

Many thanks again for your assistance.

Regards
Socrates

1 Like

Hi Socrates,

Looks like you’ve put a good amount of effort into troubleshooting.

If you’d like to pursue a return/replacement, reply to your order email and we’ll take it from there.

-James

2 Likes

Hello James,

Many thanks for the offer, I have 4 buzzers and 2 behave very erratically - I was suspecting the device driver but after running some additional tests on some other Pico’s that I have used in projects, I get mixed results. That is, they work just fine with some Picos but erratically with others - truly confusing !

I will use a combo of Pico and Buzzer that works and leave it at that.

Many thanks again for all your help.

Regards
Socrates

1 Like