Hello everyone. If you're watching this after the fact make sure and check the description below for time codes to Shift between the video. These deep dives tend to be about two hours. So you're gonna want to You may want to take a look at what we talk about there And my graphics driver is not super happy with me We're gonna take a few minutes to get going here while I turn everything off and arrange my windows Say hi in the chats. Mr. Schoenley says hi Got some exciting stuff. Hopefully I won't Hopefully I won't show my phone password. I spent the last week trying to remember a new one Hi, Piata Hi, Bruce. Hi Dave. Oh, yeah, we're a little early. Aren't we? Spooks all curled up That's the overhead has a warm weather, but today's cooler and the windows open still so he's a all tucked in Bruce says I never remember passwords if I lose last pass. I'm dead. Yeah Hey, King or North Hi, Olympia Hi, I'm expected maker Hi flying Dutchman. I should say now as a reminder Next two weeks next two weeks will not there will be no deep dive because I am Not working. I am going to visit family Yeah, looks like it'll be rainy this weekend. I have to clean out this closet. So it It might be good Might be good to do that Spooks all asleep He got some pets earlier Oh Hello, can you hear me? Yeah? I don't I don't think you can actually watch my video. It hasn't worked before I should figure that out Can folks here JP? Hello? Hello? Talking maybe but I'm gonna check my settings because who knows what? Settings I have her voice and video. Okay. Yeah looks like reasonable Oh, I'm in the wrong channel. Haha. I wasn't in the live broadcast yet. I gotta say hi to Oh dear I popped your video out and it's not working anymore say Is that my problem or your problem? I Can hear you. Okay. That's a start That's what I'm seeing Let's see little boxes. Hi, Minnesota Menta. Hi read us Hi Keith II. Hi Gary. Hi Mark Hello Hmm, I popped you out and You can turn my camera off It doesn't work if I pop you out, but it does work Cool If you're not popped out I need to pop out. It should be okay Reload That didn't work. Well, I guess you could just be this tiny person in the yeah I'm happy with that or you know what I could just make it bigger Here's what I'll do. I'll just move you here And do the same thing well there. That's better Yeah, all right. I haven't done housekeeping yet. So I should do that first and Discord folks, I won't be able to see your chat Unfortunately got it. No problem Talking more than typing Yeah, so Yeah, sorry. I have to watch JP here instead of although I guess I could pop you down to the bottom right hand corner Too many windows man Too many windows man sounds like a documentary about live streaming. I know right I have returned hot doctors here Okay, um I do try to take time codes as well I'm excited to chat with you JP though. So I'll try not to take too much of your time either though Hey, no problem You do housekeeping and then I want to do it. Can I do a snack recommendations segment? Sure This is a very chill stream as you know Excellent. We take lots of time to hang out. We've got some exciting stuff though Some exciting stuff to show okay Hello everyone, I'm down in the corner today, but my name is Scott and I work on Circuit Python for Adafruit Adafruit is an open-source hardware and software company based out of New York City I live in Seattle and work in Seattle. So I work remotely for them Circuit Python is a really easy to use programming language called Python on microcontrollers, which are these little tiny Computers that are just in about everything. They're really inexpensive and they're really fun to get going They can make the world do things which is really exciting So if you want to support me and John Park who's in the Discord here with me as well. We both work for Adafruit You can go to Adafruit.com and purchase hardware from them and then they pay us to make all this great content and software so Please support them. If you want to chat with me and John Park and a whole bunch of other folks You can join us on the Adafruit Discord server by going to the URL Adafru.it We're happy to see folks there Deep dyes happen every week except for the next well at least except for the next two weeks I'm going on vacation. So this is the last one for a little while It's normally Fridays at 2 p.m. Pacific, but occasionally shifted to Thursdays if it's a Friday off Typically it goes for two hours or more questions are welcome We're gonna talk with JP first, but then I'll answer questions after that Are we if he wants to stick around we can answer questions there as well But yeah, no deep dive for the next two weeks. I'll say it again Last piece of housekeeping is Spook who's the cat in the where I was showing earlier He is epileptic which means from time to time. He does have a seizure if I if he does I'm just gonna have to make sure that he's okay He's always been okay, but I just want to make sure he doesn't get hung up or anything It's just a heads up if I'm on stream, but not doing anything. That's that would be why and That's housekeeping so I put in the note stock maybe special guest JP because I don't necessarily like I Don't necessarily like to Like compel my guests to join So I kind of keep it secret which I guess is Not necessarily good for you because maybe people who would come and see it won't actually see it. No worries. It's fine casual Exactly. Yes. Yeah, it just Some people know I just finished streaming about 15 minutes ago mostly a stream about some 3d modeling design I did for a couple different macro keypad types of projects and Gigant work key project And and maybe we can talk about some of that stuff if you're interested but before I do that I'm hungry. So I have a snack recommendation and a beverage recommendation. So My snack recommendation is Trader Joe's synergistically seasoned popcorn and it is Tangy salty smoky and spicy And it's kind of it tastes kind of like chili powdery Barbecuey tangy citrusy like limey kind of something like that. I don't know what they actually claim to put in here but hmm, I really like it and No one else in our house does so I get it all to myself yet Olympia is asking is it vegan? Let's see I don't see any claims about No other than kosher I don't see anything gluten-free and kosher so which is important. My wife has celiac. So Free is pretty typical for our snacks It makes sense why you're doing popcorn then. Yes. Yeah, we do rather than a like flour chip sort of thing Yeah, yeah, not pretzels that kind of stuff So popcorn sunflower oil sugar white vinegar powder sea salt yeast extract cayenne pepper garlic powder citric acid rosemary extract paprika extract rice flour natural smoke flavor and turmeric May contain trace on milk almond coconut macadamia nut. So It's delicious and that's my snack Recommendation so do you ever watch? Bon appetit videos because you totally just gave me that moment. Well, that's funny. I haven't like So one of their hosts Claire Saffitz did this show where she tried to reproduce Like snacks you buy at the grocery store, but using like gourmet ingredients it gourmet makes I think it's the name of it and she would always have this like she would read the ingredients list and The editor of the video would put all of the words that she was saying as she was saying it until the screen was fall And I you just reading off the ingredients list like totally gave me that memo That's funny If for some reason growing up my dad was really big on reading ingredients, even if they were like sir, like, you know, yeah Polysorbate 80 and like crappy ice cream. So he just like loved reading ingredient lists. So I have I have some Some of that innate It's a good thing to do I think like you can tell like the things that have a lot of like food science Processes versus the things that are just like like if you ever go like I remember reading like the list for Puff pastry at the in the frozen aisle, right? It's like the most expensive puff pastry you read the ingredients at least and it's like flour and butter Versus like the more shelf-stable ones will have a whole long list of things instead. Yeah, and boy butter is expensive So if you see if you yeah, if you look you ever make real pastry like oh my god It's expensive eight sticks of butter later, right, right? So Dave was asking what time difference between you and I and we're both in the same time zone. That's right Yeah, we're on the west coast of the United States. So yeah, no different. Yeah exactly and then I Have a beer recommendation. I don't know if that's a age-appropriate for everyone on our show, but this is Los Angeles Los Angeles ale works they call it salt Bay, but they spell Bay like your girlfriend or boyfriend And it's a pilsner and I'm usually you know, I love IPA's I'm in California or IPA's really tend to to be the most popular ones made and consumed here But boy, it's hot now. So this is a nice one. It's a it's pilsner And I don't usually like things beers that like actually add other things as flavors to them Yeah, I don't hate it, but it could be heavy-handed like a sandy Yeah, it's and and ones where they like say okay This is gonna be like peanut butter stout and they've literally put peanut butter in it. I like those I like peanut butter stuff. They can be good or they can be like real real artificially and terrible So so I'm I'm cautious with them, but this one has a sea salt lime And then Hallertower and saws hops, but the sea salt lime is really subtly done It's not doesn't taste like just like citric acid powder, you know, right, right Um, so this one is and it's fairly low a bv because Again with these California IPA's it's like high 9% alcohol and it's a pint. Oh, yeah, this was more Little under six. So at least nice Some session ability to it. Awesome. Well, you're taking this like Friday afternoon thing like full-born here I feel like I should have grabbed a drink, but I do I'll choose it with my water glass here And I do like people probably may not notice but I do like these pint glasses are all like different beers So that I think what is this one? D-Railer ale.  I don't think you got it. Is it your is it your family crest? It is not but it's just family looking Awesome, well, uh You know when I offered to have you on I was assuming that would be an easier way So you wouldn't have to do show beforehand Oh, and then it turned out that you did both and I saw I was like that's why I was like No, you don't have to come on the show unless you have some stuff left in the tank But it did it does remind me just chatting with you like when I actually visited I folks that haven't seen it. I actually did the visit John at his house at his shop here and had a good time and So I you know, I I'd like to keep it casual and One thing I thought would be interesting to talk about since you and I have just chatted is the parsec stuff Yeah, the circuit python parsecs like you've you kind of do these style of videos, right? That are really short and just like we're super concise Colin's doing these right now, too but I wondered like as You're getting like you've been doing circuit Python for a long time like by virtue of like I think you joined Ada for like just a few months before I did right and so you've seen circuit Python evolve and and I Think the parsecs are like just getting you more and more into it How? How's it going? It's going well. So so the like my evolution in coding on microcontrollers is like like a lot of people started on Arduino and Excuse me. I'm not a Coder by training. So I I was coming into Arduino mostly from scripting inside of computer animation software. So I for most of my professional career used a software called Maya that has a very C-like scripting language inside it and nowadays It's actually been overtaken by Python Internally to the program and they both kind of exist, but So Arduino was pretty Good fit for me coming from Mel, which was the name of this Maya embedded language. This this electric right and so Then I spent a number of years doing projects in Arduino And then right I want to say right around the time That circuit Python was coming online and being developed. There was also make code the graphical Programming language from Microsoft. I feel like those might have been roughly around the same time And so I started to dive into both of them, right? And I started doing these make code minute Segments of my show little videos that were about two and a half minutes long And really trying to do Elemental things like how do you press a button and know that it got pressed kind of stuff? all the way up through some more advanced like I want to do a whole project that maybe lights up things and is a game score counter or Interfaces with my computer over USB so that I can make a guitar hero controller for a Computer instead of a Nintendo. So I did kind of a range of those types of projects But at the same time I was using circuit Python in projects and Probably for my own projects that I made learn guides out of I I went from in the early days with a to fruit It was all Arduino Then I started to do half Arduino and circuit Python and then a circuit Python got more libraries for Parts I wanted to use and got more features. I've Sort of drifted more towards or been retracted more towards using Python For my projects and I'll still use Arduino mostly in cases where it's not even a speed thing It's anything I've done pretty much. I've had the speed I needed in Circuit Python, but it's again if there's just like a feature a Library or something that didn't exist for a certain thing and it was like, oh, yeah Kind of the only way to do that. So we know but I I Love using I love it being iterative And so I love the iterative nature of circuit Python Just because I can try try try and it's like as fast as hitting save and I see right, right, right? Um, and so that that's been a help and then I've I've become Kind of I think as most people at the one you're using more becomes like you don't have to look it up as much like the syntax and Things so right I was just gonna ask you about that. Yeah Yeah, you know, I I missed semicolons at first and But I think I've come to really like White space formatting Which I don't I wasn't always that good at doing that in C I mean you can kind of do that, right, but you don't have to you can really brackets and so There's something nice and visually organized about that's almost Forced on you and I'm a very visual person's why I took to make code and a lot of For people who saw the the show I did before I was showing some of the way I tend to do computer graphics and and CAD and things like that is with Dagnodes like nodes with attributes that are connected and so that type of Visual arrangement of here's some data and it goes into this which performs a function and the data goes to the next thing So that type of visual arrangement of things is helpful for me, which is which is one of the things I've always liked about make code and so I think there's an element of that in circuit Python of Keeping things Organized for me to see where sections are of things just on screen And now I've transitioned To doing this show instead of make code minute I'm now doing these and I did like a hundred and I don't know thirty five episodes of that or something like that There's a lot of them. So I covered what I wanted to cover right now. I'm having a lot of fun tackling a Similar type of thing. I didn't go back and say, okay I'm gonna do a one-to-one of them, but I'm just sure starting out with what are really elemental things and I'm only Seven or eight episodes into the circuit pipe for a second. So it's literally been like Digital in digital out analog in analog out PWM. That's kind of like analog today. I'm a bouncer so those are Part of how I arrived at doing these is that there are I don't know like Five things I do in almost every project Mm-hmm as long as I can like read a button and send a signal to a thing and Maybe iterate and count something like that covers like most of the physical things with electronics in them that I end up building right USB real popular midi real popular. So neopixel So these are these fundamentals that I use a lot and I have these two great resources for Reading and copying and pasting when I do that one is the circuit python essentials learn guide Uh, and so if you just go to learn.aidford.com and type es s It's the first guide that pops up if you go to our search thing Just es s it jumps you straight to that or you can bookmark it. I have bookmark And that has a terrific A bunch of little code snippets for things that you commonly do and then the other is my friend Todd Todd curt he's Todd bot in our in our forums. He recently started a Uh github page that's just called circuit python tips and tricks or something like that And it's it's a similar type of thing except it's it's not even on like a learn guide with Images, it's just bunches of little code snippets that you can copy and paste out and uh, It it compliments the essentials guide because it's maybe some more obscure thing like how do I find out how much space is left on this You know on this flash drive or uh I'm trying to think of other examples. The debouncer is on there So I just I use that a lot and I said, okay I'm going to do the circuit python parsec by showing people the kind of really common things that you end up doing when you're building a project Do you think do you think we're missing anything? Um, no not between those two and maybe maybe at some point, um, we can look at uh folding some of that stuff in right I haven't actually seen Todd's page. I'll have to take a look at it Yeah, I'll I'll put up a link here in a second or if anyone in the chat Can can put it out of Todd's Todd's here or not Um, he was actually I think he was having to go run an errand. He said, um But I'll tell you the thing that occurred to me that's highly unnecessary, but would be kind of cool is a um kind of I don't want to use the word wizard But like a configurator where you click like a checkbox next to like five code blocks and say that's what my project's going to need and it just builds a circuit python Dot pi file. That's just okay. We're going to import these eight libraries You're going to be setting up some neopixels.  You're going to need to iterate through something and count like it it's kind of the um Only thing I'm responsible for now other than naming it's like I've got the logic of these code snippets in in our two Those two places so I write Copy and paste them. It would be kind of cute to have a wizard type of thing where you just say, you know Here's my menu of stuff that's gonna without needing like a blocky coding image thing That's it, you know, I've so we're working like what I'm working on is this ble workflow stuff, right? And I'm super I've I wanted to do it for years I had to get super in the weeds of beli to do it and it's kind of like I am hesitating a bit But I'm very excited. I actually just got a like listing the directory working Um, and I think I might have just fixed reading a file From the app as well. So like we're we're on the brink of having this world where you have an app on your phone Um, and it can talk to circuit python and one thing I thought about for the longer future And you know, whenever I talk to people about like, yeah, I want to be able to program from your phone They're like, oh, that sounds terrible because I don't have a keyboard And I'm like, well, there's a world where you don't need a keyboard. There's a world where You can have a an app that allows you to program that, uh In my mind is this meet this This intermediary between block lee block based programming and text based programming And I think of it kind of as code based programming And I think an element that block based stuff does really well Is the ability to browse for what you need Right like and and they do it through like categorizing blocks based on color So that's like your category and so that's going to be your like circuit python essential stuff And then it's going to bootstrap you but like maybe there's this, um Like more core like code forward version of that where you still get the ability to browse but you don't necessarily have, um You don't necessarily Have blocks. I I kind of think of like it looks like text, but it interacts like blocks Yeah, you know what in fact that exists in make code in their sort of python or uh Java tab depending on the the make could you if you go over to What you'd kind of think is oh, that's probably just the text editor It still has all the categories and you can still pick like neopixel strip and it pops a line of Code in for you. So you may then need like Enumerated lists to change some numbers or whatever if you don't really want to type But they actually are they're even uh, I think that's even closer to what you're describing Without the need for the graphical stuff, which I think would be maybe too too much for a phone to to Noodle around with but um, yeah, they they do have some stuff that tries to, um Ring in chunks of code that are the equivalent of the graphical block basically, right, right, right Yeah, I wonder like it still has a cursor for where it goes, right? Or do you drag A block into a particular spot because like no they only go as far as um It it's basically popping Text into the editor for you when you choose their category item Throws it over there for you. I think and that's it and then you're typing right because I'm kind of convinced it like that the real failure of text editing on a phone is is the cursor right like Cursor management on a phone is really What is terrible in my yeah? Yeah, it is her So I like this idea of like You have holes and this is kind of what blocks do right is like You have spots where you can attach something else and in my mind in text or in code It's like if you have a function that takes two parameters like you don't have a cursor But you just have holes there that you have to fill in Um, and if if we know that like the second parameter is a number We just click the hole and you get a number keyboard or something, right? Like Um, there's some really cool things that we could potentially do with that. So Yeah That's the that's the long long term But yeah in general the the where we are right now with circuit python is just terrific like I I can get stuff done um the Um Place we're at from like my point of view is that I finally have little like, um You guys are putting buttons on things like the fact that I now have one of my camera controller uh keypads here that Doesn't show up as a circuit pie drive because I'm using the the circuit python 7. Yeah dot pie thing to describe the thing as um Only a hid usb device. That's the only thing it shows unless I Hold the first key while I'm starting up. I think is what I said it to I did a couple weeks Like very refinements on some things like that I'm sure there are still, you know, major things that people want that that don't exist but for Um, the place I'm at it's like it's just kind of amazingly refined Good How long we've we've been working on or you've been working on it. I mean, it's not just me either, right? Like just I was the first person That's good to hear. I I um To some degree like this ble stuff is something I wanted to do for so long. It's kind of like I I I'm trying to think further out, right like Like once we do that, what is the next thing and what are the next things after that? um And you know, we've always I've always tried to keep our focus on the like first five minutes and so There's a lot of work to do on the ble side for that but um I wonder how we can continue to push the boundary of what happens in that first five minutes Um, because as you know as somebody who doesn't have a software background like I do Like the question is is like Or the challenge is like making sure you don't get bumped off Doing it in that first five minutes. Yeah, that's a really interesting question. I think the um The first Five minutes, um Is There's an aspect of it that's difficult to Control Without really controlling the ide Um, which is why I think about these browser based things like make code. Um, you know, if there were a browser based editor for circuit python devices that Always started with working example code and not just print hello world at the top But like here's a you know It's as if arduino has always opened, um blink Dot I know when you start starting them up, which they don't do but like you're you're when you're If if you're doing stuff every day, it doesn't matter But if you're like Casually doing this stuff and you're coming back after three weeks having not touched any of it You're like god, what do I what do I even how do I even start like I really like the idea of? um library management in a browser Example code and auto completion type of stuff uriel and easy to connect to serial But where someone can just say From because because currently I either go to the essentials learn guide I open up my old code from a different project that I remember is similar or I go to taut's uh tricks page So I'm always going somewhere right not staying in one place. I use adam Yeah, if there were adam plugin that was like hi, I am your circuit python best friend and it It was just like what would you like to do it doesn't need to be clippy and have an animated character anything right, but don't annoy me, but at the same time a um This notion of what you're talking about would be a leafing It doesn't necessarily have to be on a phone like if i'm on a my computer with giant when you know monitors I still don't really love going and putting my attention over here to copy and paste a thing Hopefully properly right, but instead just from within one environment one IDE of some kind or web-based thing of some kind to be able to say You know search neopixel and it says I think you probably want to paste in some like format a neopixel code and you know I ran into this one uh two days ago when I Grabbed this little eight millimeter through hole neopixel Uh and it didn't work and I was like I kind of for whatever reason remember that this is not a grb Oh, yeah, neopixel and I looked in our product page and yet says okay, by the way watch out because this is rgb ordered Well searching the internet or the ate a fruit site for what is the order What is the the uh flag you put in when you when you build the neopixel strip to say the order right think order equals But i'm not sure same with like auto right. I couldn't remember the word auto right So I was like automatically auto something and it took me like yeah away from what i'm doing So uh and the read the docs are great. I end up there too, but again, it's like a separate place So, uh, I think that's one. Do you have do you have the adam? extension installed Because I don't I think there is one and I don't think it does what you want, but it um Fomey guy was just looking at it. So what um, what this is autocomplete to some degree right is Is one way to solve this problem and we did Dylan actually she helped us and switched all of our documentation that generates the api docs to a Format called circuit or python stubs, which is like it's python code, but there's no implementation Um, and all the editor is kind of standardized on using that as their way of understanding What the apis for things are so that when you're typing it in and it knows what you have it can give you Autocomplete for stuff like that. I'll check that out. Yeah It's not like one of those things and and talking about this is like we should prioritize it But it's like one of those things that like is still in the works and it still doesn't work very well But like that's definitely part of it and yeah I also want to use that for like if we do do an editor for a mobile device Like it will be powered by that same information That's smart though because it looks like if if that's done that way It's not just like putting all your eggs into creating one ide, but instead it's creating A way for the docs to always generate these stubs that then someone in their plugin or app can kind of subscribe to grabbing that info, which is what yeah, and so like The atom id id could use it mute could use it VS code could use all of that data To power however, they do that autocomplete we can use it on the phone um I've been thinking a lot about like if you have a like pie leap app and you pull it up and what you get is just Basically like all the examples, right? So like the that starting problem is like let me show you all the learn guides and you just select one It does the project bundle fly bundler stuff and Dumps it all on your phone and now your phone's doing that project immediately, right? Like That's really what I've been thinking a lot about too It's awesome. Yeah, so Yeah, I guess there's a lot of work to do Again, I mean these are these are nice problems to have because they're about refining The interactions with the thing that I like that works well and right I can make my projects Right and I do want to I The other thing that's on my list is I do want to support the raspberry pi natively Because I would like it so that like and I think you'll like this too as a graphics person Like it would be cool to be able to do all of the display stuff that you can do in circuit pi thumb on your tv Oh, yeah, and so by being on a pi you would just have hdmi That would give you like you could have two 4k hdmi display. I owe displays or something crazy like that That's wild. Yeah, I picked up one of these and and had a lot of fun with uh, it's the dazzler from oh, yeah And it's a hdmi out. It's like a it's like a graphic card for a circuit python device basically, right? they're Going through a big chunk in Graphics processor and doing like on 120 frame a second like demo scene graphics. It's really cool and a lot of fun because the The interface into it is It's sort of simple circuit python I I just scratched the surface on like modifying two demos. So I can't say I had experience in it But it's you had a good experience. I did. Yeah, I did It's uh a lot of fun. So that's that kind of horse power at your disposal, but It's just like you're talking to a you know talking to a game engine through a develop the like the game developers kind of api Not the coders view of the world. So, right, right Appreciate that Cool. Well anything else you'd like to talk about or otherwise? I feel like I should let you go Yeah, well, I'll tell you the one other thing that I run into Dill and uh The funny thing is that I've been running into this problem And since I started with microcontrollers and art we know um And again my friend Todd Kurt who's local we used to in the before times get together and chat about this Who I also met when I was visiting Um, so, uh, Todd laughs at me because the answer to this problem I always have is like I need to do two things at once like I I want like a pulsing led going but I want to also read a button And I don't want to like and it confuses me He's always like blink without delay the the blink about delay example of arduino is like always the answer and it's never the one I want. Yeah, and so I'm like, but I Love that in make code. It's it feels like it's threaded like I can just say this is happening And this is a second forever loop and they're just concurrent and he's like, right they're lying to you under the hood It's just using like elapsed millies or something, you know like that and I said that's okay I don't mind being lied to but the thing that I always Bump into is like I kind of need two things going at once especially if I started thinking about things like MIDI sequencer, let's say I want a 120 bpm clock that's going and it's lighting up, you know Some keycaps, but it's also still allowing me to change stuff like this is this area where I never can really wrap my head around how I'm supposed to do this in Arduino in circuit python pretty much in anything. I was like, I just want it to know that I'm trying to do two things So I don't know It's like a guide you could point me to that set me on it, but it's the it's like the one thing I always run into well, I think um We hear this a lot, right? Like this is not a new thing that we hear from people and The challenge I have is that Except for the rp2040 like fundamentally you can't do two things at once on a cpu, right? Like and that's part of the reason that I push back so hard when people want this is like Look the cpu is a linear thing and it does to some degree one thing at a time and so like I I'm kind of because of that. I'm kind of okay forcing you To think about how I okay I'm going to do this blink But actually this I have some time while the leds on in the middle of the blink to do this other thing Right like to some degree. I want people to have to think like that um And the other degree is and I wonder if you ran into this with maycode It's because you know They are doing all of that looping and threading stuff behind the scenes But they do allow you to share state across those boundaries And I wonder did you run into problems and weirdness once you started orchestrating between two things going on at the same time? Uh generally not but I was not pushing things too hard. It was simple things like Even having two concurrent Melodies playing I was able to have them have their own kind of like Time and looping and they didn't even have to be at the same length and they just kind of both ran but it And I can still have a like change You know mute one of those when I press a button so I was able to do some stuff like that in the game In make code arcade is probably where I used it the most and um there it just It just seemed to work. Uh, I I was able to say okay. I've got an enemy that's moving around on a path Meanwhile, I'm my guy with my controller and it didn't feel like I was managing that stuff So it right old the kinds of stuff. I was doing well enough to um So again, I was okay being lied to but right I was able to tell it to do the thing I needed to do No, I mean, I I think make code has been like very successful in doing that and One of the challenges as we were talking about this like merging between like this middle ground between block-based coding and text-based coding It's like the the one of the things that make code has that text-based coding doesn't really have is this ability of like separate blocks, right like They break linearity that text-based coding Generally has right like your code starts at the top and goes down Unless you tell it to go elsewhere, right? Whereas like in make code you just have this block and that block and they have like Just do this or on this thing and like It makes it clear that they're disparate um One of the challenges in python is usually it's like I have this function and this function and then I'm gonna call this function at the end that calls both and runs both, right like it gets like It's just weirder to me. I I think that um the setup in in python is like Not as simple and it makes it a bit harder to to talk about that I see we're saying yeah, the paradigm is not conducive to the notion of this thing and that thing because it's right And I've thought about like, you know, you could have the model of just like code one dot pi and code two dot pi And maybe they run completely independently Um, or at least they pretend to How do you What if you do want them to talk to each other? right, I see Which is kind of interesting some people had mentioned in the chat. Um, and you said the rp20 40 with these Little p.o. State machines. I have not touched that yet. I think maybe I did one example based on some code that Maybe jeff epler put up, but uh, again, it's not something I have any Uh comfort level with right or a great understanding of but the notion of these If they're really if I'm even thinking about it properly of these Uh separate p.i.o's doing something without uh being interrupted by other stuff is uh potentially The answer for the kind of things I'm looking for well I think like sander is is pointing out that there's actually two cpus in the rp20 40, right? Like there's two cortex m zeroes that you could theoretically run python on and micro python does this They allow you to write run python code on two cores actually simultaneously Right where like make code is just faking it for you right But in the case of actually having two cores generally you can have them run running concurrently Um, yes, the challenge would be Can that be made? um accessible To a maker like me Uh, because right now it feels like you and jeff epler and shon heimel You're good to go with that stuff, but I'm like I'm not writing p.i.o's. I'm not writing like assembly language on a separate Virtual part of the chip or whatever right, but at the same time what you're talking about for what you're talking about Like you don't need true concurrency Right like the only time you need true concurrency is if you're actually like constrained on how much processing you can do Like for the like I just want to blink every one second But I also want to check a button at the same time Like you don't actually need that you just you just need the thing that'll fake it for you um But it what you're talking about with p.i.o is actually Is an important idea In the sense that actually there's a lot of parts of the chip that work independently from the cpu right like if You're doing a spy transfer right like Depending on the chip you might actually be able to say hey Here's four bytes just make those like send those out right away Right and then now that spy thing is doing stuff concurrently when your cpu's doing stuff Right and then dma is this direct memory access thing that the cpu can set up and say hey when the spy needs another byte Just read it from memory for me so that I don't have to worry about it So there is a lot of concurrency that happens in addition to like the traditional concurrency you would get with the cpu Um and that's kind of like if you've ever seen it like we start to see this in circuit python where you can play You can play a wave file right or something you can play something And it will play but then continue to run your code right like there are a few cases that we already have where we're actually doing Stuff either in between your python code running or actually relying on the hardware to do it concurrently with what we're doing Yeah Yeah, it's a hard problem and yeah And I think you know Fundamentally that the challenge that computer scientists have had is like how do you express it? Yep easily and correctly and the correctly part is the part that nobody That I know of has done a really good job with uh-huh Because concurrency is really hard and like internal of the circuit python we're constantly finding issues Like I've been doing nrf stuff and I'm seeing like oh this like Output came back as usb input like for some reason like I'm getting Into the repl because some texts that definitely did not come from my computer Like the code thought it came from my computer like concurrency is really hard and I I think that You know we we often hear about it's good to hear this from you because you're not one of those people is like I've been doing threading for the last Two decades and I want my interrupts like you're saying like I really want a way to express that I'm doing these two things at once Right. Yeah, I'm careful to try to not be the guy walks into the mechanic and says I think my distributor caps are blown I just want to say what I want to do not what I think the solution is I'm not gonna run around and say we need interrupts. We don't need interrupts I'm gonna say right this nature of the the types of things I'm trying to do and usually there's an answer like It's pretty rare that I run into something where some other person hasn't been able to help me figure out Oh, yeah use elapsed millies like that's been like one of those things that I go to and I'm like, okay You're right or the debouncer, you know, it's like, okay, right that doesn't actually block anything So right and in in in circuit python the equivalent is like time dot monotonic, right? Like you want to know Yeah, I mean you're talking about I assume the Arduino equivalent. I don't know Yeah, those are the few similar concepts to me is is time monotonic and elapsed millies. Yeah, yeah yeah, so I think and I think this is the strength of Adafruit and and In general is that they have folks like you and all of the other creative engineers who are coming from though I want to do this thing because I want to make this thing, right? Right And having that guidance and you know that informs what the war makes Right, like having that grounding and like this is what I'm trying to do Because I want to do something not because it's cool Right. Yeah. Yeah Yeah, right So I think that's really important and I think Adafruit's been really successful because they have that and circuit python's benefited from that as well Um, so whenever it for folks watching if I ever push back on you say like I know you want interrupts But tell me what you're trying to do. Yeah, this is exactly why Right, because we may have something that allows us to do it concurrently for you already Yeah Yeah, no, it's exciting. I mean the the thought I keep having is I I can't wait till the next Time I get to teach something like a microcontrollers type of class in person with people Using circuit python to be like look at this. This is no longer, you know, scary It can be a creative person who wants to just make their cosplay prop do a thing and the fact that it's now A text file that you can drag onto a drive or share with someone That that aspect of it is easy to forget How big of a change that is compared to okay Put an IDE on compile a thing successfully and get it onto onto the shipping compile form Again, it has its place and and it's powerful and great. I wouldn't be here if it weren't for Arduino, but um From from that aspect of trying to teach a class in two hours of a physical thing getting built and putting code onto it Uh, I can't wait that again Your python on it. Right The really different animal. Yeah Well, thank you so much John. I'm gonna let you go because I can talk and talk and talk obviously Yeah, well, thanks to everyone in the chat for putting up with our uh Our yammer and two and uh, I'll get out of here I'll finish my popcorn and my drink and and and uh, I'll watch the show and let you guys uh Dig into some some BLE Awesome. Yeah, I I'm gonna try to show a demo of what I was like just trying to fix So it was very exciting. I literally like got my phone connected And I listed all the files on the device and I was like Because last time it crashed so, um It's very exciting. I think it's gonna be really cool Cool. Thanks John. Thanks for having me so much fun. Yep. See you later. All right Sorry discord folks. Let me catch up um Struggle to Me rearrange my windows here I think I can only make my discord windows so small That feels larger than it used to be It's fine. Oh, you know what I made it bigger That'll do Awesome.  So let me Let me scroll back Actually, let me take a timecode here So if you have questions, um I'm happy to answer them Dave said is JP really in his workshop or is he using chroma create chroma key and actually is the local bar You know, he's just he he has beer in his workshop Christian said are we talking like having a pie host a server with that editor and library manager could be a Good way to do the usb serial interface if you're using a mobile device Or is this assuming circuit python a bewee? Yeah, I when I was talking from a mobile device. I mean straight to the device circuit python device um Ryan likes using event loops for robot stuff And king or nor says these are always tough concepts to teach my students and the timing delay problems Yeah, and I think it like, um It is really an interesting question of like how you express what you want to do Like it makes sense to people that I want to do two things at once um All links to the beer awesome What is the approximate longitude difference between you two? That I don't know. I'm in Seattle and JP's in la John is in the weekend groove. Yes, he is Yeah I moved things around here People make their own beer at least you can see where I am in the chat Back into circuit python after my excursion with c++ with circuit python. I encounter much less problems Also, the freedom we have in the python language. I'm able to create a project in much less time to c++ Yeah, I think that's the pitch. That's the pitch for me is like It you can get going really quickly with it Ha ha moda timmo says myself Myself and them both went to the barber this week. Hi. Yes. I did. I got a haircut and it was It was a little late because it was like in the 80s or it was pretty hot But now it's less hot I missed a lot Yeah, I need to look at the new swift playgrounds on ipads They are definitely experimenting in that vein 80 makers bill says just a thought what I'd really like to do is be able to configure a device by a phone So edit a config file set values Let us change delays configure what keystrokes midi notes are sent Yeah, so the file transfer stuff that I'm working on is like agnostic to what file you're sending and receiving So if you have like a config file on the device and then have an app or just a text editor on the device You'd be able to do that I really am pushing to have like a generic file app and a in a specific circuit python editing the python stuff The boot.py usb turning stuff off is seven only Yeah You have about five minutes to set the tone expectations and keep their attention. Uh-huh. Yeah, keep the ease on board The final version Yeah, you have to save it I end up going through all my devices being like is this the one I had it on p cook can do vga. I I know but I want hgmi I don't want it overclocked all that stuff Is there a circuit python fake threads for non critical non blocking functions? There is uh the async keywords You can kind of manage it yourself, but not a great Yeah, it's very early days still An extension like micro lab within circuit python is a game changer by the way is other similar functionality planned Especially now that circuit python is closer to the current version of micro by that Um, you know micro lab was just like zoltan coming to us and being like hey, you should add this and we're like Oh, that would be awesome. Um That's really all that stuff has been you know, jeff's done the integration part But zoltan's been just really a great collaborator and so it really depends on You know the folks that come into our community and and what they want to add We're we're happy to work with folks to get more stuff in Doctor says if you had code one and code two could there be a dedicated memory space for them both Yeah, I think really what you want is like I think I would just do cues like like message cues back and forth Um Yeah, that's what narrow doc came up to too Yeah, it's it's not an easy The concurrency is hard How are we going to do the next two weeks? Um, the most common class of tasks I hear along the lines of when a button press run code function Every 50 milliseconds run code functions stuff that our dino world would be often done with interrupts But you don't necessarily need real interrupts in circuit python. I'd love to make a native code library for circuit python That's just run code every end milliseconds Since the micro python merge can I do that now with npy cross? So with the latest versions of the micro python core, you can do native npy Files I wouldn't recommend it Um, and I'm not sure whether you're able to trigger python code from there um The native npy stuff worries me a lot because it won't work across all the boards and that's kind of a big selling point Um Yeah, people agree Oh, congrats mark mark says so while I was watching the show I just got noticed my show until badge is now officially my first certified open source hardware project That's awesome. Congrats okay I'm caught up in chat sander pointed out wool from alpha allows you to do the latitude of someplace minus the latitude of another place as well Beata says We'll be taking another crack at being an ice cream sea sensor in the next two or three weeks Or next two or three projects this week has leds and light sensors Yeah, I'm surprised that like for a while like people didn't want that and like more people seem to want it now Um, okay, I want to see if this code that I was trying to fix before the stream works So we're going to go to the overhead And this is my trackball And my dirty desk like this weekend is all about me cleaning the office. So hopefully I'll make some progress um Okay, so let's see Me unlock my phone off the screen this time So here's my phone. Oh, there's my control for my light Maybe it will just work Oh don't want to see I was texting my neighbor So here's the latest like hot. Oh, let me switch it Here's the the hot out of the compiler version of glider And um, it's not fine in anything. So what I'm going to do is um, I'm actually Sorry, I want to make sure that I have the So I'm forgetting the device So I'm back In the auto connect, but I forgot it now what I'm going to do it here with this test version is I'm going to click it So it does public scanning So I'm going to click once and then when it's blue, I'm going to click it again And now it should be publicly scanning And we can see it's one in one And it's nearby And it's pairing So here, uh, we haven't done anything to the circuit by the device yet, but if we hit It the folder you can see it listed everything Awesome And now if we want to read a file we can click this to change the file name And now this is the moment moment of truth if I fixed it If we hit read file And it doesn't work So this is what I was trying to fix um But it doesn't look like it's working So let's um go to desktop with hover Desktop with overhead. So what I I just want to check I may not spend a lot of time on this today But I was just trying to fix it. So um, let me do It's probably that one So let's just go through that again because I want to see what the circuit Python side sees Um No, this desk has like kitty litter dust on it too. It's kind of gross too I know I need a phone. That's just we're doing stuff on the screen I have this android sitting here, but we're doing is first but yeah that If I can't see the litter it doesn't count I can see it. That's the problem Um So what is happening with circuit python development when you are on vacation with dan jeff? Continue to do releases. Yeah The show goes on without me um I you know, I do have this iPad I could use I have an iPad here You don't want to know where that The cats have been in the litter box. That's what that's why there's litter dust here The litter box is like in the next room over it's Reality If no one has been inside your home in 16 months, it's clean, right? No, that's where the dust just settles Yeah, everything everything continues with circuit python. I'm not the only person that works on it um Okay, so we have it pulled up. Let me just do the same thing I haven't set it up So i'm forgetting the device Pulling it up And note, it's not finding it because it if you look in the rebel or in the serial output. It says private advertising That's what I actually want to work on today um And We'll do the list again And let's see what read file does That didn't look too bad That looks pretty close actually Let's take a look at this Simon says so scott how are your cats spook doing well on his meds? He's doing really good. Yeah Yeah, he hasn't I always say the disclaimer about him having a seizure, but he hasn't in Months, so yeah, he's doing good. Um, okay, let's take a look at what this said This looks pretty good. So here's the list This is all my debug prints write to Says okay, we want to read code up high total length 14 73 chunk size header Here's the first bits See the code there And it should be 493 so data out 493 Um, I'm just taking a look at this in case if I can figure it out. Maybe the app will actually finish I think the app is right. Antonio is just looking at it so Read from packet 12 continue command Continue read The continue read is what I think on the circuit Python side was wrong So continue read write Oh, I'm just not printing anything out about what I'm sending Let's add that I would love to get reading working because I think writing might work I'm kind of bouncing back and forth between Trying to get it reading or like trying to get the protocol working and then also Trying to get all the like connection stuff going So what the other thing I was working on was trying to get the the demo test connection code working or the the python side working, but um Okay, let's Validate this stuff. So I'm just going to copy This print and put it This is all I'm going to do. I'm going to copy and paste a bunch of stuff Okay, so that's quantity read and we're printing it out And I want to print out the header too because I was getting all of that wrong here We won't Potentially spend all the time are we diving into bt workflow? Yes, we are And is Response bytes So that'll tell us that it's correct We should get a third Oh, there is another continue read here But then it Was disconnected I wonder if that was just I don't know why it was disconnected Um, okay, let's build these tabs as I building this I would like to do an android version and by Do it. I mean, I'd like to see Antonio make one But there's like a lot of stuff we're learning right now um Anthony says I don't think people might understand how hard this is Congrats, and I hope you get this working soon. Yeah, me too. I was hoping to actually get it working before I go on vacation next week So I've got like Wednesday is my last day, so It'd be cool if I It's not I feel like it's pretty close. Has anybody in the in the anybody watching done um done Billy and done Done in particular like The advertising process for reconnecting because that was the other stuff that I was trying to do of like I've got the private advertising running, but On the other device if I'm using the a second circuit pipeline device to connect to the first I can't um I can't when I do a scan I don't see the private advertisements and I think the reason is is because I haven't set like the Key identity stuff internally But I think I need to do that Okay, so I built And did I do this? John says whoo, was there that was a cool way to kick off the stream today Where are you going on vacation? So, uh, my partner her family is from Um, they live in michigan, so on next friday I'm flying to michigan and we're gonna hang I'm there for five days Hanging out with them and then I come back before she does and then I'm going to go see my family Who lives like two hours outside of Seattle here and the my parents are watching the cats So I'll actually see them on thursday when I drop the cats off as well Okay Let's just try it one more time Because I would love to see this working Oh, ah This is what happens when the connection stuff is just like makes makes the Process so much Longer Talking about iteration times Come on get close enough That like minus 40 broadcast is pretty There we go. There we go there Listing seems to working pretty well Wow, see it's like stuck in this loop still See how it's like flashing a bunch Something's not right It might be me It's like sending the same pieces over and over and over again But now we have all the information Continue read header out This header looks kind of long. Oh, that's right. I think header out That's just the reply this is There I make this bigger So we're doing what is the Protocol What should it be sending not the up in michigan going to kalamazoo Oh spoilers I was gonna show that off too Um file transfer. So here's where the protocol is listed And The response is 11 Status one is for okay Chunk offset total length Chunk length Chunk offset total length chunk So this header is Chunk offset chunk Length like it seems weird that these are No, that's that's okay But then what we should get is This Why is this this so long buffer? That's like the full buffer Where's this print? It's here current offset Oh, you know what I wonder if read pacing No offset plus chunk size Greater than or equal to total length then we reset and close the file I am not in new york city. I'm in seattle I work remotely for new for uh eight different I will get you working out offset I am a printf debugger. Let me tell you Thanks for the question though nine four sixty one. It's a pointer It shouldn't be That's what f size is taking care of it is rereading it. So there is this weird world where Uh mechredev says have you got the bealy code in upstream branch to test out? Yeah, if you look in my it's under bealy workflow two is the branch name It might not be quite up to date with this, but I generally push every day to back up Offset isn't getting reset on every call. Is it if it is It might be hard to Greater than the total length. This made your wrong question. So offset should change As like it's the client's job to add it and then send back the new offset. I think Let's take a let's uh Get some more debugging more debug prints in here By the way, I love sublime. I do too. Let me tell you it is so quick I just I appreciate how quick it is That buffer is hard to read. Yeah, it's because I'm printing both the ascii and the hex Which is kind of annoying Um, if you want to I can commit this stuff and push it if you want to look at it separately Right like I'm going to rebase that branch of stuff. Don't Don't consider me can Uh Don't consider me committed to any of the code that's there, but all right, let's try it again When I'm not on stream, I get this iteration down to about three minutes two or three minutes I know because it says like two minutes ago just looking at ollie usb to isolated stuff Sounds like something blink it would be good for I'm gonna say it didn't come back I was like, oh it's connecting Keys aren't right list code.py to cool down Oh, no Lost my connection And it doesn't Hey bruce No, it's yeah, see the like We gotta get this reconnect stuff going It's public advertising again You can do it I still like that. I can see all the files Yeah, it's still doing the same thing, huh? It totally could be me It's funny actually moving my phone away is the reason it disconnects I think Or maybe because I locked it All right, let's find Oh, you know what I think it is We need to reset We need to reset the current offset regardless Like we're not waiting to get to the end of the file. We're waiting to get to the end of the chunk And then we should get a new command. Yeah, I think that's what it is. So see here This is checking if it's total length Whereas what we should be doing Is we need to have something more like This So if current size is less than Or no, it's a read I think we should just always Set it back Oh, which we do we say current offset is zero There's not an early exit Except in this error condition So why is it? It's just sending the same thing over and over again Like it's the app's job I think it's confuzzled. Yeah. I mean it could be the iOS code that's confused Or I'm not reading the right place Like this looks weird to me Doesn't that look weird to you? the fact that like This buffer is so long like this buffer should never be That long That's what seems weird to me Bluetooth background Here's the buffer print Red from packet size buffer current offset. Why is it so long? We're in read pacing Oh Where was I looking? I was looking in read Read pacing doesn't set current offset back to zero Read does but read pacing does not safe I think that's it This code is terrible by the way It's my code. I can say that It's like super early. It needs to be organized I think that's the problem though It's getting chunk 493. What isn't being satisfied? It's rereading I think the problem is that it's like not consuming the current command I think that's what it was Copy here Huge success Are you assuming it works? I mean that would make sense why it would be a problem. Okay, let me get the phone ready. Forget device Connecting Disconnected public advertising Hmm Oh, and it disconnected This is all super alpha Don't judge if it Oh, did you see um There's an icon now There's a glider icon It's still publicly advertising list code Read Hey, oh Look at that We have the file Should we try to fix it? Delete Write file Oh, it gave an error, but you know why? Did you see that it said error? Yay Um, so the error is see here in the in the text output. It says usb is using the file system So that error was totally okay Love the factory says how difficult is it to get circuit python working on a stm32 that isn't supported yet? Is there a guide? There isn't really um The best person to talk to is higher effect who's done a lot of the stm work Um, make sure that it has at least 32 k ram and 256 k flash though. Otherwise it should work Yeah, feel the love Okay, so I want to try another test And that test is I have this I have this usb cable from the shop and it has this data In charge mode, so I'm going to put it in charger mode And we're going to go crazy. We're going to lose our thing. So let me go back to Let me do full overhead here full overhead Um, so what we're going to do is we're going to start over again and we're going to see how far we can get So I'm going to forget So this means that we won't be on usb anymore So I'm going to we're I'm going to do boop Okay, so it didn't give me the blue option Oh, and it's connecting. Okay, so we're going to do the same thing We're going to go here and And it doesn't work Did we disconnect maybe that minimum pair? There we go code.py Read file delete that Hey, oh That was all correct But now the problem is is it's it's um Private it's private broadcasting and this is what doesn't work yet So what we'll have to do is we'll have to I'm going to click this and It should publicly broadcast And it's going to complain. So I'm going to go here and forget I should private or it should Give me the blue Okay, so let's do the file selection again Code.py and let's just I guess we're going to read it again because we wrote it. Oh, no Uh, what do we think the reason that was? It's still running because we're still blinking. Let's just reset it and see what happens I don't know why we're not getting the blue blinks I'm going to forget that out So that we can forget It's like sticky I still am excited that that works No, it's it crashed again I wonder let's turn on USB and see If we if the write actually worked Like because that's what we're trying to confirm Thanks, unexpected maker You're probably gone by now, but I just thought um, okay, let's switch the switch Let's see if that right worked. So we should get a code dot pot or a circuit pi Which we do which is good and it's 1.4 k still And look import neopixels gone so The question then is why isn't the read working I actually didn't expect that we'd do this all day, but I'm gonna put emoji in python code Does that make sense to make a glider report for the linux cli? Says the person without a decent phone I think What you could try actually FETI 2 what you could try is take the Blue the circuit python be lee file transfer library and see if it just works on because blinka has be lee support It's possible. You could write like a thin um It's possible. You could write a thin python cli on top of that library to do it from the To do it from the cli um Micro dev asks have you thought of a wi-fi only workflow like beat the be lee I really I know people want it I find that Talking to things over wi-fi is much more of a pain to get them to talk to each other Um, so I haven't thought too much about it yet it wouldn't Wouldn't I wouldn't rule it out though Like I understand people want it. Hopefully somebody else will add it Instead of Instead of me having to do it Okay So let's see if The read works now Or we could figure out why we don't get the Oh, I think I know I think I know why we're not getting the blue that time it worked Why why is that do you think? Uh, no, I don't think it I don't think it's that my blue led is dead I think what it is Is let's just fix it because I'm thinking about it in here We have the Blue blink. I mean that's a good question doctor because the red led was my problem before But it I think it's I think it would work if I unplugged it and plugged it back in I think the reason is that I'm ending up in this mode Um And what I'm not doing Is before I do that What I should be setting I should be clearing this set saved word So that it doesn't stick the saved word is a piece of memory that doesn't get reset With um, I'm just going to null it out Ryan says I won't I wrote I just wrote a simple web id that seems to work pretty well. You could do um web bluetooth maybe Web bluetooth would be really cool. Like what if you just did circuit python.org slash ide Or something like that. I was also thinking about circuit python.org slash serial Uh for your serial connection as well Um, okay, let's build We're going to copy over this new version To get our blue blink on I like esp now for some things Web repel with the file manager Yeah, I talked to damien a bit um about Brent says talking to things over wi-fi is a pain Yeah, that's that's been my experience Well, this is exciting I'll have to send a link to LeMore that we got some of it working And they can clip it out It's weird that the I should double check that the broadcast strength Like because I'm setting the tx power really low with the advertisement and but I should make sure that when it Connects it doesn't connect at that low strength. That's why it's so touchy. Like I only want The advertisement to be that weak But the tx power once the connection is made should be a lot. So we're doing blue So that's okay. I don't mind skipping it. I was thinking about this here. Let me Let me take a poll. So I hit it during the blue period. Should we still Should I have it be solid blue for a second to confirm that you did did it correctly? I think that makes sense Is that we should have like instead of blue blinking it should be blue solid and then return I should probably just do that right now while i'm thinking of it Let me know in the chat. So if you think that's a good idea My good. I've said circuitrathen.org slash id sounds cool. It could be cross-platform 100 And it can source libraries straight from the server. Mm-hmm. I agree Simon says yeah, I would Okay, the solid blue makes sense. Okay, let's do it So Here's an erase and a race is actually potentially a file system action. So let's set it blue Before we get there um if beli mode Let's init the status led earlier Let's D init it in Here before we reset Set it This is probably bad. I'm I'm copying a lot of this code Um, let's not do that If beli mode you want to set this We're not gonna do it You need another youtube stream for sublime. Oh, sorry Sorry folks What we really what we talked about is doing um What we talked about doing was like setting up a bot so that like people in the chat can control Which video feed I'm broadcasting Um Okay beli mode if it's zero set the save word because we might actually do this If it's not zero after the time The preemptive set want to turn it on before we do the erase because the erase is going to take time I thought you were talking about the band sublime No, sorry Yeah, we might have we might have fights between cat cam and code cam Let's find if we can check in on spook. He looks real cute Does that look like a happy cat or what? That's a cat's life for you All right, we're gonna go back to code now Okay, so if the mode is not blah blah blah and then This can also be beli mode not equals zero or That should be fine diff gets reset We'll get into this loop later, but the diff will be will have started from here. We'll hit the loop once That's okay though Good night, Dave set it Erase boot and discovery. Oh, we don't want this return set saved word Oh, you know what instead of this then Oh look there's an erase here We don't want that instead of doing the set save word we say reset state equals zero so that we clear it Otherwise the value that we're keeping around is the one that will get us back here That's right. Let's try and then I can take the last 15 minutes to show the broadband stuff for 10 minutes Live crowd coding Yeah, maybe maybe that's what we should do is figure out how to have an editor where people can All see the same code. That'd be kind of neat. It's kind of like a google doc All right, let's try this. Oh There's a usb bug here. You can't see it There's a usb bug that sometimes kicks it into the REPL I thought we fixed it, but it's still there We're gonna hit it blue blink solid blue Nice, I'm gonna do it again Looks good Yeah, I like that Can everyone see that okay? All right, let's do one more kicks Bluetooth Forgot Code Read Oh, it was just slow, but it worked Yay And Want to import Oh, it capitalized it And it said I couldn't do it because of usb Awesome. Well, that is where we're at with glider That looks pretty clear. It's obvious that you hit the bealy workflow with press. Nice job. Awesome. Thank you Um before we move on Hello Jeff Finally caught one live gonna have to go back and catch the first hundred minutes to figure out what's going on Uh I just demoed we were working on debugging house The circumventing code I wrote for reading files was completely wrong apparently and Well, not completely wrong wrong in a couple ways um And I'm just gonna add all this and push it so that it's not on my hard drive I actually you know what I got I talked about mail um I did get a One terabyte PCie for NVMe drive that I'm very excited about I've been doing all of this data sciencey stuff that takes a lot of space um And I have a 512 gig thing and I filled it up So I was like I'm gonna buy a terabyte and then I was I realized that Um, I bought the NVMe that's in there before I had my new motherboard And my new mother board can do PCie 4 So I'm gonna take everything that's on my current drive and put it on this drive and then I'll have the other one for um For more space as well So one thing I did do is I actually um actually let me finish my thought commit uh readworks Blue led solid on Erase formatting I'm gonna redo all these commits anyway It's primarily just I'll push it so you all can see it too. See I'm push pushing it. Oh, you can't see it again That's uh Pushing it to my beally workflow to branch Um, so one thing I did do because I was having this problem. I was running out of space is um, I switched from ext 4 to better fs um and the reason I did is because But butter fs or better fs allows you to compress under the hood So whereas I was running out of space now. I actually have 162 gigs free um Because a lot of this data science stuff that I'm doing. Okay, let's switch over. Let me tick it David David let me know he wasn't going to be able to do time codes. He's just been really busy. Oh 153 27 Um Can you move the deep divers roll up in hierarchy? I'd like blue for a change. Sorry I like circuit by the nieces being higher than and that would have that would affect everyone Um Well, that's a huge storage savings. Do you pay for it in access time? Um I'm not sure actually Um, I'm sure some folks would have a better measurement for it, but like You're paying cpu time versus pcie time, right? um and I I'm really lucky that like I I managed to snag one of the 16 core risons. So I have like The best consumer grade thing right now um So if we go here and we just like look at um So obbm was like a name. I was thinking about doing um If we just do dush like it's 225 gigs just in this alone And we can see here like here's a csv file. That's 2.7 gigs and like That is perfect for um That is perfect for better fs's on the fly compression Because like the tools need it uncompressed. They can't like uncompress it as they need it so it's um It's neat to have like this here Where it like thinks it's that big but it's not actually in reality um There's another one that's 11 gigs. Yeah, so these are like, um Yeah, so this fbd us satellite one. It's a big long csv that has um For every census block every broadband wire line provider their name Like how big it is or like Let me show you I can show you so I've converted this to uh db these are sequel light files um So the those of you who don't know one of my side projects is currently Building a map to show where in the u.s. Uh that internet service is really poor um So If you just go it's going to be at fiber deserts.net. This is an old version This is kind of what i'm going for but nationally so you can hover over you can see blocks Um, I'm getting rid of this thing that follows me around But the idea is that I want to highlight areas that don't have good internet or fiber so what we have is like the FCC which is our like Our radio and tv and telecommunications regulator they publish data that's reported by the providers about like For every census block which are these areas here Like how fast of the service it is what um What uh like technology is used to provide that service um Yeah, so it's the provided reported data So that giant csv is like a dump of all the provided provider reported stuff And it's also nice and that's because it's like too common cs getting stuff as csv is really common And then there's also this geo json format um, which is a json version of like Uh stuff and it's really large too Um, Nebraska has a lot of their debating to have an independent group validate these reports Yeah, so kind of the longer term goal is to have this site be able to kind of like Tell you whether like it can be a kind of a third party to So like Washington state has a Has a speed test that um, I'm going to pull the data down from so let me show you where I got let me start it up. So There's this really cool tool called data set um, oh, I was trying to publish it. I was actually trying to like Replace the I got it to a point where it's Yeah, so here. So there's this tool called data set and what you what I'm doing here is I'm giving it specific high tech for kids A static directory a template directory and then I'm listing a sequel light stuff um Like these are the the base map is like all of the labels and the water and stuff US census is the census blocks tracks and stuff. I have buildings I have the f 477 data the mobile data. So cell phone providers Claim coverage areas and different technologies and then this high cost stuff too, which I was just experimenting with So if I get that going um I tried zooming out so I could see more of the country and it just stopped loading. Yeah, it does that Is the speed test logged by going to location in the counties? And having a third party run a test Good night, micro dev No, the the Washington state log the Washington state broadband tests are done by individuals Um, and they're kind of self reported too, which leads an interesting question about determining like is somebody like on terrible wi-fi Um, that's an interesting problem too Okay, so here's the current running example. Let me just hit refresh Um, so I finally got this um Right hand side left hand side. So the right hand side. I haven't actually Um, does it only do Washington? Well, let me show you So this version does the whole us Um, and it's kind of slow Remember, it's like generating a lot of these tiles on the fly. So um I could take requests if people want it. So right now the the um The map isn't really showing what I wanted to show This might just die So the all of these polygons for counties. So these are counties at this level. They're um They're rendered on the fly. So that's why it's taking so long, but it's kind of okay because in In the future, it'll be a behind-the-cache So like one person will have to load it at this level and then everything else um Yeah, we'll take requests I'll slowly pan around as my computer is a little unhappy Um If I know my geography Can you hear my fan kicking up? Yeah, so I want to put it behind fat of fastly cash I can't hear your your fan over my fan. Yeah, that's fair Okay, so what I have here is these aren't These are tracks I think So I'm gonna have to zoom in where in Pennsylvania are we going and will I know where it is? Um Should we just do lebanon Let's do that on chug chug chug So this page is loading from my local box. That's why it's doing a lot more work I have developer tools. Let's take a look. I wanted to make sure my browser cache was enabled Oh, we got more stuff coming in. I want to click So this is a census tract Let's see if I zoom in enough that like there's not a ton in a particular tile Okay, so here's lebanon high school Um, here you can see there there are actually buildings Um And what I can do here is I can click this tract Or this block it drops a marker it highlights the It highlights the block and it tells you all of the wire line providers. So Verizon, Pennsylvania will give you 940 down 80 880 up and I know 50. This is the tech code. This is where it would say like fiber I think what I wanted to say here is like fiber and list all the people that do fiber Then comcast is going to be cable Sadie it says nice haircut. Is that my spring look? No, this is my like I get around to actually having my hair getting my haircut look. I do this haircut all year long it's just I I space out my haircuts longer than I probably should So, yeah, that's what this is showing is that from the form 477 data For this block here Has all these providers. That's what they're reporting and the and this is the service that they're reporting um And then this is the wireless data So what's powering this is data set, which is really cool So if I just do this and then do like f 477 So this is a sequel sequel interaction thing, so If we just click here, it's going to be slow because it has to count how many rows it is But you can actually just do a like I want to find All the rows where the state abbreviation is what is Nebraska ne? apply And And then it took too long. So it stopped me There's no there's no index on On the state abbreviation right now Whereas if I pick like one of these census block codes I could say block code is That number and it's nice. It should be nice and snappy um So, yeah, so this is it. It's a really neat way of just exploring data um I also did so I want to have like raw links that allow you to get into this and then um I just did the high cost one So here is this was interesting to me. I didn't realize that you could get this um So what this is is there have been federal programs to pay for people to get access and this actually lists every individual address It's latitude and longitude the company that provided the service which fund it was And then it will tell you that they got What speed they got and Um How much money total they got to do it so like somebody I think there was a There's like a date here as well deployment year so somebody in 2019 We paid for them to get 10 megabits down one megabit up Uh, which is kind of just outrageous to me. Um, but then again somebody was talking about like Nebraska having terrible, um Dial-up service, let's just see See it's a little quicker now that it's cached So that should be like usually the experience where's Nebraska There it is. So we you're talking the western side of the state Keith says that's a huge improvement for a lot of Nebraska. Okay, so we're in Nebraska here Let's Here's a alliance Let's click here It's a tract. I don't have any data under tracks yet I gotta zoom in Do we think alliance is bad? Huh, I don't know why we got a 404 Let's see how alliance does So at least in this town If this is correct, there's an alo communications, which will give you fiber for a thousand each way See, this is kind of cool like I um I find it fun to find all of these random like ISPs that are giving people great service ideally Um, okay, that's in a town though. Let's see if we can't find like a Like what is this here? Here's a tiny town Yeah, that's the motivation for the bill so this this barrier town has um fiber and it does 300 symmetric Which is nothing to sneeze at as well Um, yeah, so I'm pretty excited. I'm happy with how this is working Um, so the next step I had for this is actually I want to get it Up to the fiber deserts.net because I think it is kind of neat to just explore One thing I also want to do and maybe I'll have time to do it this weekend Is I'd like to put a search box where you can at least um Where you can at least put uh Your like zip code and it will warp you at least to the zip code to just like help find stuff The doctor says will there be anything to add service quality like Comcast here offers the same general speeds as Verizon here But the actual service quality and customer service is very bad So this is all self-reported data right now Um, but there is this site called measurement lab That does open-store speed tests. I think it's just dot net So I I do I think I want to integrate with their speed tests um And so you could say that's why I have a drop Uh a pin drop. I want you to be able to say like I'm here Run a speed test and then what we'll do is will um What we would do is uh Like I would log your ip address when you say that and then I can go look up by ip address later Uh for this open source Or open Open thing Like you can get all their data and they they have some troubles like they just use ip address to figure out where people are um Yeah Keith says it is correct if you're testing and not letting anyone else use the line and you're testing right next to the isp Not in a house a few miles away Your fight for fiber is not technology neutral. So it would be So it would be killing the non-fiber competition. Is that good for competition? Um Yeah, you're assuming that only one provider can provide fiber um There's actually some like there's a model called open access uh where um And I know that there's in washington state here The idea being that like the utility provides the fiber, but the the isp the internet service itself is provided by somebody on top of that it's kind of like We all pay for the roads, but then the like dhl and ups and fedex can all use those roads to service people um Oh, there's a collab version for sublime the reality the reality is is that Okay, yeah, david says we do that for electricity. Yeah, it's similar like there's a lot of parallels to Like we should just get fiber to everyone In the same way we should we should get everybody electricity Um Oh, I think I got Brewster, I kind of just want to like to Like this these poor folks they only have satellite 60 is satellite So folks here they only have satellite internet Oh, but look at this so Brewster here has okay pud 100 100 fiber I thought grand Cooley dam was around here somewhere here's bridgeport bridgeport has Douglas county pud wholesale fiber whoa No, 30 is not fiber 30 is something else That might be incorrect Douglas county zipli fiber that's interesting zipli fiber does not provide fiber. They provide terrible service um Yeah, so I I'm going to try to get this public so that people can start poking at it One thing I would like to get is these tech codes to actually show something Um, oh, yeah, here's green coulee. This is what I was thinking of so this is This is like a big dam here in washington state that generates a lot of our power and there's a Grant county public utility district that does fiber and but it's an open access model So there's like internet service providers on top of that The first number here, um, this 50 is the technology code. So it's it would tell you like What type of dsl it is what type of cable it is or whether it's fiber Early fiber internet services started with dsl like speeds Does that graphic show the number of people they serve because some of those look amazing But if they serve two clients, it's still something of an internet desert So the f the this is a controversy with the form 477 data is that in order to report it. They only have to service a single household or a single premises in the block um So yeah, there's not it's not as granular as it could be um And actually this data on the left hand side includes business customers as well Um, so it's not just personal folks I do have data around, um Like the census data has the number of people that live in a block as well that um is something i'm used to using Or is something i'm used to uh Yeah Hey patrick Does the data separate residential versus business or is it all lumped together? Oh, actually we can just look in the the inspector here So this is the full so what i'm doing is i'm actually just making a call to data set Um with the block code So it will so here we go block code. So it says doing business as holding company Holding company name max. So these are also advertised rates um Sorry for the Sorry, I think it's a Lot more, uh, we're almost down here um These are advertised rates not rates that they promise to give you either Somebody said is that my computer fan? No, it's not um tech code provider name Yeah, so there's just like booleans for business and consumer Yeah, sorry about that folks the window is open because it gets hot in here So yeah, that's where i'm at. I finally figured out how to like do a little bit of javascripty stuff um For being able to like click through round. So I wanted to get this up on the website and get all that working um This is really nifty. Is there a way? To highlight the lack of reliability between the advertised speeds and the provided speeds Yeah, I would like to I would like to get there. I would like to start So when you click here, like I would like to be able to say then and here's all the speed tests we found for this area um And microsoft also released a data set at the county level for what they think um What they think that the average rates are Never understood how well they advertise up to that rate. That's the problem That is a direction. I'm excited to see. Yeah, so I think what I would do is I want to have a button on here that says like take a speed test Take a public speed test. I should say like The data is logged and and like The location that you give here would just like could be associated with your ip Which you should think about before you do that. Um But yeah, I think once we once we start having enough data we could aggregate it so that we could say like Compare speeds and stuff and we could do it even on a like provider by provider basis um, so I've been thinking about that. Um I've been thinking about that as well A lot of this has been like figuring out the infrastructure bits and now it's kind of like, all right, let me Like now that I have all the pieces now, I can just say, okay I'm going to pull this data source in and I'm going to have it show on the left hand side, right? um so Yeah, and I also want to bring in like the federal funding. There's actually a pretty good map that they just updated This is the universal service administration company high cost program Consider open data actually If you're curious about this stuff They have this map They connect america fund broadband map So we were talking about nebraska I think i'm a state off. That's kansas So here is nebraska You'll notice I don't have roads right Right now in my version so these blue areas are um areas that uh We've paid like the federal government has paid to connect people And then what you can do is you can actually just click a dot and say like um This person had 10 1 in 2019 like I was saying um And these are people that like these are these are companies that were paid to provide that service to folks 25 5 um So yeah, this is trying to be a bit more transparent about um Where are our monies going? I thought they had I thought it was multicolored one thing at one I found when I was looking at this is um This here This company is doing fiber with that money, which is really cool So Yeah, I'm I already pulled the this is the the same data set at least all the dots or the high cost data set that I have All right, let's wrap up If you're losing service every other week you should be compensated in some way at downtime Especially if you're working they promise a minimum of 100 they should suffer if they break the promise 74 up is really interesting How does starlink fit into this map? So the They would be categorized as a satellite provider um But they will Only show up in the areas I don't know. I don't necessarily think you have to have a customer um I'm trying to remember when this data was gathered because starlink's done a lot even in like the last six months to a year um But they should show up as a satellite provider um Like here's some small town Yeah, so see they have Satellite so this is sorted by upload speed Um is how I'm sorting it And you can see these are all the people that have mobile service as well. So yeah starlink would show up as a Form four seven seven and in fact, you know what I can do Is if I go here And I do forms four seven seven And maybe if I just look at provider name and I search star So there's no there's no provider name here is starlink, but I think I think that I'm still uh I think this is a little old I'm trying to remember Look at my So this is june 2020 data So it's it's like over six months old SpaceX. Yeah, I could Oh, I turned it off Minnesota mentat says fiber is still needed in dead sleep populated areas Was that a duck on the stream or should I step outside? Hughes was in or not. Yeah Space blue space No space x It's possible that they're uh, they're just not linked. They're not listed yet They did weren't so the the latest round of funding the art off Rural development of opportunity fund like starlink won some of that money. So they they would be in there I do need a better way to know the time of the stream Oh, yeah Yeah, I don't know I could try to get an overlay on the stream That might be the easiest way All right, um, I'll try to get this out publicly Um, if you do want to follow the code the code is For fiber deserts is up under fiber deserts on github under map This does not include all the data so you wouldn't quite be able to um If you're not able to Get it going. Let me know and I'll I'll send you files or get you files or whatever But yeah, let's uh, take a timecode and wrap up Starlink starry eyed the Early reviews are that it's very unreliable and that's hard to hard to overcome You need reliable internet not just internet occasionally You said it does not have the maps in the code It doesn't necessarily have all the source files Um I can fix improve if you want to add things to the dock but not necessarily have exact codes I can always go back and watch it and update it um Okay, all right everyone. Uh, thank you again for joining me for this deep dive reminder This is the last deep dive for a few weeks. I'm taking the next two weeks off for a vacation I'm going to see family which should be really good um Yeah, just put fiber everywhere starlink is not just not going to be Never going to compete with fiber Just spend our money on fiber and get it done once and for all Um, that's my opinion. That's why it's called fiber deserts Thank you all for hanging out. Uh, I'm glad we made some progress on the bealy workflow stuff And thanks again to john park for hanging out with me and chit chatting about things as well Um, if you want to support me, please do so by supporting Adafruit. You can go to adafruit.com purchase stuff there If you don't have any blue bealy devices I suggest picking one up Because we're we're doing some really cool stuff with that that'd be cool. And um If you want to chat with us outside of just this, uh This time window feel free to join the discord server by going to adafru.it slash discord and um If you want to check out the fiber desert stuff, feel free to ping me on the discord as well and with that I think that's all my housekeeping Um, thank you all. Uh, and I'll see you in three weeks I have a great day and I'll I'll definitely get some cat pets in here for you Kitty Kim Hi kitty I have to thank you. It's tradition. Thank dad. I'm taking a bath All right, thanks folks


Hello and welcome to the session I am Deepika here. Let's discuss the question which says Population of Rajasthan is equal to 570 lakhs and population of UP is equal to 1660 lakhs. Area of Rajasthan is equal to 3 lakh km2 and area of UP is equal to 2 lakh km2. Part 1. How many people are there per km2 in both these states? Part 2. Which state is less populated? Now for this question we will take the help of unitary method in which we first find the value of one unit and then the value of the required number of units. So let's start the part 1. The square in both these states is equal to 570 lakhs is equal to km2. So for an area of 70 lakhs or 1 lakh km area there are 20 upon is equal to 190 people km2 is equal to 1660 that is the number of people UP is equal to 1660 lakhs. UP square area there are 1660 lakh people km2 area there are 1660 upon is equal to 830 people. Now this part is Rajasthan km2 and in UP people per km2. Now let's move to the part 2 it is less populated. Now there are two states Rajasthan and UP and for UP there are 830 people per km2 less populated because people is Rajasthan. I hope the solution is clear to you.