In this lecture, I want to give you a quick demonstration of how you can use the IDB and Micro Python
to do something simple with the big picture, which is this case to make the board ality link.
At the moment, I've got my inspirited connected, so it's unconnected and instead connect the Raspberry
Pi pickle back into the thorny idy.
And the two options change the integral to the three pickle and show that the port is properly selected
and OK.
So now we've switched the target device to the Raspberry Pi pickle, which means running micro python.
This is actually how it comes from the factory.
It didn't have to do anything in terms of installing a micro python interpreter from on it.
Just plug and play.
We can find information about the pickle on its Web page.
You can see here Raspberry Pi dot org documentation.
They could get started and scroll down and the board specifications.
You see the pin map out there.
Big picture is well equipped with all sorts of Tapio capabilities and communications capabilities.
One interesting technology that comes with that is a programmable input output, Appio State machines,
which basically allow you to write simple programs and execute on specific bios.
And because they run directly on the side of the checkpoint, not occupying any MCU cycles, they're
very, very fast.
It's a fairly advanced topic, though, but I thought I should mention, because it's really a feature
that stands out when compared to other microcontroller units.
Anyway, in this simple example, I can show you how to toggle the state of the built in.
And just as you can see in the pin map out, it is connected to the chip.
Twenty five using thony to eat.
All right, so the first thing that you need to do is to import the PIN module from the machine to the
library and the machine library, you learn about this in more detail a bit later.
It is a library that is available for all of units that support micro python, and it contains functions
that are specifically created for the microcontroller that you're targeting.
So in this case, the machine library contains functions that specifically apply to their pickle.
Later on will be using a different version of the machine library that specifically applies to the capabilities
of the HP 32 and so on.
And that's because each hardware target is different in terms of its hardware capabilities.
And those differences are reflected in the individual machine libraries.
So now that you've got the PIN module, I'll be able to use the capabilities the PIN module provides
me to do things such as toggle the state of the entity, which is, as you said, connected to JP twenty
five.
The first is going to create the entity object and I'm going to use the PIN constructor so that we are
targeting JP twenty five.
And this is going to be an output which that's how you set this up in Raspberry Pi.
Piggot and now that we've got this object we can collect on the work of.
The.
Perhaps I should say, to not talk like that there, Verizon.
That's also another way that you can do this if you want to be more specific about the value that you're
writing to the top twenty five, which is the only thing, is to use the venue method.
And in this case, the world is turned off now.
So I'm going to turn it on by putting value one like that.
You can also check the state of the ality by just calling the value, but had a parameter.
You could see now that it is on a fight top level and check the value again, you'll see that it's off
now.
It's zero.
It's just a quick demonstration is the focus of this course is on the three.
But if you're curious about learning more about the Cross-Breed Pekoe, then have a look at the documentation
here, a full book with a lot of content, including the link example that I've just shown you and lots
of other bits of information that you'll find interesting.
All right, so then the next thing that I want to do in the next lecture is to show you how to do something
similar with the BBC.
MacRobert The purpose of this, of course, is to show you how the versatile micro python nature allows
you to jump from one kind of hardware to another with some small, relatively small modifications to
your Microplace approach.
So let's go ahead and extend the ABC a.