 All right, it's me, John Park, and it's time for John Park's workshop. Thanks for tuning in. We're up and running. Let's do this thing. Thanks for people over in the chat there on Discord. Let me bring that up right there. Hey, hi, everyone. Hey, Johnny Bergdahl. Hey, okay, you're on Steve, in parentheses, Dr. Hello, Johnny Bergdahl. Hey. I said hi to you twice. Hey, Dexter Starboard. Nice to see everybody, and hi to people over on YouTube as well. If you're watching us on Twitch or Periscope or one of the other fine streaming services and you're wondering where all the chat is happening, head on over to Adafruit's Discord server, and it's on the live broadcast channel. And that's at adafruit.it-slash-discord, and you can jump right in and get an instant invite into our server. Hey, wavey hand. Oh, Steve. All right, let's see. What are we going to do here? First thing I want to do, actually, is mention that we've got, I believe, a few spots left for this Adabox. Hey, look, I look like I'm wearing a big box right there. Hey. Adabox. 19. We've done quite a few of these, huh? Head on over to the Adafruit Adabox page. I can bring that up right here. That's what it looks like. And you can either subscribe for this one coming up. We may have a few slots left. We've just started sending out shipping notices, and I think maybe even started shipping. And if not, you can subscribe to the one after that, number 20, which will be coming out sometime in October. This one's going to be shipping real soon, or it's actually started. I sense movement in the whole shipping side of things. And I'm getting geared up to do an unboxing in a little under two weeks. It'll be on, I believe, the 28th, which is a Wednesday. It'll be a takeover of the normal Ask an Engineer time slot. And I'll be doing an unboxing there and then. So head on over to the Adabox site and sign up if it lets you. I should tell you if there's any left on this one on 19. Otherwise, you'll get in on the one following that. So who's excited about your Adabox? Has anyone gotten shipping notices? I think those have gone out. I don't know if any have hit people's doorsteps yet. I think it's a little early for that, but we've set the process in motion. So exciting, exciting Adabox. All right, what's next? I also wanted to mention that we've got the job board over at jobs.aderfruit.com. You can head over there and you can take a look at the available job postings. They look an awful lot like this right here. And this is a free jobs site where you can post positions. If you're looking to hire someone, if you're looking to have some freelance or contract work full-time, part-time, on-site, off-site, all of those are options. And you can also, if you're logged in, I don't think I'm logged in on this browser at the moment, if you are logged in, you can check out the available for hire. And you can also post your own info if you're looking to pick up some work. So that's the jobs.aderfruit.com site, and I recommend you check it out. Won't you please? All right, let's see, what else is happening here? Yeah, Johnny Bergdahl brings up a point that the Adabox, due to changes in shipping throughout the world, the costs of shipping in particular have gone bonkers. And so Adabox is available only in the United States and Canada right now. I don't know if there's any plans for changing that, but we're currently only able to do those in the US and Canada. So beware of that before you head over there to that website. Let's see, did you know that I've got this show, the JP's Product Pick of the Week show on Tuesdays happens at this time slot, so it's one o'clock Pacific, four o'clock Eastern. You should come tune in next Tuesday because on the show I have a deep, deep discount, usually around 50% off on a brand new product pick of the week. Sometimes it's digging into the archive, sometimes it's something that's been refreshed. Most often it's something that's brand spanking new. And this week, that's no exception, so let me give you a little recap. This is normally a 15 minute show, but I like to do a little one minute recap so you can see what you missed. The 24LC32EE Prom Breakout. This is some memory that you can write information to and it's not gonna go away when you pull the power on it. So what I'm gonna do is I'll go ahead and plug in one of my EE Prom Breakouts and nothing fancy, I'll just reset the board. And now when it restarts, you'll see it loaded in the first four bytes of information on the EE Prom, so it looked at address 0, 1, 2, and 3. And from that, it grabbed these hex values, so what others? Those are the RGB values of a number of neopixels. Now what I can do is go ahead and unplug that just like a game cartridge. Plug in a different one. And again, I'll just go ahead and reset. And now we've loaded in some different values right off of the chip there. That's the product pick of the week. It is the 24LC32EE Prom Breakout on I squared C, StemaQT form factor. EEPROM, it's fun to say it. EEPROM, I like saying it. All right, what else is going on here? Let's why don't we dive into a Circuit Python Parsec? Check it out. All right, well, let's get set up here. For the Circuit Python Parsec today, I wanted to talk about ModOperator or ModuloOperator. What is this? The ModuloOperator is a really useful arithmetic function that you can use in your code in order to iterate through a list endlessly. So one great use of this is you want to press a button. And each time you press it, you go between, let's say, three colors of neopixels, which is what I'm going to do here. So first, let's demonstrate it. You can see I've got a little Circuit Playground Express here. And when I click it, I'll go between orange, blue, and magenta. And each time I click it, we go through those three colors. So how do we tell this thing to cycle between those colors? Well, the way I'm doing it in this code, one thing I actually want to set up for you here, if you give me a moment, is I'm going to open up my serial. And let's see what's going on here. So I've set up some code here that I think makes it clear what ModuloO does. ModuloO is essentially a divided by b and the remainder is c. So in this case, I have this counter. Every time I press this button, the counter increments by 1. So you can see that going 35, 36. So 36 divided by 3, which is the size of this list I want to iterate to, that goes in evenly. It goes in 12 times with a remainder of 0. So I'm going to use that 0 as the first index in a list. The next time I increment this, we have a remainder of 1. So 3 goes into 37, 12 times remainder of 1. One more time, 3 goes into 38, 12 times remainder of 2. The next time we go through this, hey, we're now back at a remainder of 0. So you can do that the sort of complex way. You can do that the nice easy way, which is what you see at the bottom there. 42. And then that percent sign actually means Modulo. So 42, ModuloO3 equals 0. ModuloO3 for 43 is 1. And ModuloO3 of 44 is 2. And this goes on endlessly. And so the list here that you can see I'm using is this set of three colors, blue, magenta, and orange. There is the list. And so those are the items, 0, 1, and 2 are blue, magenta, orange. So in my code itself, what I'm doing is a bunch of printing so that it looks nice. But then really every time this button gets pressed, we just increment A by 1. That's the counter. And then we run that Modulo operation on the list value, which is this right here. So C, which is the index, is the answer to A, Modulo B. And so that is a way that you can use the mod operator in order to increment through a list inside of CircuitPython. And that is your CircuitPython parsec. Now you know I'm going to have to go and edit that down into a little two minute version later. And boy, I hope I wasn't clearing my throat the whole time. Excuse me, I got something stuck in there. I'm going to have some water. All right. Andy Calaway says Modulus, my favorite operator. It's a good one, huh? And over in Discord, I appreciate that, OK, you're on, Steve. Echoed my sentiments of how much fun it is to say eee prom. Thanks. All right. Let's see. What else? I think we're going to dig into the meat of the project today. So let me jump over to the browser, actually, for a second here. And we'll talk about a couple things. So let's bring up this little Chrome window here. So by the way, if you just go to adafruit.com slash new, you'll see our new product section. You can see the fun stuff that Lady Aida announced last night in the new, new, new, new section. And if we scroll down a bit on here, you'll see the macro pad, which I'm going to be using for today's project. There it is. So if we click on macro pad there and take a look at, scroll way down to the learn guide, primary guide. I've been using this for a couple weeks now. But the exciting thing is that Catnee has been working on a macro pad library that will make a lot of the things we're doing easier. So the way that I was using it last week, I had a bunch of individual libraries for things like the keypad, or the Rotary I.O. for Rotary Encoder, or Digital I.O. for using the switch. So what Catnee did was wrapped up the most common stuff that you'll use into this macro pad library. And so now the code is actually quite a bit more succinct. And it's a little easier and more consistent to jump in and see how it works. So what I'll do actually is let me show you some code here in Atom. And you may have seen this last night I demoed it on show and tell. I've made a sort of nice basic MIDI tester. So when you're using MIDI for, and I love MIDI, when you're using MIDI for speaking to a synthesizer, you usually want to send things like note on off messages, which is what plays actual different pitches. You want to send CC or controller changes, which is the knobs or sliders on your synth for lots of modulation and parameters and filters and things. And you want to send pitch bend often, which is just to take a tone and warp it one way or another, shift it. And in this project, I actually also wanted to use the bank or preset capabilities of a lot of synthesizers, which is, if you remember, ever playing around with any kind of synthesizer. You're usually going to find a keyboard synthesizer all in one. You'll find there's buttons, like 128 sounds on there. And you can hit buttons to go between piano and maracas and drum kit and xylophone. So those are presets or patches that are often ganged up inside of separate banks of presets and patches. So I want to send a type of message called program change that we'll talk to that. So all of those things I just mentioned, those are built into the MIDI library. So in previous versions of this kind of code, I would have also, so I said, I would have imported keypad, rotary IO, digital IO, Neopixel, MIDI. So now take a look. This is my code here. I'm going to zoom this up a little bit. I've got just two imports that I'm doing, importing Adafruit MacroPad. And I'm importing Rainbow, which gives me the color wheel, which is a really nice convenient quick shorthand for being able to adjust colors. And what I'm going to do is I won't go through all the code right now. I'm going to just talk about a couple things. Then I'm going to give you a demo of how it works. And then we'll come back and look at it in more depth. So in the setup here, you'll see, for example, instead of the normal Neopixel setup where you have to say, how many Neopixels? Which pin it's on? What order of color you're using? I'm just talking to MacroPad.Neopixels right away. I wanted to set a brightness. And I wanted to fill them with a color. And I've already set that color using this key wheel, so this color wheel, rather. So the first thing that happens is it just fires up. There's almost no setup for a lot of these things, which is great. MIDI, I am doing some setup on here, where I'm creating some lists of notes and things like that. And then I'm jumping straight to display. So again, you'll notice I didn't have to import display.io and tell it the width and height, because we already know that. The MacroPad library knows what's on here, so we get to be really succinct about it and just immediately start using this text lines and tell the display to show lines of text. So very quick and easy to do this kind of setup. And then I'm also creating a little sort of state for my encoder position, the rotation of the encoder. And then you'll see, in running the code, just like with keypad, this is using keypad under the hood, I'm saying, OK, a key event is whenever macropad.keys.events get, which is once a cycle, it's going to run through and just check. Is any of these keys being pressed or any of these keys have they been released? And I'll skip over this code for now. We'll come back to it. Same thing with the encoder switch. So pushing the switch, it just uses a part of the MacroPad library to use a debounced switch pressed or released state. Super simple. And same sort of thing with the rotation of the encoder. So the last position here, I'm saying, is that different from macropad.encoder? So that's how easy it is to ask for what's the position of the encoder. And I'll get back to some of the sort of details of that later. But why don't we jump into a little bit of a demo here that I've set up. Let me go and wake up a laptop over here, and I'll do some demos for you. So here's what we've got. I don't know, will that wake it up? No, I've got to. There we go. And let me turn off notifications on this one so it's not bugging us. It might bug us. Do not disturb until tomorrow. That'll work. OK, so I've got a laptop here, and I've just set a little piece of wood on top of it there so I could arrange things under the camera neatly. So you'll see I'm running some synth software. This is the Mog model 15 synth software. So it's sort of an emulation of a classic synthesizer. Let me zoom out a bit so you can see that a little better. And I might focus on the macro pad here. OK, so you can see the synth back there. So macro pad, by the way, I'll show you the code for this. I'm using it upside down. And again, this is kind of a neat thing. Since we have a matrix of keys, which we choose to call the first key, key 1, 2, 3, 4, 5, 6, on down through 12, you'd probably have a bunch of annoying math to do in your code if you wanted to use it in the upside down mode, or that sideways mode, or that sideways mode, because this is sort of considered the natural state of the macro pad. But Katni wrote a little bit of code inside of the macro pad library. It might have been a lot of code, but exposed to us is a really simple thing, which is just rotation equals 0, 90, 180, 270. So I've got this in this 180 mode. And it automatically flips the screen for me, flips the button order for me, so I don't have to change my code. And that's both the buttons and the neopixels. So it just works, which is great. So you see here, I've created some MIDI notes. So it's a chromatic keyboard working from the bottom up. And I have a little output on my display there just telling me which MIDI note number. So that's note 48, 50. And then you'll see here it says Mode Patch 4. So I'm using the fourth patch, which is a preset, a stored arrangement of stuff on the synthesizer. This is what it sounds like. Now watch this. I'm going to turn my little encoder knob here. And you'll see my synth changing back there. So it's just rearranged a whole bunch of patch cables. That's why it's called a patch. And it's also changed a bunch of settings. So quite a different sound. Again, really different sound just by picking a different patch. Now you could do this by clicking in the menu and dragging down. Or you can use, I think, some arrow keys. But this is a really nice, quick way to fly through some patches. So let's go to one that's got a lot of rich harmonics in it. OK, that's a good one. So I picked that one because it has a lot of harmonic content in it, which means we'll be able to hear if I change the filter cutoff frequency of this with a low pass filter. And so what I'll do is I'm going to actually click the encoder wheel, which changes the mode. So right now we're in this patch selection mode. And now what I've switched into is CC mode. So CC mode means that I can use a continuous controller change, which is one of the knobs on here. In fact, let me refocus so we can see the synth a little better. So you see here is this low pass filter fixed control voltage. As I change my knob on the macro pad, you can see the knob on the synthesizer software is changing as well. And here's what it sounds like when we do that. So it sort of muffles the sound, which is what this filter does, is it cuts off the frequencies that we can hear. And then we've also got, if I click this wheel again, we'll go to another mode. And now it says pitch bend. And right now it says zero. So it means the pitch is not being altered from the expected setup that we have. So let me play a little higher note. So you can see I can pitch that up a little bit or down. And this one's polyphonic, meaning we can have two notes at once, which are sort of beating off of each other. And then we can, of course, wrap around back to patch there. So these are the modes, patch, CC, and pitch bend. So I can flip among those. And I can always access these 12 keys to play. So if we can see it's actually kind of playable, you wouldn't, I'm guessing, use this as your primary instrument interface, get a big keyboard of some kind. But it's kind of neat to think of building a little utility like this. In fact, I was inspired, I'm sure. Subconsciously, I'm sure I was inspired by RetroKits, which is a great synth and MIDI gear company out of the Netherlands. They have a DIY project called the RK007, or 007. And it uses a matrix keypad, a little display, a knob. And it's used for sending MIDI, not USB MIDI, but I think it's just for classic MIDI. It'll probably be adapted for both. And it lets you do things like pick different messages like these program change messages, control change messages, changing MIDI channels even, I think. So you could go a pretty long way with this as a sort of diagnostic tool, same with the RK007, this idea of having a little box that just lets you access a lot of different MIDI parameters. So what I'm going to do is actually I'll unplug this from my little laptop here and let's head over to my workstation. We could talk about the code a little bit. And I will take a look at the Discord chat to see if we have any questions. Let me bring that up in fact. So there are gifs. OK, that's good. I like that. Lars thinks he's in space. What is he doing back there? That nutty guy. Hey, Dr. said their Adabox 19 is preparing for shipment. He must have got an email. That's exciting and fun. Got a little elf gif there. Very nice. I'm so excited. Let's see. That was very spooky sounding, yes, for sure. A lot of those Moog patches, I think that's the, I had the pads bank. Actually, that's something I'll talk about. I'm going to jump into a different synth software in a little bit and we'll talk about banks versus patches. So first I'm going to re-plug in my macro pad. Allow that to start up. And by the way, one thing I didn't mention, I'll just show it on here, I mentioned it last night. Remember, I put rainbow in there, the color wheel from rainbow in the libraries. So as I move through the patches, you'll see I'm actually changing the color and I'm going from essentially blue up to purple. So I'm adjusting through about half the color wheel and that's matching up with the number of patches. So the number of patches you can send over MIDI is 128. So I'm basically using 128 degrees of that color wheel just for fun, just to show. And you could get, like I said, really sophisticated with this. You could have, say, colors assigned to particular patches or colors assigned to particular banks. And so there it is, I've got it launched back up. Let's see if other questions we had. Question about rotation, can you change that on the fly? Oh, that's a good question. I'm not sure if that's, if Catney's watching, let us know. Because I just did it in set up, but maybe we can test it if we have time, we'll goof around in there. Let's see, other, oh, Todd answers it. You can change display rotation on the fly, but you'll need to change your graphics layout. It doesn't change the keyboard layout. What does that do then? What does it change, the neopixels? I'm confused. But yeah, when I set it in the initial, creating the macro pad object, it switches the whole thing. In fact, I'll show you that. Let's take a look at that. Let's do that first, in fact. So let's bring back this display, and I'll move our little friendly Circuit Playground Express off to the side there. By the way, you'll notice I've got a sort of different arrangement here of the macro pad back layer. I decided to expose this cool space art here with the Vera Rubin quote. So you can put that on either way. And that looks pretty good. So let's take a look. In the code here, right up at the top, macro pad equals macro pad rotation equals 180. Let's set that to 0. Oh, actually, you know what? Let me reopen the code right off of the macro pad, because I think I made a couple changes that are not shown there. There we go. OK, so this is the actual code running on the device. I'm going to set rotation equals 0 and hit Save. And now we have it right side up, instead of upside down. And it's still going to send the notes from sort of lowest to highest bottom to top. Nothing else will change. I don't have a synth hooked up now, so you won't hear anything. But that's we'll do that. Let's go 90 degrees. I don't know which one's 90 and which one's 270. If it's clockwise or counterclockwise, there we go. It's counterclockwise. Oh, no, it's clockwise. We just made it all the way around 270. So you can see, let me do 90. And after it restarts, there you go. So now that 50, oh wait, did that not work? Oh, that's interesting. Might have found a bug, because that should be the lowest number. But it's acting like that one is. I don't think I tested the sideways button order. So bad me. I should have tested that. But you can see you've got shorter text lines, but more of them. So for some applications, this may be the way you want to go. In fact, I have a project in mind that's going to use that. But for this one, let's jump back to 180. And then let's talk about what else is going on in here. So color wheel I'm setting up. I mentioned setting up the pixels right there. Very simple. The text that I'm creating to display there is a little list, because that changes with each of these button presses we switch out. So again, this is this macro pad display text. Let's you just create lines like 0 through 4 or 0 through 5 in this orientation. I can't remember. And it'll just display those. In fact, you can put a space just by calling this line 2. It'll skip line 1. And then saying lines show pops that up on the display. And so as far as the MIDI events go, or the MIDI sends, when I detect a key event using the macro pad key events get, this uses the keypad library underneath the hood that Dan Halbert created, which is excellent and works on matrix keyboards, one switch per pin keyboards, and shift register keyboards, of which I do not have an example. So I can't try that. But maybe with an old SNES controller, I think that uses a shift register. And then this is the bulk of the code for the key presses is if a key event happens, so if key events pressed, just change the state from not pressed to pressed, I am creating this variable called key, which is the key event key number. So if I press this one, that's going to be 1, 2, 3, 4, 5, 6, and so on. Then macro pad MIDI send, macro pad note on. And then we could send a note. We could send MIDI note 1, which is so low, you probably can't hear it. But instead, I'm going up and grabbing from a little list I made of MIDI notes. And those are correlated to the keys. So remember, actually MIDI note 1 is up at the top. Sorry, the macro pad key is up at the top. I got that backwards a second ago. So this key down here is 10, or what, 10? Yeah, 10, 11, 12. So 10 is this note 48. 11 is this note 49. 12 is this note 50. And then after I press that key, I adjust the key to be green. So you see when I press them, they turn green. Can't see it on the screen as well there. And that's just using 90 on the color wheel. It's this 0 to 255 color wheel. And then I change the line 1 text to say note on, and then using a little of our string formatting to write the note. And that's what gets printed down here, 48, 49, 50, and so on. When I release, here's what we do. We, again, find out what number did that just happen to? Because we can press a bunch of these. So right now, if I want to release a note and have that go from green back to blue, it has to know which one that happens to. And so it'll do it for each of those in turn, because it's aware of which key just got released, which is great. We send the note off command. So these will play as long as they're held. So this sets that note to stop. And then I set the key color back to whatever it was based on our knob turn. And then I print on the little display there that we've released that note. So note off and then the MIDI note. So for the switch that's on the encoder, this push encoder switch, click, click, that's what switches between my modes. And what I'm doing there is, again, using a really nice convenient script that Catney wrote. By the way, Catney is in the chat now over on Discord. So hey, and thank you. And ask her deep, important questions about this stuff. If I've gotten anything wrong, please correct me. So when we press this, we just check for the macro pad dot encoder switch debounced press. So it uses a debouncer. So we don't have to worry about holding it and it runs through a bazillion times doing something. It just has that debouncer state change. It doesn't get ghost hits or multiple hits. And we don't have to do anything complicated in code about that, which is great. So what I'm doing is I have a little, remember our friend Modulo. This was what I showed in the Circuit Python Parsec earlier. Here I'm using it again. So mode is mode plus 1, Modulo 3. So every time I click on this mode thing, it switches its index. So it's going to go 0, 1, 2, 0, 1, 2, 0, 1, 2. Mode can be one of these three things. Sorry, let me scroll up a little. If mode 0, then I'm going to print the mode is whatever that current text mode is, which is when it's 0, it's the patch mode. When it's 1, it's the CC mode. And when it's 2, it's the pitch shift mode or pitch bend mode. And then I print the value. Now, the values that I'm printing here are slightly a lie just because some things are in kind of weird different scalings. Like pitch bend is 16,543 or whatever values. It goes negative 8,000 something and positive 8,000 something. That's just how MIDI works for that. Other things are 0 to 127, but we want to see them 1 to 128 and so on. So I'm messing with the display a little there. And I also want to do some scaling. So with the CCs, I didn't want to have one click of the rotation on the encoder equal 1 CC because then we would have to rotate the thing like 10 times in order to go from minimum to maximum CC. So I'm actually scaling that by about 4, 4.1. And this is just for the display up here right now because that's all clicking does is it changes that display and it changes the value of mode. How we use that happens a little later. By the way, also one other thing happens is there's a little red LED there. You can see it glowing my finger when I press it. So that's a little LED built right onto the macro pad board. And I'm just lighting that up when I press this for fun. And then when I release, all I'm doing is turning that light off. So this released state just lifts that LED off. Then this is how easy it is to check for changes in the encoder rotation. So my last knob position was what we started with when we turned it on or reset it. And then initially, if we go up to the top, that is either I set it to 0 or just to read the encoder. Yeah, so last knob position is whatever the macro pad encoder is at when this starts, which it resets itself to 0. So then what we do is we check and see if that position is different from what the encoder position is, which is this rotation. As soon as I turn this, those two numbers become different, so that is essentially a state change that checks and sees, OK, you're turning it. Now I have a variable called knob position that equals whatever the encoder is at. And then I do some math here to be able to put this into usable ranges and also to essentially limit how high or how low it can go. So we use some min max, which credit where credit is due. Todd Bot helped me figure this out, so thank you, Todd Bot. You can ask him in the chat if you have questions about this in details on this. But you can see it in use, let's see, right here. So the midi values of mode when we're in program change, those can go from 0 to 127. And so this min max midi values mode plus the knob delta from 0 to 127 basically means we'll only allow the knob to register down to 0, even though it can get positions infinitely lower than 0 and infinitely higher in the other direction. Then we send that value. So again, macro pad midi send, macro pad program change midi values and whatever that number is 0 through 127. And then that's what the synthesizer is using to change its presets or its patches. Then I do this color, this key color value is a variable that I change as I turn the knob. And I wanted to start for whatever reason at the cyan, so I added 120 to it at the beginning and I keep that up here. And then we fill the pixels with whatever that color is. So again, that's kind of a slow change. That would be a lot faster if I hooked that to the CC because that one whips through in about a couple turns. So if we switch instead to mode 1, so we go from CC rather from program change to CC, now we do a slightly different scaling. So I'm saying I just want to go from 0 to 31. So I want 32 possible values, which is a subdivision of the 128 that it can actually be, which means I turn the knob four times fewer to get to the top. Or every little click of the encoder goes up by 4 or 4.1, which gets me the full range 0 to 128. And then for pitch bend, we do a similar thing except now it's just the range of 0 to 15 gives me a full range of the pitch bend, which usually is a two-semitone pitch bend. Your synthesizer or your synthesizer software can change that. But usually that 16,384 values equates to two semitones below 0 and to below the root pitch and two above. And then for state detection, we set that last knob position variable to be equal to whatever the encoder is at. So let me look and see if there's any questions before I move on. I'm going to show just a little bit of a demo of some of these MIDI values coming out of here. We'll spy on those. And then we'll look at one other synth thing that I wanted to show you. It's super cool. Let's see. Todd says, rotation of keys and LEDs and displays is super handy because people have different needs about where USB cable should come out of device. This is true. You might want a 4 by 3 instead of a 3 by 4. I actually kind of like this having for this, which is kind of a handheld. I imagine this is a handheld thing. I like having this little display down at the bottom like that. It's kind of nice. This is the more typical on your desk display where you can see the screen up on the top. And oh, doctor asks if there's an I squared C slider board because that could go on the side with 3D printed brackets. So do we have, I don't know if we have a slide potentiometer with I squared C yet. We just have the Trinkie that's a USB. So we don't have a ready-made solution, but you could probably do that with an I squared C ADAC analog to digital converter and then plug a potentiometer into that. Meridian Prime is showing a cool 303 acid synth. Awesome. And let's jump into taking a look at some of these MIDI messages. So I'm going to launch my little MIDI monitor program here. And I got to share this, sorry. I forgot to set this little guy up and share it earlier. How about just add a screen if you'll bear with me. This might make my broadcast glitch. So sorry if it does that. Add a screen. And now we wait. Promise it's thinking. There we go. Switch that to a window and MIDI monitor. There we go. OK, so this is now just spying on the outgoing USB MIDI messages. So if you see here when I press this first note, this first key, my display on the MacroPads says I've sent note on for 48. And you can see there in the MIDI monitor. Yeah, sure enough, note on over channel one for note 48. And it also is telling me that we have a velocity of 120. Now we also get this extra byte, which is just a bug that's being worked on in our USB for all the USB MIDI stuff on our devices. There's just a bug right now. And then when I release this, you're going to see it's going to send a note off message. So note on and then I release note off. And I'll clear this just to make the display neater. I don't think I can zoom this, unfortunately, can I? No. You'll see if I press another note, like note 56 here, then I can release either and either. So that's how that MacroPad pressed and released from the keypad library works, which is terrific. Now, oh yeah, you know what? Someone just said zoom enhance. Well, I can do zoom enhance because I'm not going to show too many messages. So let's allow me to zoom enhance. There we go. So now you can see when I click the encoder to patch and I rotate, I get a program on channel one and the data is sending a 127. So that means I was all the way cranked up at the top. So as I scroll this back, I'm going through every possible of the 127 possible patches that we can send. So now I'm going to clear that. Now I'm at the bottom, the very first patch, one, two, three, four, and so on. You could, of course, set this to send over a different MIDI channel if you had a reason to. You could have MIDI channel selection be part of the UI on here. You could have MIDI bank selection be part of the UI. You could have which CC number you're sending be part of the UI. So it's all things that you could code on here pretty readily, I think. So I'm going to switch to the CC mode here and you'll see as I turn this, I'm sending on MIDI CC number 74, which is often a filter frequency. You can assign it in your synth software for whatever you want. And then it jumps up by four every time I turn one notch of this encoder. And that's because I just didn't want to be turning forever. So if we start at the bottom here and I go, that's basically a half turn that gets me to 36, another half turn 65, another half turn 94, another half turn. So it's about two full turns will get me all the way up there or a little crank, a little half turns. All right, so let me close. Oh, I won't close that. Let me just hide that. Last thing I wanted to do is just kind of share a pretty cool synth that you can get your hands on for free. That Moog synth, I think, might be $15 or $30 right now. Sometimes it's free. It went for free back in April, I think. But here's a really cool app. In fact, I'm going to jump to my browser. And this is a free synthesizer that is near and dear to many people's hearts because it is an emulation or a simulation of the realistic or Radio Shack brand MG1, which if you look at it, that's the Wikipedia page on the MG1. It was called the Concert Mate MG1 as well. And Radio Shack had a line of synthesizers in this Concert Mate series. But this is the only one of them that was actually manufactured by Moog. So it was at the time a $500 synth that came out in 1981. And it is not the same as any particular Moog, but it has a lot of the same characteristics as some of the Moog synths of the era, just with a couple of differences. But it's a really neat synth, really fat sounding. And this is the Cherry Audio. It's a synth company. They make this software synth that is currently free. I don't know if they have plans on selling it again because they say now free. And then down here it says $25 and that's crossed out free. So I recommend this one because it's got a ton of presets in it. It's got, I think, 128 presets in it that we can scroll through with our knob there. It actually does polyphony. So you can hold down multiple notes at once, which is somewhat accurate to the original. It had, I think, two oscillators and then this polyphony third oscillator. And I think it allowed you to play more than the three notes, though. So I can't remember if that's para-phonic rather than actually polyphonic. But you can get multiple notes at once, which is kind of cool. And it allows you to assign CC to change things on it. So what I'll do actually, I'm going to jump back over there. I don't have it installed on this machine, I don't think. But I'll jump over there and show you running through its presets because unlike that Moog synth which thinks in terms of banks, this one instead just has one long list of presets. So you can scrub through all 127 of them, no problem. Let me just get a USB adapter here. Let's re-launch. I'm going to quit that one, and load this one here. There we go. And I think I can just scale that. That's nice and big. Whoa. So if you're wondering about, I'll turn the output to my amplifier. Hold on one second. Audio and MIDI, audio through headphones. There we go. So in the software, you'll see there's a big list. If I set it to all presets, these are the bazillion presets and you can go through and pick them by name, which is cool. But again, that's the big list that we're switching when we use our MacroPads patch. You can do things. A lot of these have detunings among the three oscillators so they can get pretty raunchy sounding, which may be what you're after. I don't judge. I'll set this back here. So again, this will work. Let's find a nicer patch. I like that. So you can see here, this is that filter. Again, I've assigned this MIDI number 74 to drive that knob. And like I said, you could in here code something where you get to pick CC numbers, which is then assignable to pretty much anything in here. So you could go through one at a time and play things. In reality, you'd probably want a box with 8 or 16 rotary encoders on it to do lots of hardware style changes on the fly. But this is fun for testing for sure. And then pitch bend will work as well. So that's the MG1 based on that Radio Shack Realistic Slash Mogue synth, which is super cool. And apparently, one of the more common ones to find, just because they were cheaper than mugs, so they sold a lot of them or sold at Radio Shack. So you can still find them. They, I think, usually run around $700 to $1,000 in the used market for one that's a little grungy. But it's been a while since I looked. I don't have one. I wish I did. All right, so I think that's going to do for today. Let me jump back over to the work bench there, workstation, and see if anyone's got any other thoughts and questions before we sign off. Hi, Dave Odessa, who said they were late. Sorry, you were late. Let's jump over to Discord so I can see it there. More rotaries, yes, in fact. Oh yeah, Meridian Prime said that there was a 303 clone that Lady Aida made about 12 years ago called the Zoxbox, X-O-X box, so instead of 808 or 303 or 909, it was X-O-X. It was based on the 303. Hard to find them now. I have a PCB for it, but a lot of the parts are hard to find, so I've never built it, maybe one day. Doctor said something I didn't catch is the macro pad sending the MIDI instructions directly or is there software bridge? It is direct. So USB MIDI flies right into the software. You don't have to do anything in the middle. I was using that monitoring program just to look at it, but this will work also for hardware synthesizers that have a USB MIDI host built into them. So you'll see I've often used this 1010 music blue box, a little sample station. That has a USB host MIDI port, so you could plug something like this into it and then use its own setup to say what influences what, as you turn knobs and press buttons. Let's see. Oh, and Todd answered that question. Thank you. So I'm behind the curve by a couple minutes here. Oh, you can still get the Xoxbox synth kit PCB set. I didn't, I realized that. Check it out. Yeah, here it is. That is, that's the Xox kit. It costs $3.03. Oh, $3.03 is four of them. So if you're thinking about doing it, it is an intense build with a lot of hard to find parts, but people dig them. There's a whole world of people using those out there. Let's see, other discord happenings. Oh, Steve has one. You've got a Xoxbox right there. That's cool. I don't have any 303 type of synths. They've got that syrupy, drippy, filter-y acid sound. Doctor said Cherry synths requires an account. Okay, good to know. So you will need to have an account in order to get the free synth. Dexter says JP has all the cool tools. Man, that's a free synth. I don't have the real one. Oh, Steve's got a picture in the discord there of that lovely build of the Xoxbox. Maybe you could bring that on show and tell some time and play it for people. It's been a while since anyone's heard those. All right, I think that's gonna do it. So hey, thanks so much for stopping by today. And thanks again to the whole CircuitPython team and Dan Halbert in particular for the Keyswitch library and Katny for the MacroPad library, which is making life so easy for coding this kind of stuff on the MacroPad. Love it. And thanks also to Todd for help with that MinMac stuff for rearranging my values there. I wanted to see if I could do that without importing extra libraries. And I think that's gonna do it. And thank you, the viewer for stopping by today and hanging out and coming into the chat. And so please remember, we will have a AidaBox unboxing coming up not next Wednesday, but the one after that. So that's the 28th of July. And that'll be at the normal Ask an Engineer time slot, which I'm not gonna say, because I always forget by like an hour. I think it's at 8 p.m. Eastern though. If anyone knows in the chat, let me know. Hey, Minnesota Mentat, thank you also. And next Tuesday, I'll have another JP's product pick of the week. I probably won't be dressed up like a cat. But you will probably get a great discount on a cool thing, so why not come and check it out. And that'll do it. So I believe there's gonna be a deep dive with Scott tomorrow at five o'clock Eastern time, so please stop by. And then we have a bunch of other happenings going on with different people going on podcasts and hack chats and things like that, Haxter and all kinds of things. So check our blog, because that's the best place to find out about it, or ask people in the Discord, what's going on, what's happening? All right, so that's gonna do it. Freighted Fruit Industries, I'm John Park, and I will see you next week. Bye-bye.