 for JP's product pick of the week. I just had my lower third turned off. Hello and welcome to the show. Thanks for coming. And I'm sorry about the mess, first of all. Messier than usual. And the delay. In fact, I'm going to go turn off one of the sources of the delays, which was some electrical work going on in here, including getting that vent fan on a switch there. That'll allow me to turn that off during the show. So what have we got today? I've got an exciting and excellent new product pick for you, a big, big discount on it. Before we go any further, I'll tell you, this is the place to go. If you want to jump inside of the product page, join me, because I'm broadcasting from right there inside the product page. You can just go to that QR code or that URL right there. That'll take you to the same place, which is the product page. Scroll down a bit and you'll see this video playing right in there. The discount, I believe it's a 50% off this week, is good just during the show. You don't need a coupon code or anything like that. You just want to throw it in your cart and check out before the end of the show, because we just dropped the price during the show and then bring it back up afterwards. You can get up to 10 of them, no resellers allowed. And you might want to pick up some other related stuff, which I'll reveal in a second here. But before I go any further, let's have Lady Aida tell us all about this week's product pick. Take it away, Lady Aida. Next up, this is something that we're using for internal hacking, but I thought I would make a dev board for it so other people could hack with it. It's a piezo driver using the PAM 8904. This is a chip that's specifically designed for driving piezo disks. And what's interesting is that it seems like the audio amplifier can go up to 300 kilohertz, which is not something you can do with it's 100 kilohertz, I can't remember. But it's like more than 20 kilohertz of piezo disks. So it's good for ultrasonic and like other like non audio based piezo driving needs. Sometimes you have to like vibrate something or you want to like bounce ultrasonic waves off of something a piezo will do that whereas the speaker will be too slow. So this is a driver that takes in three to five volts or two and a half to three to five volts and it will use two internal switch cap converters to give you up to three times gain on the voltage. And then it uses differential output. So if you have 3.3 volts in and you have 3.3 times gain, it'll give you 10 volts output. And then differentially, because it's like plus or minus, you'll get 20 volts across the piezo. So much stronger drives, especially we needed this for doing ultrasonic experimentation where you can't just drive it from my controller pan and get, you know, three volts, 20 milliamps output you want something much stronger. There's a little gain setting at the top. Both are off. It's, you know, if both are set to off then the sensors in sleep mode or the drivers in sleep mode, one gain, two gain, both to the right is three gain. Only thing to watch out for is don't set it to three gain if you're using four volts or higher because the output really doesn't want to be more than 10 volts peak to peak. And while I wish they wouldn't let you purposefully destroy the sensor and you're not gonna destroy it instantly it's not good for the sensor to be strained. So if you're at five volts, you know, keep it to one or two gains, you don't go above 10 volts. That is excellent advice. So look, look, there it is right there. Look at this little cute guy. This right here, that is my product pick of the week this week. It is the piezo driver amp with the PAM 8904, is that your name? What's your name? Yeah, it is the piezo driver amp with Stema and it drives the, let me say that again, it is the piezo driver amp Stema PAM 8904. So this has a three pin Stema. Remember Stema can be Stema four pin, Stema four pin QT, the small one or it can be this Stema JSTPH3 pin which allows you to plug it into power, ground and signal on your board. And then we also have terminal blocks right here for your piezo elements. So here's a typical piezo buzzer and you can drive these from a microcontroller by setting a PWM signal, but it is not gonna be super loud at least not compared to this. This will give us all the way up to the peak to peak I think 10 volt or is it 20 volt peak to 13 volts. Sorry, it's a 13 volt peak to peak that we can drive safely. And this can be driven off of either the three volt, three V three or the five volt on your microcontroller. And then like lady has said, we have some dip switches there to adjust the gain on that. So you can boost that up quite a bit. So let me do a little demo here. I'm gonna switch over to a view here and actually no wait, let me show you putting this together. Let's pull that view out of there. So before I actually zoom out, I'll show you here are the little gain switches. So I have this set to three X gain right now. You can go to two X gain at most if you're using five volts but we can go all the way up to three X gain and this would be one X and somewhat conveniently go to zero and that will actually mute the thing which is kind of nice to have that just built in there but I'll leave this up at full blast and I'm driving this with three volts so that's safe to do. And I'll come out just a little bit here and refocus for you. I don't like to use the autofocus, so there we go. So this actually is a AC element and so it doesn't really matter which wire gets plugged in where. It's not a DC thing like some speakers. So what we'll do is tighten those leads down on that piezo element. This is the large piezo element that we sell in the Adafruit store and I can show you a link to that in a second. You can also run it with the little small one. I've got a project with that on it right now. Okay, so those are in there good and snug and then you can see here we have a three pin JST and we have versions of these that terminate in a variety of ends. We've got alligator clips on them, male header pins, female header sockets. I'm using the male header pins and plugging that into a Metro RP2040 there. And you can see I've got my three volt power ground and then I'm running off of a pin D5 there. It's kind of hard to tell which one it isn't exactly. So I'll zoom out here a bit and give power to the Metro. It's gonna do a little reboot. You should be able to hear that pretty well even though my mic is a little further away. I'm gonna bring that up close and what I'll do is actually quiet this thing a bit. So that's the 1x gain and that'll turn it off even though it's still running that'll essentially mute the thing. And let's take a look at the code that runs that. So here you can see I've got kind of a complicated example you can just straight up send PWM 50% duty cycle send it frequencies, make some noise. In fact, if you look in my code window that's the simple example down here. So this is a typical one piezo duty cycle, sleep set the duty cycle to zero, pause between notes that'll just buzz it on and off. But what I'm doing is actually I made up a neat little example here using an arpeggiator and this is Todd Botts RP library that he wrote and I'm able to send it the same sort of thing. I'm sending it a note on message and that will run this right here piezo frequency is whatever the frequency the library is telling it and the duty cycle is set to 50% and then on a note off message I'm setting the duty cycle to zero. So the rest of this is all just RP stuff if you look in Todd Botts, synth IO examples, even though I'm not using synth IO here I was able to grab this utility which is kind of cool. If you want to you can use the simple IO tone to run this you can use straight up PWM tone generation and I'll show you in a second some examples of that code on the site. But actually, since I said site that is the page right there you can see there's the device for $2.48. If you look over on the right underneath this add to cart button you'll see we have some links to some JST three pin cables you could use either the female socket or male header similar to what I have there in my example or the alligator clip version and also here's a large enclosed piezo element with wires that's the same one I'm using right here. If you scroll down a bit you will see a link to the learn guide which is this right here and this will tell you all about it how to run it, how to set up the code for it there's some code examples there are pinouts right here so you can see v in you can run that anywhere actually from 2.3 to five volts if you're running off a microcontroller typically you'll just go with a 3v3 and then the signal pins now you don't have to use the JST connector you could solder to the little pads that you see on the bottom there or solder some header pins and stick it into a breadboard or a perma-proto board and you'll see here this pin signal that's where you provide your square wave and that can be anywhere from 20 Hertz which is basically at the bottom of the scale of human hearing 20 Hertz all the way up to 300,000 Hertz so that is well beyond hearing range I can, as an aging human I can hear somewhere in the probably 13,000 range I don't know how high up to go before my dogs hate me but 300,000 that's in the ultrasonic range so you can use this like Ladyada said for experimentation with ultrasonic sensing if you want to set up a receiver experiment with things that can hear the reflected ultrasonic wave come off of the surface that's a reason you might want to go up that high but audible range up to 20,000 is pretty much it for a young set of ears and if you look at, this will describe some things about the gain as well as not using the 5v at 3x gain because that's gonna bring it up to 15v which is more than this can handle then if you look there's some examples for circuit python and Arduino so if we look at the circuit python example right here this shows wiring and then in this code example right here highlighting, you can see the setup is import time, import board for pin definitions import the PWMIO library and then we set up the object piezo is PWMIO dot PWM out and then you give it a pin in this case board D5 tell it the duty cycle which at zero it's not ever on it's a flat line at zero then the frequency in this case it's being set to 440 hertz and allowing it to do variable frequency by saying variable frequency true then in the main loop there you can see there are some preset a little melody has been set up there the piezo frequency is changing and the duty cycle is going on in fact, let's run this example I'm just going to hit copy code right here now we'll go back to my board I'm going to turn the sound back up on that let's come over to my code window and that should work so I'm going to hit save and it's just going to loop that forever and ever and ever I'll resave the old code go back up to this one other thing I want to do that's just kind of fun is I have a zoom out here I have a piezo based Eurorack module that can be used sort of as a type of a microphone for tapping on it and things and it's actually pretty nice to do piezo directly to piezo and then be able to amplify that send that signal through some sound processing and so forth so if you take a look right here this is the ears module based on Tom Whitwell's microphone module this was the mutable instruments variation on that module and so there's a piezo element built under here used you can see it's noticing that I'm tapping it so that'll notice the vibrations of this so I'll go ahead and do is turn my piezo gain back up and then I'm going to press it against this and we should hear it coming through so now we're getting a amplified and processed signal amplified and now let's give it some reverb turn that back down so you can do a lot with these little beeps they don't have to just be simple indicator type of beeps they can actually be used musically if you run them through some processing it's not bad and but one thing they actually really excel at is things like indication alerts it's very easy to make this sound like your fire alarm or smoke detector going off I'm using one in my B&O 055 based power washer pressure washer for the power wash simulator because there are some calibration steps where I want to let the user know the status and so I'm using one of these little amps here as well as the smaller piezo element stuffed inside so that it's loud enough to be heard which is a good use for these so you can find a lot of uses for them let's see what else what am I forgetting so go back to this page here for a moment if you look at the main page and scroll down a bit you'll see here are three different piezo elements that we sell I've tried the small one and the large one that have the wires on them I haven't tried this one that's got the breadboard friendly legs on it but I imagine that would work as well so you can check those out those are options that might be it as far as piezos that we sell that are designed for this type of use and let's see any questions that we have in the chat let me go check out the YouTube chat let's see yeah 25,000 Hertz John Lupton says for ultrasonic dog trainers okay yeah so we could you could potentially do some dog training using this amplifier by the way I've got it plugged into a metro here just because it was convenient but you can imagine if you use something like QT pie you can get a pretty small little package there maybe a battery and a little QT pie and you can make a nice little piezo object there let's see other questions Ken Wilson asks and I don't know the answer to this how would you sense the return from the ultrasonic now we sell some devices that are designed for this and they have the sender and the receiver so you may want to look at those this would be more if you're interested in experimenting with it and then it's beyond anything I've tried so I'm not sure and if anyone in the chat knows I'm not sure what type of element you would use I don't know if it's also a piezo or a microphone instead that can detect that very high frequency reflected sound that's an excellent question maybe ask that on Eskin engineer tomorrow night Wednesday ask an engineer maybe see if that's something Lamor can talk to that would be kind of interesting let's see I think that does it what if I have I forgot anything this once again there is your picture there there is the URL if you want to use the QR code or just type in this URL it's product ID 5791 and you can see a nice close up there of the boards there is a by the way I should mention also a nice little indicator LED can you see that you see that green it's hard to see on the camera block out my fingers a little green LED lit up there to let you know when you've got power to the board anything else any other questions thanks for stopping by don't forget to check out before the end of the show because the price is going to go back up but I think that's going to do it so here let's let's all compete with these beautiful beautiful sounds here and that is it that is my product pick of the week this week it is the Stemma Piazzo driver PAM 8904 that is going to do it for this week's product pick of the week thanks so much everyone for your interest I'm John Park and I will see you next time bye bye