Currently I am running version 1.1.1 off node red on my Raspberry Pi.
And in this lecture I'll show you how to upgrade to the current version 2.1.
It doesn't really matter which version of note rate you are using in your instance of this project.
The process is the same, so I'm using the instructions that you have already seen in the introductory
part of this course where I showed you how to install note rate on your Raspberry Pi and turn the page
that should be looking at a stock's getting started.
Raspberry Pi.
And back then we used this bash command to install a fresh instance of note read.
We're going to use the exact same command now to install the upgrade.
So I'm going to copy this command.
And here in my terminal window, I've already logged on to my node red Raspberry Pi as user pi and just
paste this command in here and hit enter and that will begin the process which can take about ten or
15 minutes depending on the speed of your Raspberry Pi hour and your Internet connection.
So let's go through it.
So I'll say yes to this question or when to proceed and of course, install the PI specific nodes.
And I'm just going to let it do its thing while I wait.
And at this point, I'm going to fast forward to picking up.
Okay.
And that process is now complete.
We've got this script that has upgraded note rate to version 2.10.5, as you can see here.
He did not make any changes to Node.js that I already had because the current version is sufficient
for Node 2.1.5.
Although I could get the same script to also upgrade node to chase runtime.
But before I do anything else, let's go over to my web browser and check to see what is happening with
my node institution and to refresh this page.
And of course, it's not running, so let's have a look at how to get it started again.
So to start the node thread service, I'm going to use this command here.
No direct to start.
So copy that and paste it in here.
And New Red is now starting.
It's a system D service.
Give it a few more moments.
There's the finish loading up.
And we're back up and running.
So in my browser again, refresh the page and there is no trade 2.1 and I can hear the pump motor in
the background.
You may be able to hear that as well that it just started so you can follow the tour guide, which will
take you through the new features on the user interface level.
I'm just going through all those fairly quickly, and I'm going to spend more time exploring those new
features in upcoming lectures in the section.
All right.
And close.
And I've got my currently active running slow here in the tap.
And let's have a look at the user interface or the dashboard, I should say.
Just open it up in a new tab.
So everything seems to be working fine.
I'm just going to increase the threshold for the pump so that it doesn't start to motor.
I'll put it up to 600.
Like that.
And that.
That value here for the pump threshold ensures that the motor will not just start randomly and everything
seems to be working there.
Soil humidity, the air humidity, air temperature, the various widgets up and running.
Emanuel Pump control is also working.
And everything looks fine.
And of course, the version of note rate that is now running is 2.1.5.
So the upgrade is complete.
Now, one last thing that I want to do here is to get rid of the start and boot.
So I'm going to use this command for that.
I'm just going to hit control C to get back to the command line and paste.
Jimmy Garoppolo so you can see it and pace the system.
City l command enable.
And now the no trip instance will begin when the Raspberry Pi starts its double check that my note read
instance is still working even though I hit control C because it's running as a service, you can see
that it is working the Wichita operating properly and getting updates from the ESP three to.
All right.
She'd say also that I haven't made any changes at all in the sketch that is running on the ECP 32.
The only changes that are made there are what you have just seen, namely to upgrade the instance of
note rate to version 2.1.5.
While we are.
Edward Pettit wanted to show you one more thing that you can do here with the installation or upgrade
script right here.
You noticed that when I ran the barebones version of this command line, the bash command line, the
script maintained my current version of the Node.js runtime because it's sufficient for the version
of Node Red that I'm upgrading to.
However, I do have the option to upgrade to Node JS 14 or 16.
Now to do that, it's actually quite easy.
Let's have a look.
I'm just going to clean up here, paste the same command part instead of running it.
Bare bones.
I'm just going to use the help switch just to see what the options are.
So if I don't have a node version, then as you can see here, the script is going to install Node.js
14 by default unless there is an existing compatible version of no teacher.
Yes, in which case it's going to leave the current installation, the current version of Node.js intact.
In my case, I'd like to actually upgrade to Node 16.
So to do that, just replace the help switch with Node 16 and run the same command again.
And yes, I want to proceed the same questions asked.
Go for the PI specific notes and then the script will now upgrade the version of note to read and then
install Node.js version 16.
So again, I'm going to fast forward this bit and then continue.
Once the installation is.
Okay, that's complete.
So the script removes the old version of Node Red and the old version of note to use and then installed.
She has 16 LTE s and no direct code 2.1.5.
Let's test it out.
First thing to do would be to restart node red as a service.
Give it a few moments to spin up.
And so we'll look at close this down and just have a look at my web browser.
So I know Dredd has restarted.
And again, 2.1.5 and I'm going to go to the dashboard.
And increase that threshold to 600 so that the pump motor doesn't start.
All right.
So everything is back to normal.
All right.
Can do control.
See, to get back to the command line.
I know.
Trade still running in the background.
And if you haven't done so already, then you can set the service to start on boot.
I should be okay because I've already done it.
In my case.
It doesn't hurt to do it again though.
So be careful just in case.
So let's wrap it up for this lecture.
I have now upgraded Node Red to version 2.1.5 and I have confirmed that my existing terrarium controller
flows still work.
So in the next few lectures in this section, I'm going to walk through some of the most important or
interesting features of Node Red Version two and show you how they work.