Embedded - 434: I Love It, It’s Exhausting
Episode Date: November 11, 2022Sarah Withee spoke with us about using an artificial pancreas, learning many programming languages, and FIRST robotics. More about the Open Artificial Pancreas System can be found at OpenAPS.org or in... their documentation. Some other pieces we talked about include: LoopKit: an automated insulin delivery app template for iOS github (some additional docs) AndroidAPS github (additional docs) Reilly Link is the communication method for some insulin pumps Orange Link is a Reilly Link compatible device to run OpenAPS To get involved with FIRST robotics, the place to start is FIRSTInspires.org Sarah’s website is GeekyGirlSarah.com. Her programming language comparison tool is Code Thesaurus: codethesaur.us/ If you want to see small algorithms written in different languages, check out Rosetta Code Transcript
Transcript
Discussion (0)
Welcome to Embedded. I am Eliseo White, alongside Christopher White. Our guest this week is
Sarah Withey, and we're going to talk about programming languages and pancreases.
Hi, Sarah. Welcome to the show.
Hi, thanks for having me today.
Could you tell us about yourself as if we met at She's Geeky
or some other technical event? Yeah, I like to use the term polyglot software engineer just because
I do software engineering stuff, but I tend not to stick in one language. So like work right now
is in Python. I do stuff on the side with the robotics group in Java.
I tinker on the hardware things in C++.
The tech community space has some management software that's in Ruby.
So I don't really stick with anything in particular.
I also mentor an all-girls robotics team here in Pittsburgh
and can be briefly seen speaking at conferences once in a while
and sometimes other places.
All right.
We want to do lightning round where we ask you short questions
and we want short answers.
And if we're behaving ourselves, we won't say,
are you really sure about Rust or anything like that?
All right.
What's up with Rust lately?
It came up in class, and so it's on my mind.
What is your favorite kind of M&M, past, present, or I will add, future?
Oh, wow.
I'm terrible at predicting the future, so I don't know if I'll go there.
But I do like the crispy M&Ms and also the ones with peanuts.
Not peanuts, pretzels.
Pretzels in them.
I do like peanuts, but pretzels are better.
I didn't know there were other kinds besides the regular peanut kind.
So now I feel like I need to have M&M tasting.
Do you have a favorite video game?
Ooh.
I'm playing lots of Splatoon lately, so Splatoon 2 and 3.
I do love The Legend of Zelda games, too.
Favorite programming language for quick little tasks?
Quick little tasks.
Maybe Python.
If you were a burglar and could only steal something that would cause inconvenience, what would it be?
Oh, I think I asked one of those on my Twitter question of the day once.
Shoot.
I'm like looking around my house right now and trying to think like, what would I do?
Maybe take all the light bulbs.
How many languages do you think
most software
engineers know
know as in like
could sit down
right now and
write some bit of
code in
yeah let's go with
that
okay
I don't know
two maybe
I would average
guess
do you have a
favorite fictional
robot
I was thinking about this earlier because I think I I would average guess. Do you have a favorite fictional robot?
I was thinking about this earlier because I think I saw this as one of the prompts.
I'm really amused by Marvin the Depressed Robot from Hitchhiker's Guide.
Not because he's necessarily like a really good robot, but I just appreciate sarcasm really well.
All right.
And Marvin's like particularly sarcastic on a regular basis.
If you could teach a college course, what would you want to teach?
Oh, gosh.
I saw that one and I couldn't quite think of a good answer.
I think I was going to go with like something completely not tech related and just be random and might be like soap making because it's kind of interesting.
So I saw that you gave, well, you've given a couple of talks about pancreases.
Yes.
Pancreasi, Pegasus, no, one of which was a very short Bang Bang Talk,
which was pretty good.
And I wanted to know more. Yeah. So I have an artificial pancreas.
And the reason I have an artificial pancreas is because I'm a type one diabetic. So basically
my body, for whatever reason, we don't really know why, it just stopped making insulin for things.
And so I do need insulin on a daily
basis, the 24-7 stream insulin pump, all those good things. But I also have an artificial pancreas
and this little device talks to my insulin pump and also talks to a glucose sensor that's on me
and tries to do some algorithms to figure out what's happening with my blood sugar at any
given moment and then automatically adjust to give me more or less insulin at any given moment depending on you know
if i'm starting to look like i'm going to go low or if i'm going to go too high it will auto correct
for those things is this like uh it sounds like a rice cooker with fuzzy logic you want it to go
just the right amount yeah so there's you measure it in milligrams per deciliter, and there's the magic numbers.
Normal people, you keep it between 70 and 100 automatically with your own body.
Diabetics are usually told to keep it under 180 and above 80 or something just to be on
the safe side.
So my pancreas kind of sees what's happening. If it's just
climbing up, it's like, oh, hey, you probably ate something or something's going on that's
making your blood sugar rise. We need to counteract that. So we give you insulin and
bring it back down. If I start to go trending downward, like I'm 100 and I'm falling five
points every several minutes, then it's just like, oh, bad things are going to happen in the near
future. So it actually cuts off my insulin supply to try and save me from ever actually reaching the low.
So it does a lot of automagic to try and keep me in this like magical range that I can kind
of define for it. But that's just software. Why isn't that attached to the pump or to the glucose monitor?
Good question. So it kind of depends where you're looking. In the beginning,
insulin pumps were, you know, when we think of like smart devices, it's actually kind of a dumb
device. Like you can, if you ate, you would have to pull out the device and kind of say, oh, give me so much insulin because I ate this much carbs.
And the glucose sensor will tell you the values of what your blood sugar is right now.
But both of these are kind of independent devices.
So a bunch of people got together, figured out how to reverse engineer certain pumps and then certain glucose sensors.
And then they wrote some scripts to kind of like make them talk to each other
essentially through a separate device.
And over time,
what's been kind of interesting is the medical device companies have just kind
of avoided it. Like we don't want to touch this automated stuff, you know?
But they've started to see like all, all these open-source hackery people,
like, tinkering with things
and actually getting even better
than their own products are.
And so they've slowly had to actually, like,
kind of change their pace.
Like, oh, hey, wait a minute.
We might actually have to start implementing some of this.
So in the past couple of years,
Medtronic, Tandem, is there another one?
I don't remember off the top of my head.
But they've started to release some of their own algorithms inside their devices.
Tandem is good.
A friend of mine runs it.
She really likes it.
I've met people that have had the Medtronic one and they absolutely hate it.
They said they would rather go back to older pumps that have been cracked and use the open pancreas systems.
I can understand from a medical device perspective why reading a value and being told a value, those are both safe.
Somebody else has to take responsibility if anything messes up.
But as soon as you connect them and make an algorithm that isn't just a above this,
you do that, and below this, you do that. It's a real, you makes you liable if it doesn't work for any one person.
Yeah. And that's why, like, that's the excuse they've tended to use. It's expensive. You got to
do a bunch of studies. It's complicated. It's weird. It's hard. But at the same time, the open source people have been kind of testing it on themselves. And there's a blood test you
can do. It's called an A1C. But basically, the percentage tells you essentially how close in
range your blood sugar values have been for the last three months. And they found this range is actually a lot better
for people that are on these open pancreas systems than it is for people either doing
themselves manually, which is usually not very good at all, or the ones done by
the med tech companies. And they're better, but the open source ones have been like really, really,
really good.
The people that developed the original algorithms, they actually have like white papers on them.
You can go read these papers, how they've did these studies, how they've looked at past
blood sugar values and then calculated like what the algorithm should be and then just
test it in on themselves, which is totally a thing you can do because you're not involving
extra companies and you're not involving extra
companies and you're not doing wide-scale research. You're just kind of doing it to yourself. So
that's fine. And they've just found your blood sugar values are amazing. In fact,
my blood sugar values have pretty much looked like a non-diabetic. It just looked like a
regular person's blood sugar values just because the technology has just been that good at doing what it does.
And part of the reason is because if you have a human in the loop, they're only going to do it
occasionally. And if you have a device, it has nothing better to do with his time.
Yeah, basically. So I get a new value from the glucose sensor
every five minutes. So every five minutes, it just runs the calculations. It's just like, hey,
is everything still going as expected? If not, give you more or less insulin. And it just does
that 24 hours a day. It's very strange to me. I've developed medical devices. So I have some
perspective from the medical device manufacturers, but also I'm
very sympathetic to, hey, I would like a product that improves my quality of life and you're not
creating it. Because you're too much of a wimp. Well, yeah, that's the thing is this market exists.
And I do know that what those devices are doing takes you from, as you said, one level of safety
to another level of safety to another level
of safety, which means a lot more documentation, a lot more verification, probably a 510k clinical,
whatever. But the market exists. So, and there's lots of much, for lack of a better word,
stupider medical devices that people put through studies that go for a long time. So it's very,
it's very strange to me that they haven't, didn't look at this before and say, this is a good market.
And even the monitoring devices, I mean, a glucose monitoring device, yes, you've added the human in the loop to self-inject glucose or whatever.
But if that screws up, there's a lawsuit there no matter what, too.
I mean, so, yeah.
But that's user error. not if the thing is reporting
the wrong value oh that's true but it's easier to report the right value i mean that that's a
yeah yeah that's almost provable case yeah and i mean like i've had it mess up where
i've gone low and my all my things say oh nope you're perfectly normal and i've had it mess up where I've gone low and my, all my things say, Oh, nope,
you're perfectly normal.
And I've had gone high when it said I'm perfectly normal.
And,
um,
you know,
there's,
you know,
mistakes happen and bodies are weird and it's really kind of impossible to
get it perfect every single time.
But at the same time,
this is the only like disease and-related things I've ever heard of, where basically
I'm given a blank check and a giant bottle of medicine, and they say, take whatever you
need, good luck calculating it, here's some basic ideas on how to get started, here's
what you do if it goes bad. By the way, you will likely
overdose, and here's how to counteract that. And it's like, you don't really do this with a lot of
other diseases. It's not two pills a day, twice a day. This is just basically like a bottle and,
I don't know, figure out how much food you ate and take that much insulin for it.
And it turns out people aren't always really great at calculating those,
especially if they're not really science-oriented.
So even taking part of the equations out
and putting them on a computer really helps dramatically.
That makes a lot of sense to me.
And I have a question here about open source
and how it can be hard for non-technical folks to
get used to. But then I also remember my mom making graphs and how bad she was at it.
So how hard is it to use the open APS?
It depends. There's multiple types of artificial pancreas system, which is what the APS
is. There's several different types. It depends on which one you're using, which ecosystem you're
in. So essentially like which pump and glucose sensor and phone you have. Depends on how easy it will be in the end. LoopKit is the one that's on iOS.
It's compatible with a variety of different pumps. It's usually pretty easy. It has a really nice
user interface. All the calculations are done on the phone. It just uses Bluetooth and a separate
little device to talk to the pumps, and it's pretty easy. There's also Android APS.
It's also fairly easy.
It's the one I use now.
OpenAPS was a little bit more difficult
just because it was basically a Linux device,
and it ran all the algorithms on it.
But it also meant I didn't have to do much.
It just kind of casually ran in the background,
and I didn't always have to have like my phone
all the time for it um it was a little bit more complicated just because you had to
like ssh into it as something went wrong and figure out kind of what happened but um they
they say on several of the manuals just like you don't have to be necessarily technical or
a programmer or anything you just have to be willing to
kind of learn the time to, or spend the time to work with the device. So like, you know,
kind of all technology, you need to kind of sit down and read the instruction manual.
With anything, with a bunch of variables, you kind of have to take the time to configure it.
So like the amount of insulin I need per carb is different
for me than it is for like you two. And so like your body's kind of automatically adjust for
whatever you eat. Mine doesn't. And it has changed over time too. So it's, you know,
periodically I kind of have to revisit, like, is this the same value I think it should be?
You know, if every time I'm eat, I'm going low most of the time, it probably means my math is wrong.
So I have to kind of like go back and tinker with it.
So it's like you have that problem whether you have the pancreas system or not.
Right, right.
And, you know, the pancreas system is kind of nice because there's ways to figure out how off your values are over
time so just as the statistics to see like oh hey you know you're you're taking um five units per
you know this many carbs right now we think that's really wrong you should be doing like
four units per this many carbs and can you imagine a medical company telling you that medical devices company no no no no because that's that's too close to
medical advice well yeah but it shouldn't but they're but pacemakers exist they're autonomous
yeah and they def and defibrillators implantable defibribrillators exist. So there's precedent for automatic,
autonomous devices that are managing life-critical systems.
But not ones that learn.
But the other thing is, I can always override something. So if I'm going low and the system's not really taking care of it, I can always stop it and take care of it too. So it's not like,
I mean, the pancreas devices they're
external like i keep a one in the little pouch and i wear it on my butt loops or in dress pockets or
whatever um but you know i can always turn it off i can always override things i can always
um tell it like hey quit doing the automated looping system. So it's just back to manual efforts or whatever, too.
So, you know, it's not like it's inside me and I can't ever touch it.
Right, right.
Whereas like some of the pacemakers are.
Were you involved with the development of any of the artificial pancreases?
I was not. I have fixed a couple bugs, and I started working on an easy-to-install system for OpenAPS when I was using it more often.
So it's really like, log into the device, update all your Linux packages, install this GitHub repo, run the install scripts.
And I kind of thought, this is stuff a person doesn't really have to do.
It's like something a computer could just plug it in and let a program do that for you.
And so I started writing something like that.
Kind of got pulled away from work and a bunch of other mental health things.
And I kind of stopped working on it.
And then the devices you use on OpenAPS
are a lot harder to find now.
So I just
haven't went back to working on that.
So I haven't really worked on the core of
the algorithms or the apps
or anything, but
I would love to. I have started
looking at Android APS's bugs
and pondered if I could fix any of
them, but
I haven't contributed there yet.
So what does the hardware look like?
Is this existing hardware that's been jailbroken,
for lack of a better word,
or is there a unit that's an open-source hardware unit?
Yeah, good question.
Or is it just a phone app?
Or all three.
Or multiple combinations of all the above. So OpenAPS was, when I
first started it, it was an Intel Edison chip. Oh, wow.
A system on chip. Yeah, Linux. You just kind of
SSH'd in and all the things. It was attached to
either 400, what, 430 megahertz
transmitter board or 900 megahertz transmitter board to talk to whatever
kind of pump you're using. And so it just, it was kind of small, fairly easy to tote around
until I quit making those chips. And then eventually the company that made the
transmitter boards went out of business. And so we can blame the pandemic for that.
But the next one is, it's called a Riley Link.
So instead of being like Linux on it,
it's just a simple device that accepts Bluetooth and transmits over 400 or 900 megahertz.
So it's essentially just kind of like a bridge.
So it expects your phone really to tell it
what to say to the pumps.
And it will just like send those signals um riley link um it's i don't know like one inch by a couple inches and it was like
half an inch thick so not too bad also like really easy to carry around like tic tac container sized
um and the one i use now it's called an orange link so it's actually in a container that's
specifically the size of an airpods case to like be able to be carried in like cases made for
airpods so it's you know still pretty small really easy all of these are open source so you can
actually like go online and see how they made the boards for them. The Riley link and I think Orange link is open source too.
But yeah, you can just like go get the schematics,
learn how to do them.
You could even build them yourselves
if you really wanted to.
And then as for the apps on the phones
that talk to that device,
they're all open source as well.
So LoopKit for iOS is what? LoopKit.github.io. There's Android APS. That's pretty easily
searchable. And then OpenAPS, I think, is just openaps.org. And you can just go look at the code,
read all the documentation. There's tons and tons and tons of documentation. So it's not just like,
install it, go figure it out yourself.
They guide people through all the settings and how to configure them for your pumps and your sensors and everything.
Because this is better.
Because this is actually safer.
Yeah.
And like I said, it's not perfect.
I still have my days where things go drastically wrong.
But there's so much fewer and farther
between and it's more accurate and it just does tiny little changes over time instead of
me doing like a large change after every meal. And it's just more accurate that way.
In the beginning, you talked about lots of languages, different languages you work with.
Why haven't you specialized?
That is a terrible question.
Let me try that again.
What languages do you like best and why haven't you specialized?
Dang it.
I guess I'm going to go with that.
I'm just picturing now like, Sarah, you haven't stuck to one language. What's wrong with you?
That's not what I mean.
I know. It's because you're not the first person to ask this. It's just like,
it just sounds funny that way, you know? I mean, I don't think it's that weird. I speak C and Python fluently and C++ with a little bit of a C accent.
And I've done awk and basic, so much basic MATLAB.
I mean, you take great pride in speaking multiple languages, multiple programming languages.
Do you speak multiple speaking languages?
That's okay.
I was going to say human languages, so that's not much better.
That works.
I took French in high school and was pretty good, but that was like 20 years ago and I've gotten considerably worse at French.
I started learning sign language and then stopped and then kind of relearned it and then stopped,
and I'm kind of relearning it again. So those might be, besides English, the other two languages
I've kind of learned for the human side. But yeah, for computers, it didn't start out me going,
I'm going to learn all these languages, and I'm not going to pick one.
I'm just going to do a new job, new language at every single job I land at.
It kind of sort of happened by accident, I guess, in that I learned BASIC when I was a kid and then computers got better.
I learned Visual BAS Basic when that came out.
I think my first college class was C++
and then Java after that.
And then I was learning PHP on the side
for something, I forgot what it was.
And just kind of over time,
these little dashes of extra languages
got blended into me.
And then when I started getting jobs after college,
one of the first places I was at was a bank,
and they kind of did this rotation program.
So I tried different teams to figure out which one I wanted to be permanently on.
And one of them was in C Sharp sharp and then the next one did some Java
stuff.
And then I think the next one was yeah,
I think it was going to be C sharp too.
And then I ended up just moving jobs over to a PHP job.
And I don't know,
it it's kind of interesting because I never intended to just say like,
I'm going to do a different language at every job.
But I think it's meant seeing so many different ways to do things and thinking through problems and, like, so many different types of ecosystems that I think it's made me a better developer.
Just because I have this, like, wide variety of knowledge on how things are done.
And so if you just throw me into a project,
I feel like I usually have a really good range of ways of solving problems.
And also just because I've been in so many different languages over the years,
I can probably get tossed into most anything
and hit the ground running with little effort. Like I'm not necessarily an expert in any of
these languages, but I know enough that I have an idea of what I'm doing and an idea of where to go
to find answers to solve those kinds of problems in that language.
So it's like,
I don't always know how to do everything in Python for like my day job,
but I know where to look to find those kinds of answers.
Is it stack overflow?
I mean, that's some of it, but also just, you know,
dabbling in Python over the years means I kind of know what kinds of packages I might need to look for to do different things. Or I know the different types of what's kind of built into the language, what's not built into the language.
And just can kind of poke around either Python's documentation or ask the right question on Stack Overflow, I guess.
But just also search through other types of materials
and kind of understand, you know, like what do I need to write myself?
What can I look in the library for?
What's built in the language?
Or do I need to kind of pick and choose from different places
to kind of assemble a solution?
Which language would you want to learn more thoroughly?
Oh, gosh.
That's a good question.
I think possibly something like Haskell,
just because I've dabbled in it before in a school project,
and then I did a job where I learned Scala.
But I wasn't particularly great at it.
But it's such a different way of thinking about problems.
I really would like to get a lot better at it.
It's one of the things that learning multiple languages, I think, did for me.
I don't know that many.
And ones I used to know, I've completely forgotten.
Pascal.
But like a recent one I had to do a lot of work with was Swift, which is a more modern language.
And it's very opinionated about certain things.
And it has, you know, built-in language features that kind of guide you toward a certain way of thinking about structuring your program.
But having learned that and seeing those things,
it's kind of easy going back to like C or something to say,
oh, this is something I can adapt.
This is a design pattern or kind of a way of structuring code that I can adapt.
So language doesn't really have the feature to do it, but it just feels like each language has its own kind of opinions about a lot of things, whether it be design patterns
or how to deal with memory,
and those aren't necessarily things that are siloed.
Once you've learned them in one language, you can kind of like,
oh, you know, I should be more object-oriented in this other language, even if it's not an object-oriented language.
Is there anything from Swift you can use as an example?
Was it messages I think you mentioned at some point?
Um.
Or contracts?
No, I'm trying to think.
There's ways of doing early exit from functions and doing what are called cards.
There's kind of the whole function pointer-y thing about having...
You can't really do lambdas in C, but you can do callbacks and stuff like that.
Kind of making things more asynchronous with callbacks and things.
That's probably the first thing that comes to mind.
There's other things.
And Swift is object-oriented, so it's closer to C++ than C.
But
object-oriented,
there's no reason why
C can't be.
You have to build the machinery.
You don't even have to use function pointers. You just have to think about
things as objects.
And try to corral them
into their own little kingdoms.
So do you find yourself doing that?
Like, oh, there's this Java language feature,
or there's this Java-ish thing,
but I'm writing in, I don't know, Python.
Yeah, I do that from time to time.
Like, we're in a project at work right now,
and it keeps reminding me of a whole bunch of problems
I solved in a C Sharp
web app several years ago
and I keep thinking like, oh yeah, we
did it this one way. I wonder
should I actually try and do it
that way here?
The problem's really close
enough that I should try to solve them the same way
and since it's
Python in this job and C Sharp in that
one, I'm trying to think what are the equivalents of some of these things?
Is it as efficient and tidy to do them a certain way?
We kind of wrote some terribly hacky ways of solving the problem in C Sharp.
But I also think they were creative solutions.
So it makes me wonder, what's out there?
You know, does Python have any of these kinds of things similarly built in a library somewhere?
You know, could I reinvent the solution?
And, yeah, I, you know, and it's one of those kinds of things, like, I think if you were, like, an expert in one language and then you were tossed into another one, you might actually struggle a bit. Whereas I've kind of done enough of these languages, I'm not really like as nervous about jumping around on a regular basis as I think some people are.
I know some people are. I am not as nervous as I used to be. I mean, a client asked me to do something in C Sharp and I was like, okay, fine.
The only thing I'd be nervous about
would be being tossed into a functional language
because I don't understand that stuff at all.
But regular stuff, fine.
They're all similar.
Yeah, and I do think one of the hardest things
is the paradigm shifts.
Like you're thinking about a problem in a different way. You know, it's like if you're writing something in
Perl, then you're like, oh, I'm going to write Haskell now. You know, it's like two totally different ways of thinking.
And that's a lot harder, I think, than
just jumping to a language that's similar, which is
why I think like C, C++, C Sharp, Java, PHP, all those are
similar enough.
You can kind of bounce back and forth between them
with little like friction, you know?
Yes, but if you go from Python back to C,
suddenly you have no ability to hit the semicolon key again.
Yes, yes.
That's also a little different.
Yes.
I took a two-year-long Python break
and came back to C for a client.
It was a mess for a while.
If you were starting a project from scratch, is there a language you would choose?
I don't know.
I'm very much the choose-the-right-tool-for-the-job kind of person.
So I don't know that I'd want to sit down and just say,
oh, I know this one the best, that's what i should do it in um i would probably try to think like what does the language work really well in where's the
you know ecosystem of like web frameworks or whatever you need around to help you with that
i also would probably think like if i'm on a team and there's a bunch of people that have different types of knowledge, what might be the least friction to get any of them up and going in it too?
Yes, I say that with people who want to do C++ and embedded.
Yes, absolutely, as long as your whole team is writing it.
But if you have one person writing C++ and four people writing C, everybody is going to be
unhappy. Yeah, that goes for anything. It goes for any language. Those two are just compatible.
I mean, I've often been on projects where people, it's a big legacy project, it's in C or C++,
and then people come in and want to, oh, we should rewrite this and blah, blah, blah. We're new,
you know, new people on the team. It's like, well, dude, you don't know what you're asking.
Not only are you rewriting all of the bugs we finally fixed.
But none of us know how to use this.
You're asking us to do something we don't know how to do.
Yeah.
That's not always trivial to learn.
Is there a language you know that it was easier to learn than others?
Oh, gosh.
The problem is once you've learned so many, the new ones just absorb a lot quicker.
The last one you learned is probably the easiest.
Yeah.
And, you know, it's hard to judge at this point, you know, because I think the first big transition was like basic to C++. And that kind of broke my brain in the beginning, just because I'm like, whoa, this is weird.
You know, I picked it up.
It, you know, turned out not to be like particularly hard, just different.
You know, and then, you know, Java wasn't too hard of a transition after that.
Neither was PHP.
But then, you know, like I had a school project that was Haskell, and that broke my brain for a little bit.
What else?
Yeah, and then when I took the job that did some stuff in Scala, it's just like, well, I had to kind of re-remember some parts of Haskell.
But it didn't break my brain nearly as much the second time.
Having seen Haskell.
Yeah.
And like Rust, I haven't used it, but I took a workshop on it.
And, you know, once they explained like, oh, basically think C++, but like a lot safer with types and memory management and all that.
Like, you know, it broke my brain kind of in the little beginning, but it didn't, you know, after like 30 minutes like 30 minutes like okay this actually makes a lot of sense and you know if i wanted to i probably could sit down and you know you know a
little a little bit more maybe reading up on it i could probably like get working in it pretty
quickly so it's i don't know i i don't there any languages you hate?
Not hate necessarily, but if a project comes up, I'm like, oh, this again.
I would program in Fortran again if it came up to it.
That's so sad.
I'm sorry, Sarah.
Languages you hate, not languages that I should but don't. Periodically, I kick myself when I land in something like JavaScript,
but like on the server side,
just because I tend to think in things like,
oh,
you start here and you run all these commands in order and JavaScript's like,
no,
I'm going to paralyze everything for you,
which is,
you know,
a cool feature.
But if you,
you know,
I kind of have to like turn off one side of my
brain and turn on the other side of my brain again and think like, okay, when nothing works right,
when I have like a bunch of empty variables in different places, because the parallelization
hasn't filled in the values for those yet, I kind of like always have to kind of kick and scream
just because I'm like, ah, I have to rewrite this in a different order and doing like asynchronous weights and stuff like that. And I get, I kind of, it's, it's not
bad. I just always have to like kick myself because I end up in the same problems every time.
The other thing is Rails. I think it's really cool, but there's a lot of like magic that just
sort of happens. And I'm one of those people that really wants to understand what I'm doing.
And so sometimes like if I land into a problem and then I go find the
solution for it,
the solution is just like,
Oh,
add this one line.
And I'm like,
I don't get why you add that line and how this line should work because
there,
there's a lot of cool stuff that Ruby's doing,
but it's kind of behind closed curtains and you can't really tell what's
happening.
So it's not that I hate these.
It's just every time I land in them,
I find myself just kind of scratching my head a little bit more than I
normally do.
Code thesaurus.
What's that?
Good question. It's an idea I came up with several years ago, hopefully to solve some of my polyglot problems, which is, this was like 2016 or something like that, where I was on a Slack community and somebody just randomly DM'd me and be just like, hey, Sarah, could you help me with this Ruby problem I have?
And I'm like, I don't actually know Ruby, but maybe I could try and help you find the problem.
And she showed it to me and I kind of looked at it and I'm like, I'm pretty sure your problem, you know, is on this one particular line in this spot.
But I don't know what the right answer is.
You know, it's like I know how I would do it in this other language, but I don't know how the right answer is. You know, it's like, I know how I would do it in this other language,
but I don't know how I would do it in this.
And I kept, like, trying to dig.
I couldn't word it correctly on Stack Overflow to get an answer.
I couldn't really find it in the Ruby documentation.
I couldn't really find it, you know, in several different places.
And I'm just like, ah, why can't I just look at these side by side?
Like, the language I know and the language I don't know side by side. And I kind of thought like
somebody's built this already, right? And so I go looking around the internet.
Yeah, couldn't really find anything exactly like this. There's cool things like Rosetta's code
and it shows you like how to solve problems in different languages, but it doesn't let you
compare languages themselves side by side.
And people sometimes solve the problems differently depending on the language.
And so I couldn't find this exact thing.
And so eventually kind of came to terms like,
I'm probably going to have to be the one to build this thing.
And so, yeah, I call it the Polyglot Developer Reference Tool.
And so you can choose a concept like functions or file
input output or strings or something
and then choose two languages
and you can actually look at how to do
a whole bunch of things in that concept
side by side in these two languages.
That's pretty cool.
How many languages
do you support
now?
I think we're up to 21. Should there be 21 languages? Sorry.
I don't know. Let's take the best features from all of them and make this 22nd.
20, 21, 22. Oh, 22 languages. And I know there's a couple PRs to add some new ones in.
So I think there's two more that are going to get added soon.
And so I can go there and say, what are the conditionals like in a language I know, like
C, and what would they look like in a language I don't know, like Haskell?
Yes.
Yes. Yes. And so you can look up ifs and loops and all that on, I think we call it control structures in there.
So it's like when you pull that up, it's just like, how would you do an if?
How would you do an else if?
How would you do a switch or a ternary conditional?
While loops, do loops, do, do until, do whiles for each loops.
And sometimes languages don't have these.
So we do have the built-in concept of, you know, specifying like, hey,
you know, this one language doesn't actually know how to do this thing.
This is really cool.
This would be very handy when you're learning a new language
or if you're well-versed in another language
and you have to use a different one.
Just because there's a bunch of times. Like, it's like when you're speaking language, like when you're learning a spoken language, initially you spend a lot of time translating in your head.
Like, okay, I'm speaking English in my mind.
And now what's the French thing?
And you construct that.
And that's not really being fluent.
But the same thing happens, I think, with programming languages okay i think and see and so if i'm in uh python then a for loop
that i would have in c to do and you know sometimes that's not the best way to do things
but it's the way to get started with you know accomplishing yeah that's how we learn yeah
yeah so i think of it as like a good, one, like a reference tool.
So like if you just like, oh, shoot, I'm working in Java.
String capitalized? Lowercase.
You know, you can quickly go find it out.
But also can be that learning tool.
Like I know C++, Rust sounds really cool.
I want to learn Rust. You could read a book or you could skim Code Thesaurus for C++ and Rust side by side
and get a decent idea of how it works.
You wouldn't know all the ins and outs of Rust just because it does change some stuff around.
But you could at least see, oh, hey, here's the major differences between them.
And then, yeah, sure, hey, here's kind of like the major differences between them. And then, yeah, sure.
Maybe like taking some other method of learning, you could kind of use this as a reference tool.
And it's more, it's a reference.
It's a quick reference.
It's not an encyclopedia.
Yeah.
I try to make the distinction like it doesn't teach you how to program.
So you kind of have to go in knowing like what kind of loop do you want
for a particular situation? Like this won't tell you that, but it will tell you like if you know
specifically you want to do and tell loop, here's how to do it in this language. Is this hand, I
mean, this is obviously not automated. So this is all hand built by contributors and yourself? Yeah. So I built a lot of the foundational frameworks on it.
I am extremely lucky to have had,
I think, like 120 contributors to this so far.
Just over the three years, I think it's been public.
I can't find pointers.
Oh, I don't have pointers in there.
Memory management and kind of memory stuff is one of the concepts I want to add in the near future.
That'll be fun and swift and rust with their various unsafe and...
Yeah.
No, it's just, it's going to be interesting to see how this...
That's going to be a very different thing between languages.
The truth is very few of these have pointers.
Yeah, I noticed C was...
Well, there's also like some of them use references for things.
And then there's like Java where you, you know,
if you ask if some object is equal to another, you know,
it's not like are the things inside equal there.
Yeah.
You know, it's the memory address equal.
And so it's kind of hidden a little bit. So if you
try to compare two strings, it's really
like comparing, is this the same string object?
And that's not what you want.
So it's some of the
confusions around that,
like how languages,
how do you look at memory things?
How do you create new objects
if you want?
Then there's the C way,
which is like, allocate me this much space in memory, please.
You know, not a lot of languages,
or at least not a lot of the like really modern languages have that.
You know, some of the, I guess, more classic traditional languages
do have more of that.
Ooh, Objective-C.
You have any plans to remove languages like
objective c no and that's one of the things is like one of the use cases i thought is what about
python 2 that's deprecated but still so it exists in so many places yeah like the conversion to
python 3 might be important you can compare Python 2 to Python 3.
And so it's like, and that's a perfect use case
where you don't want to remove old things.
But then I also thought like, well, what about if you're working,
like you two work in the embedded space,
like what if you're using an old version of C or C++?
Like you don't want, like it's just a, oh, well, the newest version is like,
what, C20 and C++20? like you don't want like it's just a oh well the newest version is like what c 20 and c plus plus
20 or i don't know if there's a newer one than that but unfortunately the new the new one for c
for most people is 99 yes yeah no there's a new there's a newer quote unquote new yeah and it's
like that's a perfect reason like that's been deprecated several times over. But it's still... Good luck killing it.
You might, yeah.
It's still used, and so
I think it still needs to exist as a reference.
I mean, if you added
anything to C99,
where would you put the extra character?
It would have to just be called
100, because you only have
three characters there.
C99, if you add one. All right, I'm not
going to continue the bit because he's looking at me like I'm... Tell me about your FIRST Robotics
team. So FIRST Robotics is an international organization to kind of work with kids of all
ages to teach them robotics and get them interested in STEM things. And I've been involved
for, what, 11, 12 years now? So I started when I lived in Kansas City and I mentored
first Lego League team. And so they're elementary school kids that build Lego robots and then take
them to competition. And the Lego robots basically drive around the playing field and do different actions.
You pick up little objects or you can hit buttons and something happens.
And every time they do one of these things, they get certain points.
And so the teams with the most points win, essentially.
And then the middle school-ish group,
it can be middle school to high school, is called First Tech Challenge.
And so it's robots actually made of motors and metal and all those good things. But they're
18 inches by 18 inches. And they have to do also kind of a big variety of tasks,
but they're on a 12 foot by 12 foot field. And then there's First Robotics Challenge,
which is like high school only. And they're like four foot by three foot by 12 foot field. And then there's first robotics challenge, which is like high school only.
And they're like four foot by three foot by three foot robots,
I think.
And they're on just like this massive field.
It's something like 60 feet by 30 feet or something like that.
I don't remember.
It's,
it's huge.
It's really cool because besides just being like a cool tech things and
hey kids,
you get to build robots. It's cool to things and, hey, kids, you get to build robots.
It's cool to see one of them like applying things that they learned in school.
It's really easy to take a bunch of math and be like, where am I ever going to use this?
And they actually do get to use math and like some of this robotic stuff, which is really nice.
The second is it's fun. Code is sometimes hard to build a thing and
then see like, yeah, this is a thing I made. It's really virtual. So something like a mobile app is
a little bit easier to kind of see what you're doing than like, I don't know, something that
runs in the cloud. You can't really hold that code nearly as easily.
And so robotics is also good for showing kids like, hey, look, you can actually see the stuff you built.
You can actually see the programming that's involved and how these robots respond to all these things.
What's also great about the first system is they have what they call coopertition. And that's where basically you're either usually like two or three teams versus two or three teams.
And who is your teammate now might actually be your opponent in the next round or sometime in the future.
And so you actually have to get used to cooperating with people
and understanding where they're really good at strategies or what the
robot's particularly good at. But at the same time, also, you know, just like, oh, hey, I know the
robot like does this particular thing really well. How can we strategize around doing something
different or preventing them from doing that as well or something like that? So it's kind of cool to be in this environment where,
despite the competition, they are actively encouraged to be helping each other out in
many different ways. And in fact, there's even awards for being good players in this space.
Like one competition I went to last year, there were a bunch of signs all over the place.
And it was just like a robot tech support, basically.
And it's like, call our Texas number if you're having trouble with your robot.
Our team will come over and help you diagnose it.
I'm like, that's cool that this one team just said, like, we're willing to help any team, whoever they are.
And, you know, we'll come in.
We'll help you figure out what your problem
is, help you solve it. And I'm like, that's just a cool way to see kids kind of, you know,
working with each other. And so I love it. It's great. But right now the competition's over and
they haven't announced what's going on for next year? Is that right?
It's November now.
Yeah.
So first Lego League is in kind of competition season, I'll call it.
So their competitions are starting now or next month.
First Tech Challenge is in competition season next month in January.
So December, January.
And then first Robotics Challenge, their rules are released in January. So December, January. And then first, Robotics Challenge,
their rules are released in January. So they'll build through like January to March.
So it kind of depends on which program you're in, whether you're actively building right now or not.
And then I mentor specifically an FTC team. I'm in charge of our team
here. And then I do a lot of like side involvement with FRC
stuff. So I'll be helping them when their competition time starts too.
If someone is thinking about helping a FIRST team, what should they know? What should they do first. Yeah. So the easy way is you can go on firstinspires.org and find
a team to work with in your area. There's probably a team that exists. They probably
would love to have the extra help. You're always welcome to also start a team too.
But if I were to suggest something to people, one thing I hear a lot is from technical people,
oh, I don't know how to build robots. I don't know anything about wiring. I don't know anything about programming this stuff,
things like that. And I really say that, one, the kids are learning, and you absolutely can
go in and learn too. I feel like I'm constantly learning things all the time, either alongside
the kids or I'm learning it really quickly ahead of time.
And then I'm like turning around and trying to teach it to the kids, you know, a week or two
later. So definitely like don't consider your knowledge level to be a limiting factor on being
able to help kids. There are so, so, so many resources online, too, for teams that share all their plans and how they build things and how they code things to just mentor support networks.
There's forums that people post on.
Reddit has several subreddits for the first robotic stuff and as well as some other competition teams.
So all of that's out there.
If you're not exactly a technical person, I've had a lot of parents say, like, that looks really nice. I would love to help out, but I just, I'm not technical. And I'm like, there are so many teams that absolutely could just use a parent to help them do things around the site, you know, take kids to competitions or just be a scorekeeper or manage some of the money stuff or help them with presentations.
There's so many skills in so many different areas, technical and not, that teams really could use.
So if you think it's fun, if you want to help out, I definitely say go see if you can find a team near you and absolutely help them.
I love it.
It's exhausting.
I spend so many days a week with my teams, but it's wonderful to see them learn, to see them grow, to see them doing all these things that makes them happy.
But also it makes me happy, too.
And I definitely have learned a lot through working with kids as well.
That was a very good advertisement for first.
Thank you.
I have never really gotten involved with.
We did.
We judged one year.
A long time ago.
But it was a long time ago and we only went to one competition.
So we really.
Judging is so much fun.
I love it.
It is a lot of fun.
You know, I've even had some parents say like, I could never be a judge.
I would be too biased against my team.
And I'm like, one, you're not judging your team.
You're always opted out of that.
But two, it is so cool to just talk to these teams, learn how they went about solving the problems they do, to learn about how their team works, to learn about all the different kids and what they're contributing to the different
parts. I don't know. It's so much fun. I just love it. It fills me with great joy to be able
to give them awards at the end of the competition, even if they're not my team.
Switching topics, as I looked at what you've done over the years, one of the things I noticed
in your LinkedIn was that you've bounced around a bit. What are you looking for in your career? Oh, that's a really good question.
And every time I've had to change jobs, it's always been kind of me asking myself that again,
just like, what do I want? How do I choose a job when I'm working? I think some of
it is, I've been kind of this like code grunt where they're just like, Sarah, do this thing,
like type, type, type, type, type. Here you go. You know? And then I've had other times where
just like, hi, we need this thing. We have not the foggiest idea how to do it. I'm like, cool,
give me that. I will figure it out. I love solving weird and interesting problems, I think. So that's one of the things I
tend to look for. I think if I, you know, found myself without a job tomorrow, it's probably one
of those, like, I don't want like yet another job where I'm building like a generic website.
You know, it's one of those things I want I want like where can I use my brain and solve interesting problems and um I do like working with people I
know it's a lovely programmer stereotype of like I'm gonna lock myself in the basement and
shut all the windows and you know bang on a computer for six hours alone but
I really do like working with others.
So it's just like I definitely look for interesting teams and good people.
And one of the things I really advocate for now is just good culture.
I've worked in jobs where I'll put in a pull request and they'll just like,
why did you write your code like that? And I'm just like, let's not do that anymore.
That doesn't help me. That doesn't help you.
So it's just like, do I have an industry
I want to work in? Maybe. There's cool ones I think would be fun to go
for, but I think in some ways I've also
been kind of burnt out on some things about the tech
industry. Then I'm just kind of like, you know what, I'll settle for interesting challenges and
good people more so than just like, oh, hey, stuff in space looks cool. Or, oh, hey, I want to learn
machine learning stuff or whatever. That's kind of where I've settled right now.
You know,
ask me again in like two or three years and maybe that'll change,
but.
That's harder to look for.
I mean,
it's,
it's easier to say,
okay,
these,
these companies work on things that go to space.
Most of them also work on missiles.
So I'll have to make sure that only go to the right place.
But,
but trying to find out if your co-workers are going to be fun, that's a much harder problem.
Yeah, yeah.
And it turns out people don't usually stick that in the job description.
Just like, we have four great co-workers and one that could use a little work.
Like, they don't usually.
I sure wish they did.
I don't know that I would believe them.
I think, and your coworkers will be super fun, would be like one of those things that I look at the job rec and think, yeah, no, goodbye.
That would just be too scary.
Depends on your definition of fun.
It does.
True. Some people are too fun. I mean, I've been endorsed
on LinkedIn for puns, so I like to think that I'm a decent co-worker. That's really an opening I
want to go through, but I don't think you can ask people for puns just off the cuff because that seems rude. Top 10 puns, go.
Oh, gosh.
No, it's fine.
That's the Embedded podcast.
Looks like you all are wired today.
This episode is giving you a lot of spark.
Are these puns really feeling negative or positive?
Do I sound like a really grounded guest?
Are you bored?
Bored.
Bored.
Bored.
Bored.
Bored.
Oh, bored.
Yeah, I can't.
That's an auditory, not a visual reading pun.
Yeah.
Thanks for the clarification.
Clarifications make jokes better.
No, I'm clarifying myself because I was trying to figure out why I couldn't get it at first.
It was an explanation of my stupidity, not the joke.
Thank you for chatting with us, Sarah.
Is there anything you'd like to leave us with?
You know, I'll come back to the mentoring thing you
know it's uh i've had some people always ask me just like oh my gosh you always are doing things
you're always doing the robotic stuff like like how are you doing it and you know good helping
out others just fills me with more energy so it's's like I put out this energy, but I get it back.
And so I guess I would just say, you know, look for where you're getting energy out of things and keep doing the things that fill you with that energy, even if you are expending a lot of it.
Because I do think the good things will keep filling you up. Our guest has been Sarah Withey,
polyglot software engineer,
founder of Code the SARS,
and first enthusiast.
Oh, right, and she's a cyborg with the pancreas.
Thanks, Sarah.
Thank you for having me.
Thank you to Christopher for producing and co-hosting.
Thank you to our Patreon listeners
Slack group for their help with building my computer. And of course, thank you for listening.
You can always contact us at show at embedded.fm or hit the contact link on embedded.fm.
Now a quote to leave you with. Now t-shirts. Oh, oh, Christopher's right. We're going to put this
at the very end. We're going to bury it at the very bottom of the show. Yes, t-shirts are on sale through the end of the year. There'll be a link in the
show notes, or you can go to Teespring and maybe search embedded. Christopher's going to try that
now. It's not going to work. We'll make it work. But now a quote to leave you with. This is what
happens when you search for pancreas for quote sources.
From Jean Kerr,
I'm tired of all this nonsense about beauty being only skin deep.
That's deep enough.
What do you want, an adorable pancreas?