 Well, that's Lady Aida. Hey everybody and welcome to my desk. It's me Lady Aida with me Mr. Lady Aida on camera control behind the scenes and we're checking on what I've done at my desk this week. It's a long weekend which means I can do even more but let's see what I've gotten to so far. What trouble I've been brewing. What is on your desk this week? Okay so first up as you can see on my screen I am working on the easy link revision using the ESP32 that's one of the prototypes I put together I think I gave Mr. Lady Aida time-lapse that you will post later about that and basically replacing the CSR chipset module which we like couldn't get anymore and it was just kind of like a big gross mess with ESP32 which has classic Bluetooth. You know, TAC who does a lot of Bluetooth work for us figure out how to basically get SPP which is the serial protocol in classic Bluetooth to work on the ESP32 with flow control and baud rate changes and that's really important because a lot of Bluetooth SPP examples are they don't use flow control like you know it's RX, TX only there's no RTS, DTR, CTS, CTS whatever and secondly they often don't let you dynamically change the baud rate like whatever the baud rate is when you like you they're fixed to 9600 or they're fixed to 5700 or whatever what's really cool is that this module has baud rate changes and the flow control so let's go to the overhead real fast now I'll shut off in situ so this is the module so unplug this and this is the assembled version so I've got here the ESP32 Pico and I've got you know the nice thing is of course it's ESP32 and we're programming it in Arduino so it's like I'm not programming it in the CSR IDE which is like kind of like a total nightmare so you know there's a Neopixel over here in LEDs and the boot zero button is actually also the pair button because that way if you want to reprogram this board you know you hold this down while powering it to enter bootloader mode I still got the regulator and capacitors and you know probably uses a little bit more power the battery on the back if you want to power the whole thing but otherwise we made it pin compatible and I loaded it up and it works great so it's nice is that you know in addition to power ground RX and TX here we also if you see DTR and DSR so there are two control flow signals and even you know a lot of times you like people don't use hardware flow control but instead those are used for like auto reset so the ESP32 and Arduino Uno are in particular use those signals to kick the board into bootloader reset mode in order to upload code that's kind of traditionally how the Arduino works is the DTR pin is connected through a capacitor to reset when it toggles it you know passes that current through the capacitor the AC current through capacitor reset line toggles and kicks it into bootloader mode that's the auto reset which I thought was like essential because that's if you want to like we program or communicate wirelessly to like an Arduino Uno you really want to have those control lines so let me put this back loose I'm gonna get the wires lined up so red LED means it's ready to connect SPP Bluetooth you know basically when you open the port it turns blue and I actually kind of I wasn't going to do it but I can over here on my computer I connected I opened the COM port now turns blue and when I close the COM port it turns red again so so basically what's interesting about SPP is again different than Bluetooth though energy is on a computer it looks like a serial port so let's go to the computer and I can show that off so you know what happens is that you know on Windows particular we tested this that the flow control don't work on Mac but it does show up as a COM port serial port on Mac Windows and Linux there's actually some bug in Mac OS and like unsurprisingly it's so rare for people to use Bluetooth SPP with flow control even though it's in the spec almost nobody uses it we're like we're we're using something that's actually there but again you know Mac OS doesn't support it but Windows does and it shows up as a paired device it looks like a phone because it's like what do I know and then it actually creates device manager to serial port over Bluetooth links now I don't know why there's two but basically you only use the second one the first one doesn't actually exist I don't know what it is some like weird placeholder but again SPP is like super freaky and weird it's really it was used by Nokia phones like in like the mid 90s and the kind of hand that hasn't been used yet it's used since that said it's always built into operating systems so then you know if you have your you know this is like a neopixel demo and I select that COM port 31 and let's try this out I'll try uploading you know because we're passing through that serial control line it should auto reset the Arduino and perform the upload pattern and if you have RTS and DTR you can upload to an ESP32 it uses two control lines only thing is because I opened and closed that port it might be a little it might be a little upset maybe I'll do a hard reset here okay let me while I can show another demo I'm still still working on the Bluetooth stuff so on the other side we've got the Pico W which we've been doing work on Jepler has been solely but surely adding support for the Broadcom God was it like the CS4343 I don't remember the the part number that provides the wireless and Bluetooth on the Pico W and there's a micro Python driver and there's a Pico SDK driver which is used in Arduino but we wanted to add it to circuit Python because we've got Bluetooth and sorry we got IoT and Wi-Fi drivers and art you know a different IO we wanted to get this working so so far the status is we can you know get the MAC address from the Wi-Fi and we can scan for networks so there's a lot of repeats in the networks and that's I think that's normal there's a couple of pizza you'll see like the same ones show up multiple times it doesn't do like a uniqueness filter and then we can connect to Wi-Fi and get an IP address which is like which is done by like the underlying firmware it's like we haven't actually touched the TCP IP stack yet like just getting an IP address like it's even though IP is part of TCP IP we're not actually touching the stack quite yet so that's good news so the next steps for this is to add LWIP which is the again TCP IP stack that's used this is different than you know using Air Lift with the ESP32 where like the TLS and the SSL stuff and the TCP IP stuff is all kind of managed on that chip that the 4343 that the Wi-Fi module like it really only provides like the underlying like internet like the lowest level of communication and for stuff like security you have to add on top of that the thing that's going to be a little interesting is all that is going to take up a lot of RAM and flash it's gonna be interesting to see how much is left especially on the Pico W which only has two megabytes of flash we're probably gonna have to shrink the file system in order to make room for the the TLS stack in particular okay so let me close that alright so the next thing is speaking of flow control it's been a flow control weekend I wanted to see if this works this time oh yeah that's working I think I just have to restart Arduino okay so let's go to the human going to the overhead so I'm gonna open up this neopixel example and I'm going to upload it and then I'll show you the you can see we'll see you the activity LEDs as well just give it a second to upload okay so it connected and now it's you know communicating that's the RTX TX LED and then it uploaded the neopixel sketch so yeah basically don't I opened the port and I shouldn't have done that probably got a little bit confused but it does work it works pretty fast so I want to do a little bit more testing and I also want to update the module because I used a Pico O2 module here which has 8 megabytes of flash and 2 megabytes of ps4m which is kind of overkill like it's what I had handy because I've been using it in the Feather v2 but as I'll show in the great search it's a little bit more expensive and I want to say you know I want to basically make this as inexpensive as possible if I don't use the ps4m because I don't need it I'm not gonna use it okay so kicking back pop in the stack the CH sorry the CP 2104N I've been replacing this with this CH 9102F from WCH it's using the old PCB but it's actually the WCH chip and what I've been designing the tester for this like the board worked and I was like yay and then when I designed the tester part of the test procedure is I connect the flow control lines across with each other and I use that to verify that they toggle because it's a good way to just you know I test RX and TX against each other and then I want to test that I think I test DTR connected to CTS and RTS connected to DSR and basically like I cross connect them and I toggle the pins and make sure that they are connected back and forth but I was actually having a lot of problems with CTS the CTS line wasn't reading every other pin was reading except for CTS but I knew it was working because I would test it on my Windows machine and it was working turns out that the Linux driver for did that family of USB serial chips has a bug in it and the CTS line doesn't work so it's kind of more like an FYI if anyone there is replacing their chips with the CH9102F and you're like why is it my flow control working why is the CTS working it's a Linux kernel bug so let's go to the computer I'll show you how to fix it real fast these are just my notes you will have to compile an out-of-tree driver but not a big deal just apt-get install that kernel headers here and that's you know you'll have to do it for each Linux kernel update if you update the kernel of course you'll have to redo this and then this person who works for WCH I'm almost positive because they wrote a bunch of other drivers they have a new driver that they updated three months ago and this is note a fork of the official driver and they did a PR but didn't get pulled blah blah but you upload this and this you can insmod the CH3343 which is that whole family of USB serial chips and CTS will work you have to remove the old CDC ACM module by the way so don't forget to do that so unload the CACM mod probe the CH343 and it you know comes up as a new name and CTS works you know again a lot people don't use that CTS line like flow controls and that popular but I know somebody out there is like using that you know they want to use this chip or this family of chips and and just FYI if you're having that issue it's not you and it's not your hardware so check out this repo and compile the out-of-tree kernel module and I mean ideally this would get back into mainline but WCH doesn't seem to be interested in doing that so that's that all right so that's my whirlwind tour of what's on my desk so any questions before we go into no that's a good search a great search let's do it the great search brought to you by digikey and a deferent thank you digikey every single way gladiades or powers of engineering to help you find the things you need later what are you looking for on digikey.com this week okay I'm actually doing a twofer because I have two modules that I want to swap around that use the ESP32 so one of them went in a line so let's go to that first let's go to the computer and talk about this module that so we use the ESP32 for a bunch of things including this airlift technique which Arduino came up with originally where you load firmware onto the ESP32 and then it becomes an SPI client and then you can use that as a Wi-Fi chip set really great when you have something like you know RP2040 or an ATmega chip something you want or you know an R52 you want to add Wi-Fi as a co-processor you'd use something like this so the good news is that you know historically you know we've used the classic ESP room it's this like kind of chunky but very serviceable module from Expressif it's very inexpensive it uses the ESP32 four megabytes of flash no PS RAM but has a built-in antenna and it's like it's solid like it's it's like a beast right this isn't everything so we have the shield and we have the feather wing all the feather wings a little bit of a tight fit you doesn't work and then for the itsy-bitsy we use this u-blox module u-blox Nina which I which is again also used by Arduino on their like nano connector nano Wi-Fi boards and what's nice is that it's extremely compact okay but you know what I'm about to say so the problem is that this module I just kind of noticed like last week that it is under last time by this is the one I think I'm using yeah so they still have a bunch in stock but it's last time by which means I can put in one last order but they're no longer to be making this so you know thanks for the warning and it is in stock which is better again better than a lot of chips that we've we've dealt with in the last two years where we get a last time by and I like but we don't know when we're gonna get them to you so you know I'm gonna pick up a couple just to kind of ease ease the transition but I have to refine a replacement for this and I wanted to fit on that itsy-bitsy wing which is very small and then likewise I've got the easy link I can we go to the overhead real fast I'll show this again I've got this easy link board and when I put this together I use the ESP 32 Pico module which is an ESP 32 with 8 megabytes of flash 2 megabytes of ps ram and it's extremely compact but it's a little bit more expensive and I'll show I'll show the pricing differences for all these so basically want to find you know I'm like doing two things one I want to find what's the best module to replace that itsy-bitsy wing with the Nina W10 series that's end of line so a very compact module maybe it's this one and I also want to find a replacement for this module that maybe is a little bit less expensive because I don't need 8 megabytes of flash in the ps ram so in second I'm gonna just quickly open up something on my computer and then we'll switch over ask a question ask a question well the ESP 32 C3 support ESP SPI it doesn't yet sorry I'm good distracted on bluetooth easy link okay so now I'm going to open up both files we can look at them okay so let's go back to the computer top open up the T docu okay so this is the ESP easy link so the one thing is is that I really want to keep the width of the board the same because I'm trying to match the original easy link which was longer but it had this nice width I want to make it pin compatible because it's you know very easy to swap it out and again this module was let's see if I can open the V2 this is the version using the original this is the original module using the CSR chipsets we turn on to docu so you can see it's extremely long but extremely skinny so it's like it you know it did kind of just keep going keep going but it was many stories but it's nice and compact so I did like that when I did this transition this is a little bit squatter but has that same footprint and then likewise cheating I'm showing the head but this is the itsy-bitsy wing and you can see how skinny that Nina W is I mean has to fit between these two I think you know point six this is five yeah this is point six inches apart so it's you know the size of a large dip chip so you know this one again don't need a lot of for neither of them we don't need a lot of PS RAM or RAM or flash two or four megabytes is gonna be okay we don't need PS RAM of course I'm always interested in going with the lowest cost part available I do want to build an antenna I don't necessarily need a UFL antenna option but like sure later if you know if that's available but obviously like most people want to build an antenna and to do this I actually recommend going with the ESP product selector now did you key has all the parts in stock but the ESP product selector is just a little bit more specialized again for those ESP modules and I found this is a good way to kind of see the lay of the land and then I go to you know of course you can't buy from Espresso directly you go to the distributor go did you key so let's let's start now okay so for what I want so I definitely want Wi-Fi I do not want well I want Bluetooth classic for that one board which means I have to use for the easy link I have to use the ESP 32 again for the it's a bit see I don't need Bluetooth however right now the airlift code only works on the classic ESP 32 so we're gonna use only the classic ESP 32 I can't use the 8266 no classic ditto for the S2 C3 S3 and C2 so that reduces the list down to 72 pieces next up system on a chip or module I want the module cuz I want it to be like the FCC stamped and everything tinned and ready to go I want to just place it so I'm gonna go the module status you know I want mass production core I don't really care if it's single or dual core antenna I do want it built in I want to be PCB antenna I pex is the pluggable antenna okay so let's see what we've got here I can't quite reduce that this is unhideable that's okay okay so we've got all these modules down here and the thing that's most important to me is size so I'm going to search by size and moving up and then you can see there's a couple options with PS RAM and you know all them are gonna have some different flash different PS RAM living to notice they all certainly have different GPIO availability so just keep in mind all the modules that are available for the ESP like each time you change package like there's four pins that swap in and out so just be aware like GPIO like 10 and 15 that 10 17 18 19 20 those those numbers tend to kind of flip around okay so these are all in production and let's look at the sizes so the Pico is definitely the smallest it's got a 13 millimeter by 16 millimeter size whereas the mini remember there's a Pico mini and there's the mini the Pico mini is 16 millimeters 17 millimeters tall the mini one is 19 millimeters tall so for visualization I've actually started I started adding these here so this is the you blocks which is actually the smallest by far you can see they they're they're really good at making extremely compact designs they put the pads on the bottom they use like BGA parts I don't know what they did I never incapped it but it's extremely compact this is the Pico which is again 17 millimeters tall and this is the mini note that they're not you know they're this is the same width but it's taller it actually has the same number of pins basically it's just like a little stretched out so this one the chip inside the chip that's in it ESP 32 Pico chip has the PS RAM and flash all on one die I think the mini has maybe the flash is separated or something it's like it's a little separated and then this is the room which definitely has the flash and then a spot for memory separates this is kind of the end uses SOIC flash so they tend to get less expensive as you get bigger because you don't have to have as tight integration but of course they're bigger although they all pretty much have the same RF performance within reason so that the thing about this is you know this is the itsy-bitsy wing turn off the bottom layer and the you know really nothing beats this you blocks nano I could fit the Pico you know it would be a tight fit but it would fit right there in the middle and then this would fit too it's the same width but I have to really start squishing all the parts back maybe go with a double-sided design so this is a little bit tougher we'll look at the price differences for these so if I go to did you can I look for ESP 32 and then I want transceivers and modems I only want the active ones and I only want ones that are using the ESP 32 chip set not the s2 not the s3 there are a couple different variations of the ESP 32 and I want it from a stress if I'm gonna use the expressive modules again you blocks are discontinued and I want it to be a module I want antenna included trace antenna I don't want the IPEX or UFL okay so and then is there a way to get just the modules I don't know if the modules are well this is module that's not really module I'm gonna stick with this so if you search by price if you sort by price the mini module is is kind of the least expensive it's about 250 in quantity and then there's a version that has the UFL antenna if you like there's the H4 version this is the same but a little bit earlier so it's it's not recommended I believe it's it's kind of not end of line but it's like slowly being discontinued and then the room is actually a little bit more expensive so it turns out it's actually cheaper for me to go with the mini module the Pico is all the way down here is more expensive it's $4 in quantity and it's more expensive because it's got that PSRAM in it and it's got double the flash all things being equal you're always gonna pay more from well you tend to pay more for more integration in this case it's interesting it's actually less expensive but you're definitely gonna pay more for flash and PSRAM like those those cost 50 cents no matter what so it's not surprising that double it and you know your price basically goes up a $1.50 per but the mini module is actually kind of like you know very affordable here it's it's it's inexpensive it's 250 and there's a version with and without the antenna so you know I think if I can you know it's it might actually be worth it for a $1.50 to move from this U blocks to this module that's $2.50 and maybe even go double-sided you know going double-sided is or like going to much smaller components is always a little bit of a risk but if you can save $1.50 on your build material costs and you know your process only ends up being a dollar more it might be worth it and then of course the room will like totally not fit so you know I have that choice so I when I when I do my sizing for modules I like to pick out between them and then likewise for the easy link let's see I can I can show some sizing differences so ESP32 and then I have these all in my library all the mini sizes so this is the Pico and then the mini which would just be a little taller it wouldn't make the size any wider and I'm okay with making the board a little taller as well and then one side note is in case you're curious the ESP32 C3 mini is actually the same size as the ESP32 Pico so if you would like to if it is possible you use the C3 I don't have it here if you would like to use the C3 though in the product selector you can oh no sorry yeah in the product selector the Pico mini is 13 by 13 millimeters wide by 16 millimeters tall if we change chipsets to be the C3 the C3 mini is likewise 13 by 16 so so the words Pico and mini just be aware they don't always mean exactly the same thing between chipsets that was surprising to me when I saw that the C3 mini is the same size as the ESP32 Pico but again I can't use the C3 at this time so I'm going to go with the mini one and four there's lots in stock they're 250 a piece they'll do the job well it's actually a little cheaper than the room module it's got a built-in antenna and it will fit in both of the boards that I'm designing for that's a great search okay tune in this week for all our shows and more show and tell this week is hosted by Melissa we'll be doing asking an engineer on Tuesday JP's product pick of the week on Wednesday 3D King ounce with no Pedro Thursday JP's workshop Friday deep dive with Tim and with this we went to Little Island it's a park not too far from here and I saw a friend of mine who happens to use LEDs it was daytime so you're not going to see LEDs in this particular demonstration yeah but uses LEDs in this big wheel and he's and he does this wheel art where he's inside of a big wheel but since it's daytime you'll just see his form of art here that's what we're playing out with see y'all next week all right see everybody