GPIO stands for general purpose input output. And what you are doing here in the code, you are defining this output pin, like where is your output, where you are sending information, and then you say just output to this pin, which means turns it on, or send zero, turns it off. Right? Super simple to make it work.
Servo motors, this is how they look like. They are in head, being able to move it left, right, up and down. And similar thing with them. Like you define the output pin, and in a similar way define, okay, how much you want to move this motor, how much you want to turn it on. Only few lines of code.
Assembling all this together, you are actually getting exactly this, what I showed you over here, like, hey, my droid is turning lights on and off, moving the head around. You made it alive. The thing that is left is the camera, making it aware of its own surroundings.
I took this super cheap off the shelf camera, I just needed something that's plug and play, and the reason I liked it is actually because of this eye that I was able to disassemble and put in front of the droid's lens. So when you have all this connected together, one way is to, as I said, go to the cloud, take your picture, basically two, three lines of Python code, take the picture, send it to some API in the cloud, and process it there. And this is where computer vision service is a natural, gives us a lot of possibilities to do different things.
So you can detect different objects, could react on the people when someone is entering its view that it positions the head toward that person, or could detect some objects if you are showing it, I don't know, the mobile phone that it tracks with the head of the mobile phone. So it takes a picture, processes it, figures out where the object is, positions the head towards that. You can do a lot of different things there, like vision studio that came out in July last year gives you a nice hub where you can see a lot of those examples, like what is possible to do, what is there, quick examples that you can try out, and then you can use your imagination and build something new with this droid, with some other droid that you are building.
You can make speech to text so it can recognize your voice commands, maybe, and perform some actions, and many, many other things. And everything you do is super, super simple. But basically, getting back to the camera and computer vision, you are doing this image analysis trying to understand what is in front of the droid. So you could, for example, take a picture and ask the droid to explain what it sees.
That was basically my droid story. I hope so far it inspired you a bit, or at least you've seen that it's not complicated to build. We can really build Star Wars droids at our home. This is not where my story stops. I don't know if you've seen the NVIDIA GTC keynote by Yen-Seng Hong, their CEO. They presented these droids from Disney. Those are the new things in the US in Disney Park, where they fully developed them with this is running on two NVIDIA Jetson Orin inside, and they are super cute, right? The thing is, we don't really like Disney. They purchased the Star Wars, right? But slightly changing movies. As a community, there is a lot of people out there like me that think those things should be open source and people should be able to build it.
Comments