[00:00.000 --> 00:03.760] I haven't spoken at DEF CON in quite a while, so I'm kind of excited to be here. [00:03.760 --> 00:07.240] I'm glad that we're in this room and not one of those other big ones. [00:08.160 --> 00:09.940] How many of you have made badges before? [00:10.900 --> 00:13.460] How many of you have used badges before? [00:13.700 --> 00:15.200] How many of you like badges? [00:15.340 --> 00:17.180] How many of you like badges that work? [00:17.500 --> 00:19.060] How many of you have badges that work? [00:19.500 --> 00:21.760] How many of you have badges that don't work? [00:21.760 --> 00:23.900] Not necessarily this conference, but have you ever been at a conference and you get [00:24.000 --> 00:25.060] a badge and it doesn't work? [00:25.440 --> 00:26.480] Yeah, me too. [00:27.340 --> 00:29.620] How many of you didn't even bother turning it on because you weren't sure it was going [00:29.620 --> 00:30.380] to work anyway? [00:31.840 --> 00:38.140] So the point of this talk is because I have made a few badges and I have a habit of reusing [00:38.140 --> 00:42.900] as much as absolutely possible because the chief virtue of an engineer is laziness, right? [00:43.140 --> 00:47.140] So if I'm going to put the effort into making a badge that I can reuse, I want to make sure [00:47.140 --> 00:49.460] other people know that it's available and they can do that too. [00:49.620 --> 00:53.940] I know there's tons of badges, but like, and many of them are open hardware, open source. [00:54.240 --> 00:57.580] And rather than, of course, you know, just taking an existing open source one, I figured [00:57.580 --> 00:59.700] why not do another open source one? [00:59.960 --> 01:02.380] Because, you know, so that's how it goes. [01:02.400 --> 01:06.820] So I'm going to tell you about an open hardware badge design that I've worked on and that [01:06.820 --> 01:11.280] I think will be useful because it's been tested, been through two conferences already. [01:11.280 --> 01:13.300] It's going to be on track for a third one. [01:13.520 --> 01:17.280] And I want it to be open hardware so that anybody who wants to make a badge doesn't [01:17.280 --> 01:18.220] have to start from scratch. [01:18.220 --> 01:22.400] You can just take this open hardware, change it how you want, however you want to do. [01:22.440 --> 01:23.680] Just change the artwork. [01:23.680 --> 01:24.640] You can change software. [01:24.640 --> 01:26.080] You could keep it exactly the same. [01:26.080 --> 01:27.760] Just like change the conference name. [01:28.140 --> 01:29.080] And you've got a badge. [01:30.060 --> 01:33.680] So a little bit about badges, or me, I'm Joe, hi. [01:34.480 --> 01:36.800] I teach classes on hardware hacking and reverse engineering. [01:36.800 --> 01:40.360] I've been in Las Vegas for a week already because I was doing training at Black Hat. [01:40.400 --> 01:41.560] So I'm a little bit exhausted. [01:41.740 --> 01:44.780] But after this, I'm going to go hang around the pool, which is what I've been looking [01:44.780 --> 01:46.080] forward to for the past week. [01:47.680 --> 01:49.440] Yeah, I do hardware stuff. [01:52.240 --> 01:55.660] So let's talk about, this is what I'm going to talk about today, why we have badges, what [01:55.660 --> 02:00.080] this thing is that I'm talking about, what my vision for it is, what we can do today, [02:00.080 --> 02:02.240] and some logistics and pitfalls. [02:03.240 --> 02:07.740] And it started out as kind of like a workshop-y thing, but the space and the venue worked [02:07.740 --> 02:10.800] better for us to do kind of more of a talk slash demo. [02:11.280 --> 02:14.500] So I'm going to talk a bit, and then I'm going to show you some software and hardware. [02:14.800 --> 02:16.900] And then we'll have some time for questions. [02:16.900 --> 02:17.560] Sound good? [02:17.720 --> 02:18.840] Any questions? [02:19.120 --> 02:19.920] Everybody ready? [02:20.220 --> 02:21.420] Okay, listen carefully. [02:22.640 --> 02:23.740] What are badges? [02:24.240 --> 02:25.240] Why do we have badges? [02:25.240 --> 02:26.240] Well, it's pretty much access. [02:26.480 --> 02:30.020] Whether it's a wristband or a badge or something that hangs around your neck or something you [02:30.020 --> 02:33.060] tattoo on your forehead, we need a way to know who's supposed to be here, who's not, [02:33.060 --> 02:35.700] who paid, who didn't, who gets free drinks, and who doesn't. [02:36.220 --> 02:37.740] So we're going to have them anyway. [02:37.740 --> 02:39.320] We might as well make use of them. [02:39.640 --> 02:41.520] So we want the cool factor. [02:41.920 --> 02:43.700] This is a handful of badges that I designed. [02:43.700 --> 02:46.520] My first one over here was for B-Sides Portland ten years ago. [02:47.160 --> 02:52.680] It was a bus pirate, but the PCB shape was changed, so it was the shape of a Nyan cat. [02:52.680 --> 02:57.720] So the rainbow ribbon cables that come out of the bus pirate were like the trail of rainbow [02:57.720 --> 02:58.740] behind it. [02:59.440 --> 03:06.320] And a couple of these were B-Sides Portland, some 503 Party badges, 44Con in London, TRCon, [03:06.320 --> 03:10.460] which has kind of evolved into the Dan Initiative now. [03:11.380 --> 03:12.980] So yeah, they look cool. [03:12.980 --> 03:14.480] And you want them to look cool. [03:14.480 --> 03:18.340] And as a conference organizer, you want people to say, oh, this is a cool badge, take pictures [03:18.340 --> 03:22.180] of it, post it on social media, say, I can't wait until I come back next year. [03:22.180 --> 03:24.880] Conference organizers get more people coming and yada, yada, yada. [03:26.800 --> 03:28.200] Why else do we want badges? [03:28.200 --> 03:31.740] Electronic badges hopefully have some sort of interaction. [03:31.820 --> 03:35.780] And you can do interaction with a paper badge, but electronic badges are a little bit cooler. [03:39.780 --> 03:47.380] So this is a few years ago, Joe Grand's previous DEF CON badge, magic tokens, they had a piece [03:47.380 --> 03:48.620] of stone on the front. [03:48.620 --> 03:54.180] And he used a type of NFC, not like standard NFC, but like a near field communication, [03:54.180 --> 03:56.620] inductive communication method, which is pretty cool. [03:56.860 --> 04:00.720] But what happens, people go around, they go up to people they don't know, they interact [04:00.720 --> 04:02.480] with the badge, they meet people. [04:02.740 --> 04:05.840] That's kind of like the best part about an electronic badge. [04:07.160 --> 04:11.540] And also, like hopefully there's a lot, how many of you have ever designed a PCB before? [04:11.880 --> 04:16.840] How many of you have ever written embedded microcontroller code before, right? [04:16.840 --> 04:19.980] How many of you have hacked on a badge, an electronic badge? [04:19.980 --> 04:23.580] So hopefully the badge is an opportunity for you to get your hands on some hardware that [04:23.580 --> 04:24.980] you might not have otherwise done. [04:25.100 --> 04:31.040] So this one required a somewhat pricey programmer, but like once you had that, you could do whatever [04:31.040 --> 04:31.380] you want. [04:31.380 --> 04:34.640] There was also a serial port that you could interact with it, but like getting people [04:34.640 --> 04:38.420] to interact with tools and learn something is kind of a great goal. [04:39.620 --> 04:41.440] So why OpenTaxus? [04:41.640 --> 04:44.440] So anybody know what a badger is? [04:44.440 --> 04:47.720] The American badger, Taxidea Taxus. [04:47.820 --> 04:51.100] So this is the open badge, open badger, OpenTaxus. [04:51.680 --> 04:57.220] Not tax is like, you know, things you pay, not tax as the big state, but like taxes. [04:58.200 --> 05:02.080] And at some point I'm going to have a cool logo and it's going to be like a badger with [05:02.160 --> 05:07.100] a badge on that says OpenTaxus, but you can just visualize that right now. [05:07.520 --> 05:11.480] Or you know, go ask Dolly to make that during the talk and we can post it up there. [05:11.480 --> 05:12.700] You can do a pull request. [05:13.180 --> 05:14.880] So it's open, right? [05:15.020 --> 05:17.880] This is the URL right now, OpenTaxus. [05:17.880 --> 05:22.720] And that is kind of like the sanitized, cleaned up version that has like all the strings for [05:22.720 --> 05:25.860] specific events and all the logos and stuff removed. [05:25.860 --> 05:30.060] So you can go and like copy this and make it and not have to worry about like infringing [05:30.060 --> 05:33.680] on anyone's artwork, copyright, or all these detailed crappy things. [05:34.960 --> 05:40.220] So yeah, I'll put this URL up later, but I think it's the only thing on GitHub called [05:40.220 --> 05:41.600] OpenTaxus right now. [05:42.800 --> 05:44.420] So it's custom, right? [05:45.160 --> 05:49.400] Off the shelf is kind of cool, like if you have something interesting, but there's really not a [05:49.400 --> 05:50.640] lot of off the shelf options. [05:50.640 --> 05:57.660] And one cool one we did a few years ago for besides, for 503, DC503's badge was we had [05:57.660 --> 05:58.340] these little devices. [05:58.340 --> 06:00.780] They were like this big. [06:00.780 --> 06:05.400] They were smart response things, so they're made for classrooms where you like you answer [06:05.400 --> 06:07.100] questions, the teacher pops up on the screen. [06:07.100 --> 06:07.920] But we took them. [06:07.920 --> 06:11.100] We've reflashed the firmware with a couple games and use that as a badge. [06:11.100 --> 06:12.540] So we didn't design hardware. [06:12.540 --> 06:15.820] We just took pre-made hardware and programmed it, which is kind of cool. [06:16.620 --> 06:17.640] But this is the process. [06:17.640 --> 06:20.040] I mean, we go through prototyping phases. [06:20.040 --> 06:23.460] We, you know, have an actual badge and then like we have a second iteration. [06:23.460 --> 06:26.480] This is besides San Francisco's badge, which is essentially the same hardware. [06:27.460 --> 06:32.540] But, you know, like two conferences, two badges, somewhat similar, but it's okay because [06:32.540 --> 06:34.460] there's a lot of conferences and there's a lot of badges. [06:36.040 --> 06:38.800] So open, custom, and we also want it to be cheap. [06:39.980 --> 06:44.680] My objective is that, like, there's a lot of change in the microcontroller world lately. [06:44.680 --> 06:50.240] This uses the RP2040, which is the predecessor to the fancy chip that's on a Defcon badge. [06:50.380 --> 06:52.060] It's amazing because it's dirt cheap. [06:52.060 --> 06:57.360] In quantity, it's like 60 cents, and that includes, like, USB interface. [06:57.360 --> 07:01.420] So, like, there's a lot of extra chips you need sometimes to interface with the badge [07:01.420 --> 07:03.420] easily, and this doesn't need them. [07:03.420 --> 07:05.040] So it is extra cheap. [07:05.920 --> 07:09.000] Something else I've learned is when you get stuff assembled overseas, you know, if you [07:09.000 --> 07:13.200] go to a manufacturer that, like, does a lot of it, you know, if you wanted to assemble [07:13.200 --> 07:15.220] 100 badges, you need 100 chips. [07:15.220 --> 07:17.580] You buy those chips, you get the 100-chip price. [07:17.820 --> 07:22.140] If you go and get them assembled and you get 100 badges assembled, they get the chips at [07:22.140 --> 07:28.560] the 1,000 or 10,000 or real price, right, real R-E-E-L, which is also the R-E-A-L price [07:28.560 --> 07:30.720] that, you know, manufacturers get to pay. [07:30.720 --> 07:35.460] And so I've actually found that, like, for prototyping, it's cheaper for me to get a [07:35.460 --> 07:40.440] prototype assembled than it is for me to get the PCBs and buy the parts and assemble it [07:40.440 --> 07:44.880] myself, which is kind of a weird world we're in. [07:44.880 --> 07:47.100] So, yeah, right now, this is the last iteration. [07:47.100 --> 07:55.800] These were $5.70 each plus some engineering costs, which I think is pretty cool. [07:55.800 --> 07:59.280] $6 for a hardware badge that interacts is kind of a nice target. [07:59.280 --> 08:00.140] I was aiming for $5. [08:00.140 --> 08:04.180] Actually, I started aiming for $10, and then I went and did some cost reduction and managed [08:04.180 --> 08:07.480] to swap out some cheaper components and got it down to almost $5. [08:07.480 --> 08:09.360] So long run, $5 is the goal. [08:09.600 --> 08:12.500] Oops, cancel, cancel. [08:14.380 --> 08:16.500] Apologies for the AV situation. [08:16.500 --> 08:18.120] It's a little bit interesting. [08:18.460 --> 08:20.900] So I want to encourage interaction. [08:20.900 --> 08:23.160] So a badge has to have a way to communicate. [08:23.760 --> 08:26.380] However, we're hackers, we're privacy-minded people. [08:26.380 --> 08:28.800] We don't want these things broadcasting all the time, right? [08:28.800 --> 08:31.880] So what I opted for was infrared communication. [08:31.880 --> 08:36.420] What I like about infrared is that you can make it pretty short range, right? [08:36.420 --> 08:40.420] You can have it only work when you need it to work, and you can, like, you know, [08:40.420 --> 08:42.220] not use it if you don't want to. [08:42.300 --> 08:49.740] So this device has a little IR LED, right, right here, and an IR receiver right here. [08:49.740 --> 08:53.620] So when you line badges up, they, like, kind of flash lights at each other. [08:55.240 --> 08:59.760] And yeah, bill of material costs for the communication on this badge, $0.08. [09:01.140 --> 09:06.940] So compare that to, like, an antenna, which is going to be more than $0.08, or yeah, anything else. [09:07.000 --> 09:11.420] So I thought that was kind of awesome that I was able to get it that cheap. [09:11.820 --> 09:14.120] Braden Lane, he has done, like, e-challenge coins. [09:14.120 --> 09:19.060] He actually designed this IR circuit, and I asked him for a schematic and parts, [09:19.060 --> 09:20.340] and he shared it with me. [09:20.340 --> 09:24.760] So, you know, I appreciate his contribution to this, because, like, yeah, he was in the same boat. [09:24.760 --> 09:26.900] He wanted IR communications, but he wanted it to be cheap. [09:27.660 --> 09:31.260] I literally just got my DEF CON badge, like, an hour ago. [09:31.280 --> 09:36.040] So I haven't poked at this infrared communication, so I don't know what it is, whether it's modulated. [09:36.060 --> 09:38.240] But what this does is it basically speaks, it's a UART connection. [09:38.240 --> 09:39.120] You know what UART is? [09:39.140 --> 09:40.220] Serial connection. [09:40.540 --> 09:43.920] And, like, nothing fancy, just spit that UART over an LED, and it goes up and down, [09:43.920 --> 09:46.100] none of the modulation, no extra transceivers. [09:46.240 --> 09:48.200] And in the other end, you just have to do a little bit of cleanup. [09:48.200 --> 09:50.240] Downside, it's wicked slow. [09:50.520 --> 09:52.200] Upside, it's dirt cheap. [09:52.400 --> 09:53.280] Tradeoffs. [09:55.520 --> 09:57.700] So I want to encourage learning. [09:58.040 --> 10:04.580] And the original idea for this badge came from B-Love, Brandon Levine, [10:04.580 --> 10:08.540] and he wanted to do something in CircuitPython, because he was not an embedded programmer, [10:08.540 --> 10:09.560] but he knew Python. [10:09.560 --> 10:12.860] I had never used CircuitPython before, and so I was introduced. [10:12.860 --> 10:15.920] At first, I was like, yeah, that's a little high overhead for an embedded system. [10:15.920 --> 10:19.160] We're going to do, like, C, and we're going to maybe do some hand-coded assembly. [10:19.380 --> 10:21.740] But that's because I started doing microcontrollers 20 years ago, [10:21.740 --> 10:23.000] when that's the way to do it. [10:24.260 --> 10:27.720] 25, 30 years ago, when, you know, you had to pay for a compiler. [10:28.200 --> 10:32.900] And then, you know, I kind of did work for a while, and then when I left work, [10:32.900 --> 10:35.760] it's like, oh, I can play electronics for fun, and Arduino happens, right? [10:35.760 --> 10:38.600] So now we could plug things in with a USB cable, download one thing, [10:38.600 --> 10:41.060] get our compiler and all our tools, and that was great. [10:41.060 --> 10:44.760] But now, CircuitPython, you don't need a compiler, you don't need anything, [10:44.760 --> 10:48.720] you just plug in a USB cable, you have a USB flash drive that shows up, [10:48.720 --> 10:53.920] and there's a code.py file, and you edit it, and it runs, right? [10:53.920 --> 10:58.560] So your IDE is whatever text editor you want, and, yeah, [10:58.560 --> 11:00.280] you don't have to download or install anything. [11:00.280 --> 11:01.860] I think it's amazing and wonderful. [11:02.200 --> 11:05.540] It does have tradeoffs, but, like, objective here is something accessible, [11:05.540 --> 11:06.960] something that gets people playing with stuff. [11:06.960 --> 11:08.340] How many of you know Python? [11:08.880 --> 11:12.300] How many of you can hack your way through and, like, edit something in Python, [11:12.300 --> 11:14.560] even if you don't call yourself someone who knows Python? [11:14.720 --> 11:18.460] Well, how many of you have used CircuitPython or MacroPython on an embedded device? [11:18.600 --> 11:20.000] Okay, give it a try. [11:20.000 --> 11:24.740] I actually, so I've only got, like, 80 of these with me, but I'll give them out afterwards. [11:24.740 --> 11:28.600] And so if you feel like you want to either tinker with this or think you might have interest [11:28.600 --> 11:31.420] in contributing anything to this project, I've got them for you. [11:31.420 --> 11:34.720] If you just want something to, like, hang on your neck, then, like, [11:34.720 --> 11:38.300] let people who want to work on them first get them first, and then we'll have the rest available. [11:38.300 --> 11:38.940] Sound good? [11:41.000 --> 11:43.060] So, easy. [11:43.380 --> 11:44.780] Badges are not easy. [11:44.780 --> 11:46.080] Hardware is not easy. [11:46.080 --> 11:49.160] It's not called easy-ware, okay? [11:49.160 --> 11:50.880] So, it's hard. [11:50.880 --> 11:52.200] It's going to be difficult. [11:52.200 --> 11:54.260] You need to go through multiple revisions. [11:54.440 --> 11:56.300] And, yeah, so you should do that. [11:56.560 --> 12:00.280] So, here is, so, actually, the background story for this one. [12:00.280 --> 12:02.180] This is the LabsCon 2023. [12:02.180 --> 12:05.600] LabsCon is a threat intelligence conference down in Phoenix. [12:05.600 --> 12:06.920] It's pretty cool. [12:06.960 --> 12:08.700] It's very unique and niche. [12:09.880 --> 12:17.280] But, I got home from DEF CON at, like, August 16th or 15th or something. [12:17.280 --> 12:18.440] I don't know when it was. [12:18.440 --> 12:20.440] And it's like, okay, we've got five weeks. [12:21.020 --> 12:22.060] We can do this. [12:22.820 --> 12:24.280] And we did, right? [12:24.300 --> 12:28.080] So, we've got the cardboard mock-up to kind of, like, figure out what we're going to do. [12:28.080 --> 12:30.360] We've got the little PCB mock-up. [12:30.360 --> 12:32.760] This is the IR communication circuit that I prototyped. [12:32.760 --> 12:36.080] I'm like, okay, I know I can get a RP2040 working. [12:36.080 --> 12:37.740] I can get an IR communication working. [12:37.740 --> 12:41.340] I did a PCB layout and I milled a sample one. [12:41.340 --> 12:43.660] I didn't actually mill a functional prototype. [12:43.660 --> 12:46.860] I just kind of used it to make sure I got the sizes and placement right. [12:47.420 --> 12:52.960] And then a quick turn prototyping from, I believe, this one was JLCPCB. [12:53.120 --> 12:55.860] So, for, I think these were, like, under 10 bucks each. [12:56.340 --> 12:58.520] I ordered them on Monday. [12:58.520 --> 13:00.340] No, Sunday night, so Monday in China. [13:00.340 --> 13:01.820] I received them Friday. [13:01.920 --> 13:03.460] I was kind of, like, amazed. [13:03.880 --> 13:07.200] Of course, during that time, I did, like, you know, like, little updating tweaks here and there. [13:07.200 --> 13:08.180] I added some artwork. [13:09.020 --> 13:09.580] But, yeah. [13:09.920 --> 13:12.820] And, of course, you see, you will make mistakes. [13:12.820 --> 13:16.440] So, like you see here, I've got that little blue wire that happens to be black. [13:16.780 --> 13:17.640] Because, oops. [13:19.180 --> 13:20.680] And DRC is your friend. [13:21.700 --> 13:22.560] Unless you're lazy. [13:22.560 --> 13:23.160] Then you skip it. [13:23.160 --> 13:23.720] But, whatever. [13:23.960 --> 13:28.540] And, actually, you can see up here, I had a pinout wrong for what I was using at the time, which was an IR transceiver. [13:29.740 --> 13:31.500] And, yeah. [13:31.960 --> 13:34.900] So, I had to add that, change it a little bit. [13:34.900 --> 13:35.900] Screen goes on top. [13:35.900 --> 13:37.720] I like it because it hides all the components. [13:38.740 --> 13:40.500] And that was the prototype. [13:40.500 --> 13:41.140] And it worked. [13:41.140 --> 13:41.900] Which was kind of amazing. [13:41.900 --> 13:43.560] Just one blue wire and one component. [13:43.560 --> 13:44.880] So, we cleaned up that component. [13:45.700 --> 13:46.860] Got the PCBs made. [13:46.860 --> 13:50.860] So, what I did at the same time is I did the bulk order from JLCPCB. [13:51.420 --> 13:54.280] As well as, like, a small batch order. [13:54.500 --> 13:58.120] So, what happened is I got the small batch prototypes a week later. [13:58.420 --> 13:59.120] You know, I ordered. [13:59.140 --> 14:00.380] So, I received Friday. [14:00.380 --> 14:01.560] Spent all weekend working on it. [14:01.560 --> 14:05.740] Monday, ordered the second batch of prototypes. [14:05.740 --> 14:08.800] Thinking they're going to be perfect and just work. [14:09.300 --> 14:10.840] And those came the following Friday. [14:10.840 --> 14:12.080] Which, again, is amazing. [14:12.960 --> 14:14.180] And in the meantime, [14:14.940 --> 14:16.320] finalized all the artwork and everything [14:16.320 --> 14:18.440] for the actual, like, production run. [14:18.600 --> 14:20.440] I did make a couple other tiny tweaks. [14:20.680 --> 14:23.020] Turned out we got the production run in. [14:23.060 --> 14:24.800] Took them two weeks. [14:24.800 --> 14:27.280] Was kind of incredible for a few hundred badges. [14:27.600 --> 14:28.820] And they shipped. [14:28.820 --> 14:30.420] And, actually, we had room for [14:30.960 --> 14:33.520] a week of customs holdup on these badges. [14:33.640 --> 14:34.560] Because I was [14:34.560 --> 14:37.320] renovating my house, so we were living somewhere else. [14:37.360 --> 14:38.480] So, apparently, [14:38.480 --> 14:40.480] it was a unique address that [14:40.480 --> 14:43.000] I don't know, maybe customs just let stuff go to my home [14:43.000 --> 14:45.080] address and thought that this was a different [14:45.080 --> 14:46.820] address, so it's not Joe. I don't know. [14:47.540 --> 14:48.940] That, or they put too high a price [14:48.940 --> 14:50.320] on the invoice. [14:50.980 --> 14:52.680] So, but that's the badge we got. [14:52.680 --> 14:54.820] I did have to manually solder on the battery [14:54.820 --> 14:56.820] holders and the screens. That was a time constraint [14:56.820 --> 14:58.340] issue. I really [14:58.940 --> 15:00.860] am frustrated by screens. It's very difficult [15:00.860 --> 15:02.460] to get screens that are [15:02.460 --> 15:04.880] quality and reliable and consistent. [15:05.000 --> 15:06.860] So I use modules, right? You can get [15:06.860 --> 15:08.740] the modules cheaper than you can get the bare LCD [15:08.740 --> 15:10.920] OLED displays. So I might [15:10.920 --> 15:13.040] as well just use those, right? [15:13.080 --> 15:14.700] And the second [15:14.700 --> 15:16.360] iteration, so we went from [15:17.120 --> 15:18.820] this prototype for what was [15:18.820 --> 15:20.660] LabsCon, and then B-Side [15:20.660 --> 15:22.800] San Francisco was looking for a badge. And I [15:22.800 --> 15:24.760] had a conversation which roped [15:24.760 --> 15:26.520] me into another project. And [15:26.520 --> 15:28.800] so, basically, the only change in [15:28.800 --> 15:31.240] the circuit had to do with the IR circuit. [15:31.240 --> 15:32.640] I took off that transceiver [15:33.160 --> 15:35.020] that was up here. That was an IRDA [15:35.020 --> 15:37.400] transceiver. It was a [15:37.840 --> 15:39.680] $3 part. It was there [15:39.680 --> 15:42.180] because I had it and tested it and it worked. [15:42.180 --> 15:43.700] And that's when I changed it to these [15:43.700 --> 15:47.160] $0.08 of components, which were great. [15:47.160 --> 15:48.080] So, yeah. [15:48.080 --> 15:51.440] The prototype was pretty quick. The production [15:51.440 --> 15:51.780] badges took [15:51.780 --> 15:54.180] a little longer than expected. I used a contract [15:54.180 --> 15:56.420] manufacturer that I use regularly for [15:56.420 --> 15:58.300] Tigard. Shameless plug, Tigard is [15:58.300 --> 15:59.220] a little orange PCB that does JTAG, UART, and [15:59.220 --> 16:01.140] SPI. And I make it and use it for my [16:01.140 --> 16:03.140] classes. But, apparently, other people [16:03.140 --> 16:04.980] like it, too. So, you can get it on a crowd [16:04.980 --> 16:05.580] supply. [16:07.380 --> 16:08.960] So, I had that manufacturer do it because I've [16:08.960 --> 16:10.960] worked with them in the past and they will do [16:10.960 --> 16:11.940] stuff like custom [16:13.020 --> 16:14.900] solder mask color. And what they did [16:14.900 --> 16:17.060] for this badge... Oops. Do I not have [16:17.180 --> 16:18.660] a picture of it? Oh, no. [16:18.820 --> 16:21.660] So, what they did for us for the [16:22.040 --> 16:22.920] B-Side San Francisco [16:22.920 --> 16:24.520] badges, we had two different [16:25.800 --> 16:27.240] colors of silkscreen. [16:27.620 --> 16:29.460] So, they lined up perfectly. [16:29.580 --> 16:31.140] Actually, I want to do something [16:31.140 --> 16:33.420] silly. I'm going to modify [16:33.420 --> 16:35.540] my presentation on the fly. [16:35.660 --> 16:37.640] I'm going to take a picture. [16:41.390 --> 16:43.090] You don't see this on the screen yet, but... [16:46.950 --> 16:48.030] There we go. [16:51.110 --> 16:52.090] Can you see it? [16:53.330 --> 16:55.130] How come you can't see it? It's right there on the screen. [16:55.130 --> 16:56.530] Maybe I have to go back and forth. [16:57.310 --> 16:58.230] No? [16:59.210 --> 17:00.690] I see it right here on my [17:00.690 --> 17:02.790] slides. Oh. [17:03.210 --> 17:05.190] I'm very confused right now. [17:12.070 --> 17:13.570] I hope that you've been seeing the [17:13.570 --> 17:15.750] same thing as me all along because I'm [17:15.750 --> 17:17.490] literally looking at my slides right now and it's different [17:21.970 --> 17:22.430] from... [17:22.430 --> 17:23.470] Sorry. [17:25.830 --> 17:27.370] Oh, well. [17:28.050 --> 17:29.970] This badge is cool because it's got [17:29.970 --> 17:31.630] two different colors of silkscreen. [17:31.690 --> 17:34.310] It's like a cream, kind of off-white, grayish [17:34.870 --> 17:35.910] solder mask. [17:35.910 --> 17:37.710] And then a red and a black silkscreen. [17:38.610 --> 17:39.670] We'll talk about it in a second. [17:39.670 --> 17:42.150] The reason you pay for a contract manufacturer instead of a quick turn [17:42.150 --> 17:44.030] place is they'll do things [17:44.030 --> 17:46.030] like make sure those colors line up perfectly. [17:46.030 --> 17:47.590] And they did an amazing job. [17:47.590 --> 17:49.010] It was better than I expected. [17:49.230 --> 17:51.790] We have to realize that PCBs are precision things. [17:51.990 --> 17:54.150] There is some effort to make things precise. [17:55.330 --> 17:56.050] Silkscreen is [17:56.050 --> 17:58.230] kind of like the last thing and it's usually only documentation. [17:58.230 --> 17:59.690] It's not functional. [17:59.870 --> 18:01.890] There's some more slop in the silkscreen [18:01.890 --> 18:03.990] than there is in the solder mask [18:03.990 --> 18:05.230] and metal layers. [18:05.830 --> 18:08.110] Anyway, afterwards you can come up [18:08.110 --> 18:09.490] and see some of these badges. [18:09.490 --> 18:10.630] There's a bunch here. [18:10.630 --> 18:13.050] You can ogle the artwork. [18:13.790 --> 18:15.190] So what's my vision? [18:15.210 --> 18:18.030] I mentioned before I don't like doing this over again. [18:18.330 --> 18:20.010] And people are frequently asking me [18:20.010 --> 18:21.830] for badges and others. And rather than [18:21.830 --> 18:24.070] have to be involved [18:24.070 --> 18:25.930] in the loop, it'd be really cool [18:25.930 --> 18:27.510] if I had a website. You go to the website [18:27.510 --> 18:29.350] and you type in your conference name. [18:29.730 --> 18:31.130] You upload the logo for the [18:32.530 --> 18:33.410] conference. [18:34.790 --> 18:36.070] And you click go. [18:36.070 --> 18:38.050] You get your board files, your bill of materials, [18:38.050 --> 18:40.370] your code, everything ready to go. [18:40.370 --> 18:41.390] Does that sound cool? [18:42.250 --> 18:43.450] So what you can do then [18:43.450 --> 18:45.630] is instead of having to start from scratch [18:45.630 --> 18:47.310] and go through three iterations of prototypes [18:47.310 --> 18:49.390] and test everything and find the right components, [18:49.390 --> 18:51.210] you start with something that works. [18:51.490 --> 18:53.010] And change what you want to. [18:53.010 --> 18:55.430] If you want to do board changes [18:55.430 --> 18:57.290] and layout changes or add components, [18:57.290 --> 18:58.950] you do that. But you start with a board file [18:58.950 --> 19:00.210] that's functional and works. [19:01.050 --> 19:02.950] You want to make just artwork changes, [19:02.950 --> 19:05.110] you can do that. But you've already got a board that works. [19:05.130 --> 19:06.690] If you want to keep the hardware exactly the same [19:06.690 --> 19:08.630] and change the game that it plays or whatever, [19:08.630 --> 19:10.750] how it interacts, you can do that. [19:10.990 --> 19:12.550] And that's actually what, besides Portland's going to [19:12.550 --> 19:14.650] likely use the same hardware, but they're going to have a completely [19:14.650 --> 19:16.030] different game that it plays. [19:16.270 --> 19:18.910] So customize what you want to do [19:18.910 --> 19:20.690] and keep what you want to keep. [19:20.690 --> 19:22.610] Make sense? Again, chief virtue [19:22.610 --> 19:24.690] of an engineer is laziness. [19:24.890 --> 19:26.610] So be as lazy as [19:26.610 --> 19:28.810] you think is appropriate and you'll be able to [19:28.810 --> 19:31.310] spend your time doing the things you want to do. [19:31.310 --> 19:31.970] So how many of you [19:32.610 --> 19:34.290] like PCB design? [19:34.990 --> 19:37.110] How many of you like embedded software? [19:37.610 --> 19:38.590] So you can go [19:38.590 --> 19:40.750] meet up with each other and work together [19:40.750 --> 19:43.130] or do one or the other. Make sense? [19:43.710 --> 19:44.370] Cool. [19:44.650 --> 19:46.670] So what can we do today? Because of the AV [19:46.670 --> 19:48.830] stuff, I'm going to finish my slides [19:48.830 --> 19:50.670] first and then I'll flip over to my laptop [19:50.670 --> 19:53.150] and do some walkthrough demo-y stuff. [19:53.210 --> 19:54.750] I'm not going to build a badge from scratch because [19:54.750 --> 19:56.790] it's not there yet, but maybe someone will [19:56.790 --> 19:58.590] submit a pull request and we can do that. [19:59.930 --> 20:00.870] So what can we do [20:00.870 --> 20:02.770] today? If you are a hardware person, [20:02.770 --> 20:04.870] you can just change the logo. That's easy. [20:04.950 --> 20:06.570] You can adjust the board footprint. [20:06.890 --> 20:08.790] I find the cutout shape of the [20:08.790 --> 20:10.730] board is really a neat thing to customize [20:10.970 --> 20:12.790] a badge because it looks neat. [20:13.930 --> 20:14.750] You can rearrange [20:14.750 --> 20:16.690] the layout. As it is right now, it's kind of [20:16.690 --> 20:18.150] ergonomically designed. [20:18.230 --> 20:20.230] I happen to be left-handed, [20:20.230 --> 20:22.690] but I wanted righties to be okay with it too [20:22.690 --> 20:24.630] so I put the button in the middle so all you people [20:24.630 --> 20:25.750] can use it. [20:26.830 --> 20:28.750] And also it hangs down [20:28.750 --> 20:30.690] so you see the logo and if you want [20:30.690 --> 20:32.710] to use it... okay. [20:33.110 --> 20:34.690] I still have power. [20:35.050 --> 20:36.250] I'm going to keep talking. [20:36.910 --> 20:38.610] You grab it and you point it at [20:38.610 --> 20:40.510] someone else and you trade. [20:42.350 --> 20:42.750] Ergonomically [20:42.750 --> 20:44.530] they hold each other edge-to-edge. [20:45.110 --> 20:46.690] Just making sure the screen is still on. [20:46.690 --> 20:49.170] You hold them edge-to-edge and they communicate. [20:49.530 --> 20:50.650] One of the flaws of the [20:50.650 --> 20:52.470] current design is I need to [20:52.470 --> 20:54.510] tune the IR transmission a little more because you [20:54.510 --> 20:56.370] literally have to hold them together like that [20:56.370 --> 20:57.990] for them to communicate. Maybe like [20:58.670 --> 21:00.570] a half an inch, but if they're more like an inch or more [21:00.570 --> 21:02.650] they don't work. Which is kind of good [21:02.650 --> 21:04.670] because then you're not transmitting and receiving noise [21:04.670 --> 21:06.310] and other people's stuff and whatever. [21:06.630 --> 21:08.390] Also by using a module, the module kind of [21:08.390 --> 21:10.330] shades the IR stuff so even [21:10.330 --> 21:12.590] if there happen to be lights, [21:12.590 --> 21:14.170] something crazy like that, [21:14.170 --> 21:16.610] you don't have some interference from that. [21:17.130 --> 21:18.550] Cool. If anybody's got [21:18.550 --> 21:20.590] any questions as I ramble on, please, yeah, [21:20.590 --> 21:21.470] what's up? [21:23.490 --> 21:24.530] Maybe we'll do that [21:24.530 --> 21:26.570] later. Sorry. Unless there's another [21:26.570 --> 21:29.050] mic. Nah. Okay. Sorry. [21:29.650 --> 21:30.690] I'll repeat your question [21:30.690 --> 21:32.290] if I could hear it, but I hear that more. [21:32.290 --> 21:34.690] I don't think he's asking any questions about boards. [21:35.010 --> 21:36.370] So what can we do? Change the logo, [21:36.370 --> 21:38.710] adjust the footprint. We can re-arrange [21:38.710 --> 21:40.430] the layout. So if we wanted to [21:40.430 --> 21:42.330] have it wider or different [21:42.330 --> 21:44.290] layout or if you really wanted to change the [21:44.290 --> 21:46.610] infrared to something else, you totally could do that. [21:46.750 --> 21:48.510] And you can hack it to pieces. The way I did [21:48.510 --> 21:50.530] the layout, I'll show you when I look through a key cad, [21:50.530 --> 21:52.730] is I have a bundle that's the microcontroller, I have a [21:52.730 --> 21:54.750] bundle that's the power circuit, I have [21:54.750 --> 21:57.150] a bundle that's the, what's it called? [21:57.150 --> 21:59.390] Infrared circuits. So you can drag those [21:59.390 --> 22:01.250] blocks around and route those blocks together [22:01.250 --> 22:03.230] or you can drag every single little [22:03.230 --> 22:05.710] resistor and component together. [22:05.710 --> 22:07.790] So, if you're a software person, [22:07.790 --> 22:08.530] you could change strings, [22:08.530 --> 22:10.350] you take the badge, instead of being open [22:10.350 --> 22:11.330] to access, you call it [22:12.390 --> 22:12.750] besides [22:14.910 --> 22:16.470] Gallifrey or something like that. [22:16.650 --> 22:18.510] And you can change the game text. [22:18.510 --> 22:19.690] Right now the game it plays, [22:19.690 --> 22:21.210] ever played Clue? [22:22.230 --> 22:24.470] So in Clue you have a deck of [22:26.110 --> 22:26.830] suspects, [22:26.830 --> 22:28.130] weapons, and locations. [22:28.370 --> 22:30.390] And you shuffle them, you draw one of each [22:30.390 --> 22:31.950] and you put them in an envelope to the side. [22:31.950 --> 22:33.830] And then you deal the rest out to everyone. [22:33.830 --> 22:36.230] In the process of the game, you're trying to figure out what [22:36.230 --> 22:37.910] everybody else has so you know what's missing. [22:38.330 --> 22:40.150] Same thing, what it does right now is it deals [22:40.550 --> 22:42.090] one clue to each person. [22:42.650 --> 22:44.130] And you can [22:44.130 --> 22:46.210] trade those around, you meet people, it trades the handle [22:46.210 --> 22:48.050] that you put into the badge as well as [22:48.050 --> 22:49.930] your clue. And when you get them all [22:49.930 --> 22:51.750] but one, you know the solution. [22:52.250 --> 22:53.790] Right now it's set up for eight games, but [22:54.230 --> 22:55.910] we won't go into the details of that. [22:56.210 --> 22:57.870] Besides, Portland's going to do a slightly different [22:58.610 --> 22:59.610] game as well. [23:00.230 --> 23:01.990] You can change all the game text. [23:02.130 --> 23:04.210] Right now, besides San Francisco, the AI [23:04.210 --> 23:05.690] theme they used, so it was a bunch of [23:06.950 --> 23:08.330] AI, it was a bunch [23:08.330 --> 23:08.590] of [23:11.190 --> 23:12.070] doomsday scenarios [23:12.070 --> 23:13.890] and it was a bunch of fixes, so you [23:13.890 --> 23:15.610] randomly put those together like [23:16.110 --> 23:17.390] T-800 saved [23:18.570 --> 23:20.250] something from Whopper or some weird [23:20.250 --> 23:21.250] thing like that. [23:23.110 --> 23:24.470] So, badge logistics. [23:24.770 --> 23:26.630] This can be very interesting, right? [23:27.010 --> 23:28.310] Did I miss a slide there? [23:28.670 --> 23:30.150] No, I think I got it. [23:31.750 --> 23:32.630] Sorry. [23:32.630 --> 23:34.290] So, who [23:34.290 --> 23:36.250] likes hand soldering? [23:36.390 --> 23:38.490] Who likes hand soldering [23:39.330 --> 23:40.250] a hundred badges? [23:40.290 --> 23:42.770] Who likes hand soldering a thousand [23:42.770 --> 23:43.810] badges? [23:44.270 --> 23:46.410] When I [23:46.410 --> 23:48.550] solder, I design around [23:48.550 --> 23:50.370] 0603 surface mount components [23:50.370 --> 23:53.470] because I used to be able to see them and do it by hand. [23:54.030 --> 23:54.810] I can't [23:54.810 --> 23:56.470] anymore because I'm old. [23:57.530 --> 23:58.730] So I use a microscope [23:58.730 --> 24:00.390] and I can still do them by hand. [24:00.390 --> 24:02.170] But if you're going to do something [24:02.170 --> 24:04.250] this is designed for mass manufacturing. [24:04.250 --> 24:05.950] This is not designed for hand soldering. [24:05.950 --> 24:08.610] So I use 0402 components, the really tiny ones. [24:08.790 --> 24:10.270] Which means I can fit them all [24:10.270 --> 24:12.270] on there easily and they're small [24:12.270 --> 24:14.450] and 0402 is a [24:14.450 --> 24:16.350] pretty reliable size. It gets smaller than that [24:16.350 --> 24:19.450] and sometimes you get a higher failure rate. [24:19.450 --> 24:20.390] So if you're going to hand solder [24:21.590 --> 24:22.330] what I often do [24:22.330 --> 24:24.610] is I actually will get the [24:24.610 --> 24:26.750] prototypes with all the small components [24:26.750 --> 24:28.090] assembled, right? And then I get [24:28.090 --> 24:30.310] those prototypes and I solder on the big stuff. [24:30.890 --> 24:32.230] For example, if I'm like trying to [24:32.770 --> 24:34.130] fine tune which microcontroller [24:34.130 --> 24:36.630] or I get parts locally that I want to use. [24:37.430 --> 24:38.550] Next is small batch. [24:38.550 --> 24:40.890] This is like JLCPCB, PCBWay [24:41.350 --> 24:42.230] and others. [24:42.670 --> 24:44.010] Macrofab in the United States. [24:44.210 --> 24:46.190] You just give them your design and tell them a little [24:46.190 --> 24:47.910] bit about the parts and they'll [24:47.910 --> 24:50.070] make the PCBs, assemble them for you and ship them [24:50.070 --> 24:52.490] to you. Which is pretty cool. [24:52.850 --> 24:53.770] And like I said before, [24:53.770 --> 24:55.870] sometimes it's cheaper for me to do that [24:55.870 --> 24:58.230] than it is for me to just buy boards and buy parts [24:58.730 --> 24:59.750] and waste my time [24:59.750 --> 25:01.210] assembling them. [25:02.370 --> 25:04.310] And then last is contract manufacturing. [25:04.310 --> 25:05.270] This is, you know, basically [25:06.510 --> 25:07.790] there's a weakening line between [25:07.790 --> 25:09.910] the small batch stuff and the contract manufacturing because [25:10.390 --> 25:11.770] a lot of the same companies do the same thing [25:11.770 --> 25:13.810] or outsource it to each other. Again, I have [25:13.970 --> 25:15.750] a contract manufacturer I've used for Tigard [25:15.750 --> 25:18.210] and also BitMagic's the logic analyzer. [25:18.230 --> 25:19.010] If you've heard of like [25:19.910 --> 25:21.670] NETV or the FOMU, like mini [25:21.670 --> 25:24.250] FPGA, those were all done by the same folks. [25:24.250 --> 25:26.210] The reason why I chose them is because they'll do [25:26.750 --> 25:28.710] custom solder mask colors for me. [25:28.750 --> 25:29.630] Yay! [25:30.930 --> 25:32.210] But yeah, once you're [25:32.210 --> 25:34.150] hitting a threshold of more than 100 [25:34.150 --> 25:36.210] you probably want to consider this. It will [25:36.210 --> 25:38.330] take you longer, it will cost more [25:38.330 --> 25:40.190] but it's more likely to get it right the first [25:40.190 --> 25:42.350] time which is really what you want to do. [25:43.370 --> 25:44.250] 100 badges [25:44.250 --> 25:46.290] in a contract manufacturer with one mistake is [25:46.290 --> 25:48.310] 100 badges you need to rework. [25:49.870 --> 25:50.470] And finally, [25:50.470 --> 25:52.170] flashing. Once we've got these badges [25:52.170 --> 25:54.090] even if we didn't change anything [25:54.090 --> 25:55.670] we still have to provision them. [25:55.990 --> 25:57.450] I've got a flashing rig here [25:57.890 --> 25:59.890] which basically you slot the badges in [25:59.890 --> 26:01.690] it pops into a USB port [26:02.710 --> 26:03.910] and they're all connected [26:03.910 --> 26:06.070] to a 7 port USB hub and [26:06.070 --> 26:07.890] I've got a couple scripts in there that will go through [26:07.890 --> 26:10.150] wait for a device to be attached and flash [26:10.150 --> 26:12.070] it. There was a small [26:12.070 --> 26:14.250] bug in that though because what it does is it's a [26:14.250 --> 26:16.470] Linux script and it goes, okay you've attached [26:16.470 --> 26:18.390] a device, let's mount it. What's the [26:18.390 --> 26:20.010] mount point? Okay, and now we want to [26:20.010 --> 26:21.590] wipe it first. So rm [26:25.050 --> 26:26.010] mount point [26:26.010 --> 26:27.310] slash star [26:28.350 --> 26:30.030] and then dash rf. [26:30.030 --> 26:32.230] So you want to remove everything on that drive [26:32.230 --> 26:33.870] and force it. [26:34.010 --> 26:35.570] Which is great until mount point [26:35.570 --> 26:37.850] for some reason doesn't exist. You pulled it out before [26:37.850 --> 26:39.950] you got the mount point and so that string is blank. [26:39.950 --> 26:42.170] So it's rm dash rf [26:42.170 --> 26:43.890] rm slash star dash [26:43.890 --> 26:44.970] rf. [26:46.090 --> 26:48.550] You know what I'm saying. It was bad. [26:48.550 --> 26:50.530] Luckily I was using a utility called [26:50.530 --> 26:52.550] p mount which runs as a user as [26:52.550 --> 26:54.510] opposed to having escalated privileges and running [26:54.510 --> 26:56.470] it as root and mounting because that would have [26:56.470 --> 26:58.330] been a much worse rm dash rf [26:58.330 --> 27:00.570] slash star. For those of you who [27:00.570 --> 27:02.370] are like more in the Windows world, that basically [27:02.370 --> 27:04.370] slash star is your root directory and everything [27:04.370 --> 27:06.450] on your system. So like it basically would hose [27:06.450 --> 27:07.910] your system if you did that. [27:08.470 --> 27:10.690] Yeah, that could have been a lot worse. [27:10.690 --> 27:12.210] Luckily it was discovered and found and fixed [27:12.610 --> 27:14.750] before we flashed all of our laptops [27:14.750 --> 27:16.150] instead of the badges. [27:18.630 --> 27:20.670] Flashing. We just talked about flashing. [27:20.890 --> 27:22.490] So common pitfalls. [27:22.690 --> 27:24.010] We got about halfway in [27:24.470 --> 27:26.350] which means I have about half the time to go and [27:26.350 --> 27:28.810] either look at questions or [27:28.810 --> 27:30.990] walk through the designs. [27:30.990 --> 27:32.570] Common pitfalls. I'm really [27:32.570 --> 27:35.170] going to emphasize one. Schedule. [27:35.290 --> 27:36.690] Give yourself more time [27:36.690 --> 27:38.510] than you need. Once you've done that, give yourself even [27:38.510 --> 27:40.470] more time. Add some buffer for [27:40.470 --> 27:42.670] manufacturing issues. Add buffer for [27:42.670 --> 27:44.470] an extra prototype run. Add buffer [27:44.470 --> 27:46.570] for testing [27:46.570 --> 27:48.610] and software and flashing and whatever. [27:48.930 --> 27:50.730] You'll use them. You'll make good use [27:50.730 --> 27:52.230] of them, but you'll use them. [27:52.830 --> 27:54.330] Part of the idea here is [27:54.330 --> 27:56.990] if you're starting with a known good badge, [27:57.390 --> 27:58.830] you can go get those started [27:58.830 --> 28:00.410] and get the badges manufactured [28:00.410 --> 28:02.170] and work on the software in parallel. [28:02.450 --> 28:04.750] Then you don't have to worry about getting your hardware, [28:04.750 --> 28:06.290] testing it, making sure it works. [28:06.470 --> 28:09.150] Just remove the steps you don't want to have to deal with. [28:09.690 --> 28:10.250] Cool. [28:11.350 --> 28:12.550] So, I'm going to go [28:12.550 --> 28:14.650] back and for those of you who wanted [28:14.650 --> 28:16.790] where did I put it? The URL. [28:18.410 --> 28:19.050] Somewhere. [28:19.050 --> 28:20.610] I put a URL. It's [28:20.610 --> 28:22.690] GitHub. Forget it. I'm going to switch over [28:22.690 --> 28:24.670] to my laptop now. I'll get [28:24.670 --> 28:26.470] that set up. I have some hardware [28:26.470 --> 28:28.350] design and code I can walk through. [28:29.230 --> 28:30.670] If any of you have questions, [28:30.670 --> 28:32.650] just come on up here and you can ask a question [28:32.650 --> 28:34.250] and I'll repeat it and then answer it [28:34.250 --> 28:37.030] as I do the walkthrough. Give me a moment and I'll swap up. [29:03.510 --> 29:06.310] Cool. [29:37.590 --> 29:43.330] Okay. I'm connected to this wire which goes straight to the TV. It was just where I was [29:43.330 --> 29:56.790] on a second ago. First device. Ah, checking that. Looks good. 1080p. [30:04.410 --> 30:14.850] Input 1, I'm outputting to it right now. It's on the internal Google TV right now. [30:15.590 --> 30:17.290] It's showing a Google TV. [30:37.110 --> 30:44.090] Well, that's not what I want to show you. We know the TV works. So, fingers crossed one more time. [30:55.010 --> 31:03.070] More and more. Thank you for your patience. [31:28.310 --> 31:44.840] Well, that's what I get for using Linux. So, I'm going to try something. If we can get this back up on the screen. [31:48.560 --> 31:57.860] So, let's see. Nope. No, we're good. We're good. Okay. We're doing it live. [32:02.040 --> 32:05.800] So, where am I? Can I get a volunteer? [32:06.860 --> 32:08.760] Jake, come on up. [32:15.040 --> 32:17.960] Do you want to just hold it and show my screen? [32:18.000 --> 32:18.560] Just hold it? [32:18.560 --> 32:22.600] Just hold it so we see the screen. Thanks. Everybody see that? I'll make it bigger. [32:23.080 --> 32:30.080] So, there's the slides. First, let's look at... can you hear me good? [32:31.620 --> 32:35.940] First, let's look at the B-side San Francisco badge so you can kind of see what's going on. [32:36.240 --> 32:39.200] We've got a schematic. I'm not going to go into the details of the schematic. [32:39.200 --> 32:42.140] We've got... can you see anything at all? [32:42.620 --> 32:48.000] We've got the RP2040, right? We've got some flash. We've got some IO pins. [32:48.000 --> 32:51.620] We've got our IR circuit that, you know, just kind of works. [32:51.660 --> 32:57.040] And we've got a USB interface that works. USB-C, which is great because everything should be USB-C. [32:58.020 --> 33:04.380] But, let's look also... so this is what the finished badge looked like. [33:05.500 --> 33:10.300] So, this is just in black because that's what I usually do, but you see it... [33:10.700 --> 33:14.400] Silk screen on the front, no components, makes it really easy to see, you know... [33:14.400 --> 33:17.160] Can you look closer? Yeah, there we go. [33:17.380 --> 33:21.380] Makes it easy to customize it because we don't have to worry about stuff. [33:21.380 --> 33:24.320] There are a few holes, like through holes. That's where the battery connector is. [33:24.320 --> 33:26.900] That's where the USB connector is. And that's where the string goes on. [33:26.900 --> 33:28.940] But I try to keep them near the edge to make it a little better. [33:30.280 --> 33:34.680] One thing B-Side San Francisco does is they use stickers to differentiate their badge types, which is kind of cool. [33:34.680 --> 33:40.380] So, if you really just want to fab this badge as is and just make stickers for your conference, like, you can totally do that. [33:40.380 --> 33:43.100] Like, you literally don't even need a logo when you go and order the boards. [33:43.420 --> 33:47.000] But, what we've got here is the controller in the middle. [33:47.200 --> 33:54.340] Up here, we've got the Raspberry Pi 2040, some flash, an I2C connector so you can, like, attach things to it. [33:54.380 --> 33:56.480] And then, yeah, IR circuits. [33:56.480 --> 34:00.660] So, let's look at the layout. [34:00.780 --> 34:02.400] How many of you have used KiCad before? [34:02.440 --> 34:06.060] How many of you have used any circuit board design software, CAD software? [34:06.560 --> 34:09.580] So, basically, it's a whole bunch of layers, right? [34:09.580 --> 34:14.140] And you make a schematic and then you make it into the layers of the board. [34:14.140 --> 34:16.440] And you actually physically place stuff around. [34:16.520 --> 34:19.420] I had mentioned before we have, oh, I de-grouped it. [34:20.840 --> 34:22.560] I have most of the things in groups. [34:23.600 --> 34:26.400] Here, we've got the IR, TX, and RX. [34:26.400 --> 34:32.400] So, if you wanted to move that around, you can move this whole bundle at once instead of having to go and move every single component and lay it out. [34:32.520 --> 34:36.560] And we'll flip the board over, view, flip board view. [34:37.160 --> 34:41.540] Oops, and then we'll, oh boy, the resolution is just kind of making this wild. [34:45.820 --> 34:50.400] Anyway, what we see here, footprint back, there we go. [34:50.400 --> 34:55.500] So, that's the silkscreen. That's the layer that we would want to remove and replace. [34:55.500 --> 34:57.800] If you wanted to see one example of what it looks like. [34:57.800 --> 35:03.080] Of course, boards are kind of looking top-down, so it gets flipped and rotated a lot. [35:03.540 --> 35:05.100] But, yeah, that's what you do. [35:06.140 --> 35:06.940] Next. [35:09.440 --> 35:14.860] Let's go over to, this is OpenTaxus straight out of the repository. [35:14.880 --> 35:17.020] The question before was what the URL is. [35:18.220 --> 35:20.740] GitHub slash securely fits slash OpenTaxus. [35:20.740 --> 35:23.860] But if you just search GitHub for OpenTaxus, you should get it. [35:23.860 --> 35:25.040] T-A-X-U-S. [35:25.800 --> 35:27.100] What's the difference here? [35:27.400 --> 35:30.020] There's none of the logos. My logo is not on there. [35:30.020 --> 35:31.800] The open hardware is on there. [35:32.880 --> 35:34.760] The conference logo isn't on there. [35:34.760 --> 35:35.900] There is the URL. [35:36.780 --> 35:37.860] So we can see it. [35:39.900 --> 35:41.980] Take a picture if you want. I'll wait a second. [35:43.440 --> 35:47.820] Take a picture of the screen, showing the tablet, taking a picture of my laptop, [35:47.820 --> 35:52.120] showing a device that happens to have the URL text rendered as an image. [35:52.800 --> 35:54.420] I mean, I think we need to do this anyway. [35:54.440 --> 35:57.280] I would take a picture with my phone right now, but I cracked the screen yesterday. [35:57.280 --> 35:57.820] So, oops. [35:59.060 --> 36:01.680] But, yeah, you can see it's the same layout, same design. [36:01.680 --> 36:04.380] And besides, Portland is literally going to use this exactly the same. [36:04.380 --> 36:05.200] Actually, that's not true. [36:05.200 --> 36:09.920] We're going to change R11 to a slightly different resistor value. [36:11.340 --> 36:14.220] But we don't need to worry about that right now. [36:14.220 --> 36:17.680] So, yeah, and then, again, this should look very similar. [36:17.680 --> 36:21.860] This is the... get it nice and close so we get the screen as the whole screen. [36:21.920 --> 36:23.120] There we go. Perfect. [36:23.300 --> 36:25.400] So, yeah, here is the board. [36:26.640 --> 36:29.160] Blank on the back and stuff on the front. [36:30.080 --> 36:34.560] One thing I'll mention, some people kind of like to shortcut and sometimes... [36:34.560 --> 36:35.880] Oh, you can see me in there, too. [36:37.440 --> 36:41.940] You try and shortcut and say, oh, well, you know, it's cheaper if we just get the plain boards. [36:42.300 --> 36:46.120] And the default selection is HASL. [36:46.120 --> 36:50.240] It's a leaded kind of metal cover, so it makes it easier to solder on the copper. [36:50.720 --> 36:51.960] But that's leaded. [36:51.960 --> 36:56.040] And if you're doing these badges and you're handing them out to people, don't use lead. [36:56.140 --> 36:56.740] Okay? [36:56.960 --> 36:59.180] There are a lot of people who will be like, oh, yeah, I'm old school. [36:59.180 --> 37:01.260] I'm just going to use leaded solder because, you know, whatever. [37:01.260 --> 37:03.080] It tastes salty when you eat it, but too bad. [37:03.960 --> 37:04.780] Use unleaded. [37:04.780 --> 37:08.880] It exists for a reason, and especially if you're going to be handing this to people and kids, [37:08.880 --> 37:11.280] and they're going to hang it around their neck and show it to their kids when they get home, [37:11.280 --> 37:12.520] and they'll put it in their mouth. [37:12.780 --> 37:16.240] You may want to put a bit of it on there just to make it like game cartridges. [37:16.240 --> 37:18.640] But, yeah, don't use lead. [37:18.720 --> 37:19.700] Figure it out. [37:19.700 --> 37:21.460] Get the equipment and learn how. [37:21.460 --> 37:29.160] I use SAC 305 solder, which is 3% silver and 0.5% lead tin. [37:29.160 --> 37:31.320] No, not lead. Tin. I don't know. [37:31.320 --> 37:35.240] But just do it. Get practice doing it if you're a soldering person, [37:35.240 --> 37:41.660] because it's the right thing to do for people who would otherwise get injured by lead. [37:41.820 --> 37:44.860] Anyway, so let's look next. [37:45.320 --> 37:47.600] Actually, I'll skip over because it's a little more visual. [37:47.600 --> 37:50.640] This is the dock, right? [37:50.640 --> 37:53.880] And so let me try and change it so you can see the dock better. [37:53.880 --> 37:56.360] Has anybody ever used OpenSCAD before? [37:57.120 --> 38:04.820] I love OpenSCAD because I'm like a console person, and OpenSCAD is like CAD for console people. [38:04.820 --> 38:05.560] There we go. [38:05.560 --> 38:06.140] So here... [38:06.140 --> 38:10.460] What do I do now? [38:14.540 --> 38:16.580] Oh, there's a button down here. [38:17.260 --> 38:20.320] No, that was the wrong button. [38:20.580 --> 38:21.940] There we go. [38:21.940 --> 38:27.580] So OpenSCAD lets you just basically draw boxes and spheres and all that stuff. [38:27.580 --> 38:30.720] And what you can see here is I've got... oh, why is it doing this? [38:31.200 --> 38:33.560] I must have a sticky key or something. [38:33.560 --> 38:35.300] So we'll look at it sideways. [38:35.340 --> 38:37.920] I've got a groove for each of the badges to slot in there. [38:38.140 --> 38:43.660] What I also have is it's parametric, so we can change the badge size right here without having to worry. [38:43.660 --> 38:45.860] So if we change the PCB, it's pretty straightforward. [38:45.860 --> 38:48.600] I like to put the USB port in the middle. It just makes it easy. [38:48.780 --> 38:54.440] And if we wanted to do a two-column version of it, not 23, we can go do that. [38:54.440 --> 38:56.240] And bam, you've got two columns. [38:56.240 --> 39:03.580] If we only wanted to do a double one, we can do two columns and one row. [39:04.580 --> 39:06.660] Bam, just a skinny one. [39:07.020 --> 39:07.820] Make sense? [39:09.120 --> 39:13.800] I've got that up here, so when I'm done talking, y'all can come up and take a peek at it. [39:13.980 --> 39:21.800] And again, I've got badges, so if you stick out all the way to the end and you're interested in contributing something or even just want to try these things out, come on up. [39:21.800 --> 39:23.520] I didn't bring batteries. I'm sorry. [39:25.120 --> 39:28.980] And actually, now I'm realizing that there's something in my slides I forgot to mention. [39:29.000 --> 39:30.360] But I'll get back to that in a minute. [39:30.360 --> 39:32.560] The last thing I want to talk about is code. [39:33.080 --> 39:34.600] It's all Python. [39:34.620 --> 39:38.120] Anybody who's used Python, you look at this like, okay, we import stuff. [39:38.180 --> 39:42.060] I have a bunch of libraries that I use specifically for this game. [39:42.060 --> 39:44.400] And then it's Python, right? [39:44.400 --> 39:47.740] We write Python code, and it actually works on hardware. [39:47.740 --> 39:49.140] And it's pretty awesome. [39:49.140 --> 39:53.700] The downsides of Python on embedded hardware is it sucks power. [39:53.740 --> 39:55.400] It uses a lot of battery. [39:55.880 --> 40:00.420] Which is why I used AA batteries. [40:02.020 --> 40:04.180] Yeah, no, I'll go back to that later. [40:04.220 --> 40:08.000] I used AA batteries because they're cheap. [40:08.740 --> 40:12.280] And because they have a battery holder that's inexpensive. [40:12.280 --> 40:16.840] You can ship them, you can transport them, you can take them through TSA. [40:16.840 --> 40:20.760] You don't have to worry about accidentally puncturing them and starting a fire. [40:21.200 --> 40:25.980] So unless you really know what you're doing, stay away from lithium batteries on badges. [40:26.620 --> 40:31.140] It's not as bad as lead on PCBs, but I feel like... [40:31.140 --> 40:34.240] We've got a badge here that was well done. [40:34.240 --> 40:37.020] Where they actually made an enclosure and protected the battery. [40:37.020 --> 40:41.500] If you aren't enclosing your lipos, then be extra super careful. [40:41.880 --> 40:44.220] Anyway, AA battery. [40:44.220 --> 40:46.500] Actually, I started out with a triple A. [40:46.500 --> 40:50.300] I used a double A because it didn't last very long the first time I did it. [40:50.300 --> 40:53.440] But then I've added some power save features. [40:53.440 --> 40:55.980] Somehow I should be able to look down here. [40:56.560 --> 41:01.280] Right there, tiny, maybe you can see it, is some circuitry. [41:01.520 --> 41:04.540] And what this does is it takes the 5 volts in over USB and boosts... [41:04.540 --> 41:07.600] Sorry, the 1.5 volts from the battery. [41:07.760 --> 41:13.740] And boosts it up to 3.3, which means you can use that battery all the way down to 0.8 volts before the thing cuts out. [41:13.740 --> 41:18.180] Use your whole battery. I used a lot of coin cells in the past. [41:19.000 --> 41:20.460] Which is great if you have a very small thing. [41:20.460 --> 41:22.680] If you're not running CircuitPython, 10 minutes, cool. [41:23.220 --> 41:26.040] Let me wrap this up and we'll chat. [41:26.640 --> 41:31.240] It's Python code. If you know Python, you can learn it pretty quickly. [41:32.060 --> 41:34.100] CircuitPython is made by Adafruit. [41:34.100 --> 41:37.320] They're a hobbyist electronics company based out of New York. [41:37.620 --> 41:41.480] And they make reference boards, development boards, all sorts of stuff. [41:41.480 --> 41:43.640] If you want to prototype something, that's where we started. [41:43.640 --> 41:48.220] We started with a bunch of Adafruit components, prototyped on breadboards. [41:48.360 --> 41:51.100] And ended up here with a custom PCB. [41:52.160 --> 41:54.880] And the last thing I'm going to show you is... [41:55.860 --> 41:57.600] Yeah, so let's skim through this. [41:57.600 --> 41:59.960] This is basically the provisioning. [42:04.930 --> 42:06.670] Not LSD. There we go. [42:06.850 --> 42:07.950] So this is the configuration. [42:07.950 --> 42:11.470] We've got a check.sh, which actually checks when you've got a solution. [42:11.470 --> 42:14.470] The genfiles.py is what... [42:16.810 --> 42:19.190] basically generates all the files for the game. [42:19.190 --> 42:22.830] So down below, you can see we have our strings. [42:22.870 --> 42:23.950] So our company options. [42:23.950 --> 42:26.710] Terral Corporation, Neodym Pulsion, Weyland-Yutani. [42:27.010 --> 42:30.150] The startup is Algify, iTech, whatever. [42:30.150 --> 42:31.690] And the tool is something else. [42:31.690 --> 42:35.170] And the string is, blank company has just announced an intent to acquire a startup [42:35.170 --> 42:37.970] to build the industry's most advanced AI-powered tool. [42:37.970 --> 42:41.030] And the solution is randomly chosen. [42:41.130 --> 42:42.730] And it comes out here. [42:42.910 --> 42:46.310] The way it does that is, basically, it goes through the options, [42:46.310 --> 42:49.310] randomly chooses one, generates a bunch of files that go on the badges, [42:49.310 --> 42:51.450] and then it signs the clues. [42:51.950 --> 42:55.070] And gives the public key out, with RSA-512, [42:55.070 --> 42:59.110] because just enough to last you a day, without someone wasting a few grand. [43:00.190 --> 43:02.750] And that'll let you make sure that people don't mess with your game [43:02.750 --> 43:05.510] by giving out fake clues, which could screw everything up. [43:05.510 --> 43:07.850] So, I'm going to stop here. [43:08.430 --> 43:10.450] I've said all the things I think I wanted to say. [43:10.450 --> 43:12.390] If you've got some questions, come on up here. [43:12.850 --> 43:15.130] And I can continue to talk to those out loud. [43:15.150 --> 43:17.590] But you can also come on up and grab some badges if you want. [43:18.170 --> 43:19.750] So, yeah, go for it. Thank you.