WEBVTT

00:00.540 --> 00:07.560
All right, and now let's see how to write your fellows program and also debug your program directly

00:07.560 --> 00:09.030
with the simulation.

00:09.040 --> 00:15.120
So the online simulation, we think, OK, and make sure that you have watched the previous listens,

00:15.600 --> 00:18.240
because here I'm going to go a little bit more quickly.

00:18.460 --> 00:20.630
I'm not going to explain everything again.

00:21.060 --> 00:23.490
So I'm doing OK here on your dashboard.

00:23.700 --> 00:27.710
You can go on circuits and then you already have your test checkers here.

00:27.990 --> 00:29.580
You can create a new one.

00:32.720 --> 00:34.760
OK, and I'm going to name it.

00:36.340 --> 00:38.230
First program.

00:39.900 --> 00:48.240
So I'm going to add the undeniable of all such horrible but the horrible like here, and we don't need

00:48.240 --> 00:49.890
any other components right now.

00:50.730 --> 00:57.110
So that's good to see the code blocks, which is text, I assure, continue.

00:57.750 --> 01:03.040
And actually, when you start with an empty program on Tinka, well, the program is not empty.

01:03.390 --> 01:06.140
This is already the blink example.

01:06.360 --> 01:11.190
So this is what we have written for the first program.

01:11.220 --> 01:20.220
OK, so first we initialize the PIN 13 to output and then we were on the editing with digital right

01:20.220 --> 01:21.780
high on interring.

01:22.200 --> 01:30.720
We wait for one signal, we pull off the energy and we wait for another one signal and then the loop

01:30.720 --> 01:32.490
will continue to be executed.

01:33.100 --> 01:34.920
As you can see here, we have comments.

01:35.370 --> 01:39.150
So you don't necessarily need to put a comment on a new line.

01:39.570 --> 01:44.550
As soon as you put double slash, the rest of the line would be connected.

01:45.060 --> 01:49.050
So now all we need to do is to start the simulation.

01:49.050 --> 01:53.670
So let's click on Start Simulation and you can see here.

01:53.910 --> 01:55.680
So I'm going to zoom in a little bit.

01:56.280 --> 02:01.100
The energy here is blinking at one hand.

02:01.180 --> 02:06.390
So everyone singing that simulation and will.

02:07.990 --> 02:13.960
As you can see, it's not that hard to make it walk, and if you understood this program previously,

02:13.960 --> 02:16.620
then it should be quite easy at this point.

02:16.870 --> 02:22.270
And let's just shake what happens if, for example, we forget that semicolon here.

02:22.990 --> 02:32.380
Let's start simulation and you can see we have the expected semicolon before delay, so.

02:34.590 --> 02:41.700
We can add the semicolon and then it would work, so basically we have almost the same error code and

02:41.820 --> 02:43.560
for the original i.e..

02:43.980 --> 02:44.350
All right.

02:44.350 --> 02:49.500
And now let's check how to use the same money to debug your program, because, yes, you can still

02:49.500 --> 02:52.450
debug your program even with the simulation.

02:52.920 --> 02:59.150
So here I'm going to just use that program that we have created here.

02:59.160 --> 03:02.830
So I'm going to copy paste this right here.

03:03.300 --> 03:06.270
So first we initialize the cell communication.

03:06.660 --> 03:14.910
We say a billion, we print Hello, Alvino, and then we print something in the loop every five hundred

03:14.910 --> 03:15.590
milliseconds.

03:16.320 --> 03:21.560
So this is a program we have just made and explained everything in a previous lesson.

03:22.020 --> 03:23.490
Let's start the simulation.

03:25.300 --> 03:32.590
OK, so not how to see what's happening, you can go on the same monitor here on the bottom and you

03:32.590 --> 03:38.350
can see we have Helena know and then in the loop.

03:39.760 --> 03:40.780
Well, actually.

03:42.580 --> 03:45.610
There is something that happened here with this text.

03:47.310 --> 03:50.550
So now it's working well, how do I know in the loop?

03:50.850 --> 03:59.700
So if you want to restart your program, well here you simply stop the simulation and start the simulation

03:59.700 --> 03:59.980
again.

04:00.870 --> 04:03.910
And here you can see we have the reset button.

04:04.200 --> 04:06.420
What happens if I click on the reset button?

04:07.710 --> 04:14.250
And as you can see, hello, I don't know, so when I click on this reset button while the program is

04:14.250 --> 04:21.480
running on the simulation, this will also restart the program so you can interact with what's happening

04:21.480 --> 04:24.750
in secret directly during the simulation.

04:26.510 --> 04:32.960
All right, so you have seen how to make a very simple program to bring in L.A. we dissimulation, how

04:32.960 --> 04:39.870
to use the cellular communication we decided we need to operate here and how to restart your own program.

04:39.890 --> 04:47.090
OK, on the simulation, you can stop and start simulation or you can also click on this reset button.

04:47.540 --> 04:47.860
All right.

04:47.870 --> 04:54.500
And for the following of discourse, I will not always show the results on Dinko Card, OK?

04:54.830 --> 05:03.140
Or maybe just at the end of a specific lesson, because as you could see, this is the same thing whether

05:03.140 --> 05:09.050
we use the Tinker Cat Interface, this is the same thing.

05:09.530 --> 05:17.480
So if you are using the simulation first, watch the listen using the ID and you can just write it instead

05:17.480 --> 05:18.560
of in the 80s.

05:18.710 --> 05:21.160
And now you know how to start the simulation.

05:21.170 --> 05:25.150
You know how to use the same monitor, how to restart your program, etc..
