So now how about we test the other colors on the port a bit just with a little bit of addition we could
just toggle between red blue and green.
So this just out these colors here is the clear blue and then green the
who is.
And I'll give you the binary number.
Basically this is one two three four.
This is 0 1 0 0.
This is blue.
And then Mr. Clay Green Green is 8 Kikuyu 0 x 2 8.
What this stands for is one two three four one two as you show.
This is PSU P F 1 p.m. to 3 okay.
Say okay just to try.
This just change this hair switch on.
Let's move blue in that and see what happens before we start adding our controller to it.
Let's just put this forward switch too.
So as we know before we try it out we have to tell it direction registered to give us the pin for blue
and then tilted digital enabled register to enable the blue pin and we come here.
Remember blue is connected to at sea.
We declared it up here.
It's connected to P. F..
It's connected to similar 1 to P F F2
show.
We have to add P F to here us there 0 1 2 and hexadecimal.
Funny is this.
This is on say a C.
Show this on E.
In hexadecimal code 2 1 1 1 2 becomes on E.
So without this her and without direction register it becomes the same direction register.
We have to enable the M P to us.
Well so far we have this and this.
You have to enable the p 2 so in order to enable the pin for the painful blue what we want to get should
look like this in binaries currently.
It's like this.
You want to test the current form.
This is super x 0 2 in binary but what we want is to enable this like this.
So this number in binary is 6.
So we just have to change this to 6 like this.
So we've set this to an output pin and then we've enabled it so when we come here to switch on subroutine
and we say when we press give us blue it should work.
That's declared and cups.
Okay.
Sorry.
This binary number actually gives us 7.
It's rather confusing when the 0 1 the series out the other side it's an E so it should work.
Let's see this reset.
And then there we go.
The blue light is on.
This is amazing.
So the next step would do would be to test whether we can just enable and to set a direction register
for the queen LCD and then see what works.
After that we'll add the second switch on the board so that we can control different colors with the
two switches and even mix up Collis.
So let's see in the next lesson.