Build a Developer's Linux Workstation - Complete Guide

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
today in the workshop we're building a developer's workstation from scratch i'll show you how to assemble a bare bones computer system and install and configure linux we'll then add 15 software applications that are just perfect for experimenters like us we're taking care of business today so welcome to the workshop well hello and welcome to the workshop into a very special and rather long drone bot workshop video now please don't be turned off by the length of this video because in a moment i'm going to show you how you can jump directly to the parts of this video that you need and skip the parts that aren't relevant to you but before i do that i want to give you a little bit of a background story about what i'm doing over here i need a new workstation in this workshop the workstation to use with arduinos and to use with esp-32s etc because the workstation i'm using is very old it's actually an old computer that i repurposed when i built the workshop five years ago i put an ssd into it put as much ram as i could which is all of eight gigabytes but it is very underpowered it also breaks down a lot i've had a couple of videos where i've had to stop filming and literally rebuild the workstation so enough is enough we need a proper workstation here in the workshop and that's what we're going to be building today now i'm going to be building this workstation from scratch using a bare bones computer kit adding in ram adding in solid-state drive and then configuring it with linux and adding 15 software applications that i feel are very useful for folks like us who work on things like arduinos and esp32s etc and we're going to be building a developer's workstation now as you can see this is a very lengthy video and it's accompanied by a very lengthy article in fact most dronebot workshop articles tend to be reasonably lengthy they run from about thirty five hundred to six thousand words the article that accompanies this video is listed a little shy of twelve thousand now that's a lot of information to get through so i have provided a few mechanisms so that you can get through it a lot quicker the first thing is something that is true with every dronebot workshop video although amazingly a few people don't know this down in the description of the video is a clickable table of contents and that allows you to go directly to the parts of the video that you want to go to without having to go through all of the other stuff and as i said that's true of all my other videos if you want to go just do a specific section on that video but this video is also one of the first videos i've done using a new feature that youtube has called chapters on the line at the bottom of the video the one that is the timeline you'll notice now is broken up into a number of different sections and as you hover your mouse over those sections it will tell you what that section is about so you don't even need to use a table of contents if you don't want to you can just use your mouse to go and find exactly what you want in the video without randomly going around it now as for that 12 000 words mini book that i have on the dronebotworkshop.com website what i have done is i've created something called a cheat sheet to help you get through all of that now we are going to be installing linux on this workstation and then we're going to be installing a number of software applications and installing linux software applications generally means working at the command line and putting in some commands that are rather cryptic now what i've done is i've created this cheat sheet and that's simply a fancy word for a text file that has every single command in order that you need to do so all you need to do is copy this cheat sheet onto your new workstation and then copy and paste into the terminal and you can run through the entire installation very very quickly if you get stuck with something you can go to the video and look that part over or go to the article and look that part over and all of the dronebot workshop articles also have a clickable table of contents to let you get there so it's a lot of information but you can get through it so please trust me on that one now as i said i'm going to be using a bare bones computer kit and it's something called an intel nook and nook means next unit of computing i like these intel nooks in fact i've got a couple of other ones right now around the house and they're really great little units because you just put in whatever you want for drive and memory and away you go they're compact and they're really nice but you don't have to use something like that you could repurpose an existing computer to build as your workstation you could use your existing workstation if you have a windows workstation and you could put a partition aside or a second hard drive into it you could install linux and create a dual boot system or you might even already have a linux workstation that's just working just fine thank you very much but still this video could be of value to you because there are a couple of applications like the chase app and peak that you may not have heard of that i'll be installing or a couple of mods to linux that you might not be aware that you can do such as the x-kill mod so there is something in here for everyone now another option some of you might want to use is to use a single board computer to do this and you could certainly do that some of the more powerful sbcs are quite capable of running 64-bit linux and could certainly be used for this but if you're starting from scratch and thinking of using an sbc one thing i'll point out is that on the low end of these bare bone computer kits it's actually more cost effective to do that because a single board computer is going to need an addition of a case it's going to need a fan it's going to need a heat sink it's going to need a power supply and it's also going to need some way of using an ssd so by the time you put all that together you're actually in the same price range as some of the lower priced barebone computer kits now i'm not using a low priced one i'm using a rather high-end one but you certainly don't have to use one as powerful as the one that i'm using i just felt it's time the workshop had a really nice powerful computer another thing is that i'll be using ubuntu linux on this design and you don't need to use ubuntu you could use another distribution of linux in fact there are better distributions of linux there are distributions that are more lightweight if your computer is not that powerful and i'll be mentioning a few of those distributions in a moment so certainly don't feel that you're glued to using ubuntu for that i just happen to use it because i have a preference for it myself and so with all that said let's go and take a look at the requirements for our workstation and then we will start building our developers workstation now for starters we are going to require a computer not a tablet or phone there are simply not enough developer applications for ios or for android that would make a phone a usable developer's workstation we need a machine that can run an operating system like linux windows or mac os x and i'm going to be building a linux workstation today now the hardware you use needs to be capable of running common integrated development environments and that requires a reasonable amount of memory capability you'll also need graphics capability for cad applications your machine is going to need some adequate internal storage space so you may need to add an external usb drive to it if that isn't the case you'll require both wired and wireless network capabilities because there are times where you will need to be on both networks simultaneously the machine also needs to have at least one available usb port with sufficient power to power a microcontroller board now what about using a single board computer instead of a full-size computer while i would normally go for the full-size computer there are many powerful single board computers now that would make adequate linux workstations and would satisfy the requirements and so you can certainly use one if you wish you can install build of ubuntu on this or another linux operating system now linux itself was developed in 1991 by a finnish student named linus torvalds linus developed linux as a free alternative to unix the word linux itself is an abbreviation for linux is not unix which in a sense is a bit ironic since linux is very very much like unix the linux kernel is open source which is why so many distributions of linux are free the kernel is maintained by the linux community now you may have seen this little guy before the linux mascot's name is tux the mascot was chosen by lenas torvalds in 1996 and apparently was the result of an incident where he was bitten by a small penguin when visiting a zoo in adelaide australia the word tux means either torvald's unix or it can also be used to mean tuxedo which of course looks like what our little fellow is wearing the linux foundation is a conglomeration of a number of major companies that produce distributions of linux and there are many distributions of linux you can choose from ubuntu linux is the linux that i will be using for our workstation but you could use a different one if you wish ubuntu is probably the most common build of linux these days and there is a great deal of support for it which is one of the reasons i've chosen it it is however a bit of a heavyweight version of linux and so if your hardware isn't up to snuff you might want to choose a different version debian is a build of linux which is considered to be pure linux in fact many other builds of linux including ubuntu are built around debian while debian is mostly used for servers the debian workstation is also a lightweight version of linux that is very customizable and very useful for a workstation linux mint is an extremely popular version of linux in fact it's probably the next most popular one after ubuntu it's a relatively lightweight version of linux that is well supported and one feature that it has is something called time shift now those of you who've used microsoft windows may be familiar with the restore function where you can restore your computer to a previous version time shift does the same thing so linux mint would also be a good selection for a linux workstation mx linux builds itself as a mid-weight version of linux not as heavyweight as ubuntu but not as lightweight as pure debian mx linux has a fairly elegant desktop and has become a very popular distribution of linux manjaro linux is based upon arch linux as opposed to the other distributions we've seen that are based upon debian manjaro linux has a fairly elegant desktop and is very popular with those using audio and visual applications as it comes with a number of multimedia apps already installed you can use any of these builds of linux or a different distribution of linux to build your linux workstation now here's what we're going to do today first we're going to build or obtain a computer in my case i'm going to build one but you could also just use an existing computer and repurpose it as your workstation we are then going to install linux i'm going to install ubuntu linux 2004 and then we will install a number of different software applications now our applications are going to fall into a number of groups we're going to install integrated development environments or ides we have editors and file management tools communications tools are quite important for working on the network schematic and printed circuit board editor tools are very useful on your linux workstation and you may also require some graphics and media tools so let's get started and build our linux workstation now here are the components that i've chosen for my workstation and as i said earlier it is all based around this box this is an intel nook now nook is an abbreviation for next unit of computing and intel's been making these for quite a while for over a decade but it's a really great idea what they've had they take the processors and chips they use for notebook computers and place them into a small box that you can use as a desktop computer and as you can see it is a very small box let's take a look at my nook a nook look if you wish now this is a nook 10 which means it uses 10th generation processors and this particular model has an intel i7 in it so it's a pretty powerful little nook and on the front of it you can see there's a usbc jack as well as a usb 3. and there's also a headphone jack over here and underneath the protective plastic is the power switch if we turn it around we can see on the back there's a connector for a power supply there's an hdmi connector an ethernet connector two usb 3 connectors and another usbc which is also a displayport connector that can drive two additional video monitors so you can drive a total of three monitors with this and this is just a kensington lock and on one side of it here you'll note that there is a micro sorry as an sd card if you want to use a micro sd card you need to use one of those plastic adapters that you no doubt have a drawer full of and that's pretty well the basic box and as i said this box comes with the processor the intel i7 it comes with the wireless networking but it does not come with any memory and it doesn't come with a boot drive or a second drive because this can accept two drives an m.2 drive to boot off of and a sata drive as a second drive so i've got all that down here here's the memory i'm using they're ddr4 chips and i've got gigabytes of memory here in the form of two 32 gigabyte chips and that's the maximum that this will take so it should be a pretty peppy little box when it gets together now for a boot drive this is an m.2 drive it's a samsung 970 evo drive it's a one terabyte ssd and for a second drive which i use as a drive for my work files now i don't use very large drives in my computers because i keep my work up on the network on an ssd so this is just another one terabyte drive it's a western digital blue ssd drive and i've used these before they're pretty good and i've also got a usb key over here and the usb key has got an image of ubuntu on it and that's what we're going to need for the next step which is installing all of this stuff putting the parts together and installing it all on the computer so i will be showing you very soon how to make one of these images and then we'll get everything working now in order to get the ubuntu installation media you're going to need to visit the ubuntu download page and you'll find the link to this page in the article that accompanies this article on the dronebotworkshop.com website now assuming that you're using a standard computer what you want is the ubuntu desktop and i would highly recommend the long term service or lts version of ubuntu you will notice there is a more recent version that you can also get but it is not a long term service version so i'd highly recommend getting this one because it will be maintained by ubuntu for several years now the way that ubuntu version numbers work is that the current long-term service version of ubuntu is 20.04 and that's because we're in the year 2020. now next year there will be a 21.04 however that will not be a long-term service version of ubuntu the year after that in 2022 there will be another lts version because ubuntu releases this every year so eventually there will be a 22.05 the previous long-term service version of ubuntu was 1804. once you've downloaded this image you're going to need to put it onto your installation media and i would highly recommend that you use a usb stick now you may already have some software to do that but if you don't the program i recommend is over here and that's baleena etcher extra is a very useful program for doing exactly this for writing to both usb sticks and to micro sd drives and in fact i'm going to be installing extra onto our workstation later so if you need to install it on linux you can go ahead and take a look at those instructions extra is also available for the mac and for windows so once you've got extra you can use that to move the image onto a usb stick and we're ready to install ubuntu so now that we've seen what our workstation requirements are and we've seen the hardware that i'm going to be using it's time to get down to work so let's build the computer and install ubuntu linux onto it now we're all set to build our computer i've got all the parts laid out over here and the intel nook is opened up and there's a ribbon cable that connects the bottom of the case to the rest of the nook it's sitting upside down at the moment and you can see it's all basically one big circuit board over here and actually it's not really that big a circuit board let me just grab this here's a raspberry pi to give you a rough idea of the size of the board so it's it's a bigger board than the pie not quite twice as big as a pie but when you put it together in a case and everything it makes for quite a small unit they've done a very good job of making everything very compact now the cpu and everything is on the other side of the board so you can't see it from here so one of the first things we're going to do then is to put the boot drive in the m.2 drive and that just inserts down over here and there's a screw that you need to use in order to keep that in place and there we go we've got the boot drive in now the next step is to install the two memory chips and we install this one first just going to the slight angle and then snap down so that's pretty easy to do and then the last step is to put this solid state drive the sata drive in and it inserts into here and goes into there there are a couple of screws that you can hold it on with as well and those are a little bit difficult to do and there we go we got one of them in and the other one goes in up here i'll put it in a second no sense you watching me fumble with two screws but otherwise this is basically assembled i've got my ssd boot drive my ram chips and my other ssd drive into the case i just need to put that second screw in put the bottom back on it's already got the screws ready to tighten and we basically built the computer it's that easy and so i've got my nook all put back together and it's ready to go it's hooked up and waiting for us to install ubuntu now i've got a connection at the back to the usb that's going to both my keyboard and my mouse i've got an ethernet connection i have an hdmi connection and this other connection is of course to my power supply and this is the power supply here for the nook 10 it's actually larger than the one they had for the nook 8 but still these two units together are much smaller than the mini tower that they are replacing now another thing they give you with the nook is this little plate over here and what this is is it's a mounting plate that you can use to mount the nook onto the wall and it's also drilled out over here for a 75 millimeter visa mount so you can use this to mount the nook on the back of a video monitor and create sort of a self-contained workstation with a monitor and everything add a wireless keyboard and mouse to that and you'd have a very nice setup indeed now of course on the front over here i have got my usb stick and it's got my ubuntu image and it's ready to go and with everything hooked up all i need to do is hit the power button and we will install ubuntu linux okay we're booting up the nook and it's just done a check of its installation media and it says it's okay and it brings you to a screen that asks you if you want to try ubuntu because you can use this just to give ubuntu a try on an existing system without actually installing it or you can install ubuntu and if you're installing ubuntu on a machine that has windows as long as you've created a partition for it you can install it along with windows and create a dual boot machine however we're doing this in a brand new machine we're going to select install ubuntu and the keyboard is english us if yours isn't make certain to change it i'm going to do a normal installation you also have an option to do a minimal installation that doesn't have a lot of software and games and media players etc but we have enough space so we'll do the other one and we'll also download some updates while we're installing ubuntu and this will save us some time because of course there have been updates since they created the installation media and it says to erase the disk and install ubuntu and that's what we want to do there's actually nothing on the disk right now and we're checking and it's using the samsung drive uh you can select the drive over here so you could also select the western digital one but i want to boot on the samsung and use the western digital one formatted just as a work drive so we'll do install now and it says if i continue this is going to happen it's going to be permanent and i say yes and it asks where i am and i'll say continue that's my name and the computer name i want to change that i have a naming scheme and you need to select the password here and confirm it okay and require my password to log in you can also set it to login automatically if you don't want to see a password prompt when you log in and the installation is starting now and the installation is complete i need to restart the computer in order to use the new installation so that was pretty painless let's restart and we'll set up ubuntu for the first time now when you first boot up ubuntu you're going to get a number of questions most of these are security questions such as do you want applications to know your location do you want to connect your microsoft account do you want to send information to canonical about bugs and things like that and do you want to use live patch live patch is a system ubuntu has for automatically doing updates in the background and you can make your own decisions on those there are a couple of other things you're going to want to set up now go up into activities and just type in the word up and you'll notice you get a few different things over here you've got software and updates in the software updater look at software and updates first now this just specifies how ubuntu is going to obtain updates and these are the ubuntu software the one i want to show you here is other software now this won't be checked and you should check this canonical partners this allows ubuntu to also use the repository of some trusted partners and gain you access to additional software now when you check that it is going to need to go and scan and reload software database so it's going to take a few minutes but i would highly advise you do that another end over here is the additional drivers now in my case i don't require any additional drivers but some people may need to use a non-open source driver for things like video cards and the system will detect the availability of these additional drivers it'll prompt you to use them again you'll probably need to use a password in order to accept the additional drivers now the other program that we see when we type in up and i'll type it again is the software updater and it will scan to see if there are any fresh updates for ubuntu now i probably don't have any because i just did an update but when you first install ubuntu it's a good idea to do this because there will have been a number of updates that have been released between the time that your installation media was made and the time that you're actually running the programs so once you've done that you'll need to reboot and we can start setting up our linux system now one thing that i need to do to my workstation which you may or may not need to do to yours is to format the second solid state drive now of course if you don't have a second solid state drive then you can skip this process because you simply can't do it but in order to do that i need to use the disks utility so i'm going to go down into the show applications again i'm going to look for disks which is right over here by the way if you can't find something right away you could always type it in the search up here so we'll click on the disks utility and we'll notice we have two disks now the first one is my one terabyte samsung disk this is my boot disc it's already been formatted i'm certainly not going to touch that the second one is my other drive the one terabyte western digital one that i had and this one has an entire one terabyte partition that is not formatted and so what i need to do is click over here and do format partition now i need to give it a name i'm going to call mine work because that's what i'm using it for i'm not going to erase existing data because of course i don't have any existing data if you do decide to do this you will take a long format and it could take potentially several hours depending upon the type of disk you have but if you have an old disk it might not be a bad idea i'm going to leave the file type as it is because this is an internal disk however you could format it in a different format if this is a removable drive that you might want to share with another computer but in my case it's an internal disk so i'm going to accept this format type and hit next over here it's going to warn me that all the data on the volume will be lost which in this case is moot point because there is no data on it and i will click format and i have to give it my password because it says hey if you're going to do something like this i better know you really want to do it now after formatting one thing you're going to need to do is to mount the partition and you can do that just by pressing this button over here and now the partition has been mounted and if we go into our files we should be able to find it somewhere and here it is our work drive and the folder is empty because of course there's no data in it again if you don't have a second drive you won't need to do this now we've got our computer constructed and we've got linux installed on it and i'm sure we're anxious to install some applications as well but before we do that i want to take a look at ubuntu linux and a couple of utilities that come with it that are going to be useful for our workstation and also a couple of tweaks that i like to make in order to fine tune it so let's go and do that first now the way that i like to work with an operating system be it linux or anything else is i like to keep my most used applications on the dock and that's what i'm going to be doing today in this installation of course some people like to keep application icons on their desktop i do not i like to have a completely clean desktop but that's the way i work and it certainly doesn't mean you have the copy the way that i work now you'll notice i've already removed a couple of items from the dock things like thunderbird and the audio player that i don't think i'm going to be using very often again remember i have not removed these programs from my computer these programs are still here i've just simply removed them from the dock i'd also like to put a couple of other programs into the dock ones that i find very useful so i'm going to go down to show applications over here i'm going to look at all my applications now remember there's a frequent and all switch over here you want to set to all right now and there's a couple of things i'd like to put over here into my dock now if i go over here one of them is the text editor now the text editor is something called g edit and i find text editors even simple text editors to be a very handy thing to have especially when i'm copying and pasting things between applications so i'm going to right click and do add to favorites you'll notice now the text editor is in my doc now the other thing i want to put is right next to the text editor and it's probably the most important application we're going to be using today because we'll be using it to install software and that's the terminal i'm going to add that to my favorites now you can organize your favorites and i'm actually going to put my terminal right up near the top because i think it's the most important thing so you'll want to go through this and put some of the more common apps into your dock and that way you can get access to them a lot quicker now another thing i like to do before i start installing software is i like to replace the file manager that's in the dock while there's nothing wrong with this file manager i like to use one that has more features now in order to install software there are a number of things we're going to be doing some software we're going to be installing at the command line but some of them we can just use the ubuntu software store and it's very easy to install software from here now one thing you need to be aware of is that not all of the software in this store is necessarily the most current and up-to-date and this is why we're going to be installing some manually from the command line but the program i want is up to date and it's in here i'm going to open this i'm going to go up to the search and the file manager i want to use is called nemo so i'm going to search for nemo and there it is and so i'll click on nemo and i can install it this with this button here you'll need to authenticate and nemo is now installed now what i want to do is make that the file manager that's in my docs i'm going to go down here again to show updates and you'll notice we have two file applications now now this one with the darker item is nemo and so i'm going to add that to my favorites i'm also going to remove this from favorites just not to confuse myself and i'll open up nemo and the thing i like about nemo and first of all i like to sort things this way is that with nemo you can actually have multiple panes if i hit the f3 key i actually get two panes over here you can also do a control t to have tabs now the old file manager supports tabs as well but i find that having multiple panes and tabs together is very versatile when you're navigating and copying files so i would highly suggest that you install nemo as your file manager now the ubuntu operating system is very stable and the applications i'm showing you are also quite stable but it is possible that you'll have an application that locks up this this happens sometimes and it happens with every operating system what i'm going to add right now is a very convenient keyboard shortcut i can use in order to stop an app that is locked up in other words in order to kill its task now i need to go into the settings to do this and you can get the settings up over here you can also get the settings by the way through show applications either way is fine now if i scroll down all the way i will see keyboard shortcuts down over here and on keyboard shortcuts it shows me all the different shortcuts that i have for the keyboard and there are specific shortcuts here so hide all normal windows as this particular key combination you can also add your own custom ones and that's what i'm going to do right now so scroll to the bottom and hit this little plus sign and you will get the custom shortcut now what we are going to use is an application called x kill and i'm going to type x kill in both of these boxes and so now i need to set a shortcut now you can set a shortcut to be any keys you want but of course you don't want to set it to be keys that you already use for something so certainly don't make it control c or anything i'm going to use ctrl alt k so i'm going to do set shortcut and then i need to type my shortcut and it's ctrl alt k now and so i will add that and now let me show you what happens when i hit ctrl alt k watch my cursor the cursor is now changed into a little x and anything that i'll highlight and click on will disappear so if i want for example to kill the application settings i just go over it and click on it and it's gone and this is a very easy way to kill an unresponsive task in ubuntu now one of my pet peeves is the caps lock key i don't really like the caps lock key i find it to be a nuisance i'm accidentally hitting it all of the time and looking at what i've typed only to find out that i've typed it in reverse case now turning off the caps lock key is different for different operating systems mac os x actually makes it quite easy to turn off the caps lock key because there's a setting for that as opposed to windows 10 which makes it extraordinarily difficult you actually have to do a registry edit in windows to do it now ubuntu linux in the older versions actually had a little button that you could use in order to turn the caps lock key off but that was removed several versions ago but i would still like to do it so this is what i'm going to do now i'm going to go again into my show applications i'm going to look for the startup application and launch that now the startup applications are applications that run when the system first starts up i'm going to add a new one into here and so i'm going to add something here i'm going to call it caps lock and for the command i'm going to give it this string over here now remember you can get all of these strings off of the cheat sheet that i supply in the article so please don't try to type it off of the screen and if you wish you can make a comment and that's and i will add that and now i have something that will stop my caps lock however it is not going to stop it just yet i will close over here and we'll take the text editor and we'll open a new document and i'll use an example i'm going to start typing over here right now now i'm hitting my caps lock key and it's still working the caps lock okay what i have to do in order to make this work this is a startup program i'm not going to save this and so it needs to happen whenever i start the system up so i either need to reboot or just log out so i'm going to log out over here right now and then i'm going to log back in and there i go and now i'm going to open a text document again i'm going to start typing i'm going to hit my caps lock key it doesn't do anything the caps lock does have a function now it functions as a shift if i hold it down i can get capital letters just like a shift key but otherwise caps lock does not function and i like to do this just because of my peeve about the caps lock key now the next application we're going to install is actually a pretty neat application that i just discovered recently but before we do it i want to show you something about working with the terminal which is what we're going to use to install this app anyway i'm going to open up my terminal now in my case i have already increased the font size on the terminal so that you could see it better on the screen and quite frankly it makes it easier for someone like myself whose eyes aren't necessarily as good as they used to be to see it on my screen now in order to run a lot of applications we're going to need to be a root or super user and to do that you use the sudo command sudo which literally means super user do do the next statement as a super user and we're going to do something called an apt update and this is something that you should do before installing new software so i'm going to type in apt and then update and i'm going to press enter and it's going to ask me for my password now i'm going to type the password but note it is not going to make any cursor movement however i am indeed going to type it and press enter and it looks and sees if there's anything else that can be updated and if there are updates that will perform them and now we can install the software application that i wanted to install now the application i'm going to be installing is something called the chase app and you may not have heard of this because it's a relatively new application but i find it to be very handy what chase app is is it's a search engine except it's a very special search engine allows you to search some of your own properties properties can include github they can include google docs they can include dropbox etc so if you're creating content like i do this is a very handy application and it can be installed quite easily now i've just pasted in the command to install it and i got that off of the cheat sheet that i have and you'll notice it's another sudo command and the next thing after that is snap now snap is another method of installing applications in ubuntu and other linux systems in fact the linux store over here the application software store is now using snap as well so a lot of times this is equivalent to that so i'm going to just call up the snap and i'm going to install the chase app snap i'm going to hit enter now you'll notice i didn't need to type my password that's because the first time i typed sudo up over here it took the password i'm still elevated within the same session before it times out you don't need to type the password every time you do sudo and the installation just proceeds and now it is installed now let's go and take a look for it and here it is chase app i'll open it up and the very first time i need to connect to it with a login like google microsoft or linkedin i'm going to use google and now the case app has been installed i can close the web browser right now i'll close the terminal as well let's go bring the chase app back up and there it is and there's a search box here so if i type in arduino it shows me a number of things that i have for arduino now i've already configured my chase app on another computer so that is linked to things like my google drive and my github and my trello etc etc yourself you will need to go into the configuration screens on chase app and set the applications that you were going to be using and log into them individually but once you do that it's attached to your chase app account and it will go on every machine and chase app by the way is also available for windows and mac os x and i have it on all of my computers so now that we've got our computer all set up we're ready to add some applications and the first applications i want to add are integrated development environments or ides these are essential applications for developers i'm sure you've used a few ides before and if you've already got a workstation there's a good chance that a few of the ones i'm going to install right now are installed on yours so we're going to start off with what is probably the most popular ide for developers using microcontrollers and that's the arduino ide and then we're going to move on to a couple of other ones now the first ide that we're going to install is the arduino ide now this ide of course you're all familiar with and it's not necessarily the fanciest ide or even the best one for working with the arduino but it certainly is a starting point and it is an essential piece of software for your developers workstation now there is more than one method of installing this ide one simple way of doing it is to use the snap store the same way we installed the chase app and if you want to install it that way i have instructions for doing that on the article that accompanies this video on the dronebotworkshop.com website however before you install it with snap there's one thing you need to be made aware of in the snapstore version of the arduino ide the python applications that the ide depends upon are run inside a sandbox they are separate and isolated from the python applications that are already installed on your computer now in most cases this will make absolutely no difference however it is possible that if you add additional boards using the boards manager in the ide that those boards may call on a python application that doesn't exist in the sandbox and they won't work now there is a way of moving applications from the python on your machine into the sandbox but that gets pretty involved so what i'm going to do is install the ide the manual way even that has a number of different methods you can do everything at the command line but i'm going to be using a combination of a web browser the file manager and the command line to do my installation now the first thing you'll want to do is to go to the arduino ide home page to the download page and download the proper version now for me that will be linux 64 bits and that's what it's going to be for most of you who've been following along if you're using a single board computer you may need to get the arm version and hopefully you're using a 64-bit operating system there is a 32-bit version but i will warn you that some of the other software that we're going to be installing will require a 64-bit os so click on this and then download the ide now i've already done that and so i'm going to go into my downloads folder where that is and we'll go into downloads and there it is the zipped file of the arduino ide now first we need to extract this file so right click on it and do open with archive manager and the archive manager shows you the contents which is a folder called arduino 1.8.13 now keep in mind if you're doing this later than i'm doing it you may have a more recent version of the ide and that number will change we're going to do an extract right now and we're just going to extract it right here into the download directory and the extraction is completed successfully so we can close the archive manager now what we're going to do is we're going to need to move this file this folder over here actually contains the ide program and i don't really want to run it from my downloads directory that's not really a good place for it especially since i could very easily delete it so what we're going to need to do is go into the terminal and you can go into the terminal directly from the file manager by doing open in terminal and this will put you on the downloads directory if i do an ls you will see that we've got both the file the tar.xz file and the directory itself we're going to move that directory so we're going to need to do that with root permissions we'll do a sudo and then we'll do a move command which is mv and then the name of it now you'll notice that i only started typing the whoops letters ar d after that i hit my tab character and it determined what it was i wanted to move and after that i'm going to have to give it a destination my destination is the opt directory and i need to of course provide my password because i i'm doing a sudo and there we go now if you look right now behind here the file is gone and we can close the file manager by the way so now let's go and change into that opt directory and i'm going to change into that arduino directory itself so here we are and we can do an ls here to see what its contents are now there is a file over here called install.sh and that is what we are going to need to run to install the ide and so we need to do a sudo and then we need to put a period that's very important and a forward slash install sh and it is done what is actually done is it has installed a shortcut because of course the files were already there and so what we can do right now is we can go here to show applications and you'll see we have the arduino ide which we can add to our favorites now we're going to open the ide and test it out now that we've finished installing the arduino ide there is actually one more step that we need to take and to illustrate why i've attached an arduino uno up to my workstation and i've also opened up the blink sketch in the arduino ide now i'll go into tools over here and i'll show you that i've got the board set correctly right now as an arduino uno and i've also selected the port and so it should be a very simple matter of just uploading blink however since my board is already blinking at the default once per second i'm going to change blink around let's just make that 3000 and it should produce a slower blink i'm going to upload that and it looks like i have a problem and the problem here is that i don't have permission to actually go to my serial port and this is common on linux installations now what i need to do is i need to add myself to the group that has permission to use that port and on ubuntu linux the name of that group is dial out now if you happen to be running a different distribution of linux you might find that that name is different and i have a procedure in the accompanying article on the dronebotworkshop.com website that will allow you to determine what group owns that but i happen to know its dial out for ubuntu so what i'm going to do is go into my terminal and for my cheat sheet i'm going to paste this command over here and this is a command that is going to let me user mod lets me modify the permissions of a user and i'm going to add myself to the dialog group so i just need to give the name of the user which you can see very conveniently right at the beginning of the command line and mine happens to be drumbot workshop so i will add that and i'll enter i'll need to put a password because i'm using sudo and i'll hit enter now in order for this change to take effect i'm going to need to log out and log back in so i'm going to do that right now and log back in i'll open the arduino ide again and we're back to blink over here let's go modify our blink sketch again because i didn't save the modified version and see if that helped and it did indeed and if you look at my arduino it's now doing a very slow blink because it has now successfully uploaded the sketch now another ide that has become very popular for working with microcontroller boards like the arduino as well as doing a number of other tasks is platform io platform io offers a lot of advantages over the arduino ide and platform io itself is a product that runs as a plugin under visual studio code visual studio code as you might imagine from the name is a microsoft product yet this is an open source microsoft product some people don't realize that microsoft also makes open source products in order to install platform io we're going to need to install visual studio code first but before we do any of those things we need to install a python3 virtual environment for platform io so i've gone to my cheat sheet and i've gotten the command for installing this virtual environment and this is it over here and i'll enter it and of course it wants my password and i'll say yes over here and we've installed the python3 virtual environment now i'm going to go back into my cheat sheet and i'm going to look at the installation for visual studio code and this is going to be a snap installation and so i'm going to take that paste it into my terminal and now visual studio code has been installed and so let's go and do our show applications go down near the bottom and there it is visual studio code we'll open that up right now now in order to install platform io we need to install it as an extension so we'll click over here for the extensions and we'll look up platform io and here it is the platform io ide click the install button over here and it is installing you can see the progress down here in the corner and the platform io ide has been successfully installed it says you need to reload so you hit the reload now button and platform io has been reloaded and you can start platform io by hitting this little home key over here and this is the platform io environment and we can add new projects import existing arduino projects etc now i'm not going to go through the use of platform i o now because i'm going to be doing a separate video on platform i o itself because it's such an important environment for working with the arduino and other microcontrollers instead we're going to move on to our next ide now one language that has become extremely important in microcontroller development as well as development of software in general is python now you can edit python using extensions for visual studio code but you could also install a dedicated ide for working with python i'm going to install one called pycharm and it's very easy to install because it comes in the snap store so i'm just paste this in for my cheat sheet give it my password and let it install and it should be installed right now we'll go into our show applications and here's pycharm i'm going to actually add that to my favorites and launch it you need to accept the privacy policy let's just say that we read all of this text and you can send anonymous data if you like this is just something that they do in order to track for bugs and things i'll do that and we're at the pycharm screen right now now you can add things to pie charm you can add plug-ins to pie charm there are quite a few of them that you can look at over here and one very interesting thing about pie charm is that there's also a learn pycharm and you can set this up it starts off a project and it'll start you learning how to use this incredible ide so this is a really great ide for both beginners and experts with python now a lot of what we do as developers with our workstation computer is we work with text files the programs we write are essentially text files that are eventually compiled into code now the ides that i've already installed are quite capable of working with text files but i like to use a separate text editor because i find it to be more full featured so i want to show you how to install the text editor that i prefer plus a couple of other utilities for working with files on your workstation now the next software product i'm going to install is a text editor now i know i already have the basic text editor g edit over here but i'm going to install a more advanced text editor it's actually more of a code editor and there are several of these available and this is sort of a matter of personal preferences but the one that i like the most is one called genie i like genie because of its syntax highlighting i like it because of the fact that it shows me all of my variables in use in the side it recognizes all sorts of different languages and genie is also available for linux windows and the mac so as i move from computer to computer i can maintain the same environment so i'm going to install genie right now i've already taken this out of my cheat sheet and it's pretty simple you just do an apt-get install genie and provide your password and say yes over here and that was it genie's installed as simple as that let's go and take a look for it over here i'm going to add it to my favorites because i use genie a lot and we'll open it up and this is the genie code editor now if you've used the raspberry pi you might be familiar with genie because it is also included on the standard build of the raspberry pi operating system again it's a very useful text editor and if you don't have a favorite text editor i would highly recommend it now the next file handling utility i'm going to install is something called melt now what meld is is it's a difference comparator in other words what it does is it takes two files or for that matter two folders and it highlights the differences between the two of them and this can be very useful when you're working on code samples and have another sample that has been modified by someone else you can go and highlight and see what the differences are now i've already gone to my cheat sheet to get the installation string from meld and i'm going to paste it into the terminal one thing i want you to notice about this install string is the fact that there's a slash y in it and what that does is you'll notice in a few of the previous installations i had to answer a why or yes to indicate i want it to continue if you place this in the installation string this will make it answer it automatically so you won't be prompted for that and so now that i've got this over here let's enter it and of course i need my password and we have it installed and so let's go and take a look and here is meld i'm going to add that to my favorites and open it up we can do a new comparison let's just do a file comparison right now now the first file over here i'll go into my arduino and i've created two versions of the blink program just for this i'll go into here and i'll open blink1.ino for my next one i'm going to open blink2 and i'll hit compare and right now you can see that it's got the two files side by side and down here is the difference and the differences in one of the blinks i've got a delay of 3000 and the other one i've got a delay of 500. these arrows over here allow you to move code from one file to the other so if you want to adjust a file or take some segments of one file and move it to the other one you can use these arrows to do that so as you can see for comparing code files meld is a very useful utility now this next program probably doesn't need any introduction simply because i've already introduced it i'm going to install etcher onto my developer's workstation now etc of course is the program that we used in the first place to get the ubuntu image onto a usb stick but etcher will also transfer images onto sd and microsd cards and that is very useful when you're using microcomputers such as a raspberry pi or nvidia jetson nano that require a micro sd card to boot up so you're definitely going to want to have a copy of etcher now the installation of etcher under linux is actually many steps so i'm definitely going to make use of the handy cheat sheet file the one that i've provided on the dronebotworkshop.com website that you can download and so the first statement over here adds the source for etcher into my system and it uses an echo so it's actually going to print back something after i do it so i'm going to hit enter and it's going to ask my password because you'll note there's a sudo in the middle of this and it prints back what it had to echo now the next thing i have to add is a key server number and this is again something you're definitely going to want to copy because i really wouldn't want to have to type this out manually and there we go and it's imported the key now we're going to do an update right now just to refresh the queue and now we can finally do the installation of echo and etcher has been installed and we should be able to see it now in our show applications there it is right here and you're familiar with that here of course what we have to do is add a source file then select the target and just flash it and this will be a very useful utility for you when you're working with microcomputers now one common requirement for software developers is to work with code repositories such as github this allows us to share our code and to work on code with other coders allowing us to check out files and check them back in now there are a number of different clients that you can use to manage git repositories unfortunately the selection of free clients for linux is rather limited my personal favorite client for github is the github desktop however for some strange reason the github desktop is only available for microsoft windows and mac os x there is no linux version and i personally find that a bit surprising considering many software developers use linux as their platform however there are some alternatives there is get kraken which is probably the most common get client for linux however get cracking is not a free program there is a freemium version of the program but to get the full program you need to actually pay for a license and i'm trying to avoid having you install software that you need to pay for today the same would go with smart git which is another very popular git program again this requires a license and it has a freemium version now there are a couple of options you can have for a free git program for linux and i want to show them to you now the first one we can just go into our ubuntu software over here and this is a list of software that you can install for ubuntu you might be wondering why we haven't used it before a lot of the software here tends to be a bit up out of date but this has improved especially since now the software store is linked to the snapcraft store and so it's getting better and there is a client over here called get g so if you hit the search box over here and type in get g you'll see the graphical user interface for git and you can install that just with the install button over here you'll need to authenticate and get key has been installed and if you go down into show applications we should be able to find it and there it is right over here now i want to show you another get client that you can use it's a bit more advanced in git g and it's called get cola we're going to install this one at the command line so i've gone to the cheat sheet and i've taken the command which takes us over to the snapcraft store again and so this is get cola we'll say yes over here and it is installed and we can go into here and you'll actually see it's installed more than one icon it's installed the get cola icon and also git dag git cola is the actual repository manager whereas git dag is a history manager it looks at the log files in the repository and allows you to go back historically through all of the changes that you've made and between this and git g you may find something that you want to use in order to manage your activities on github and other repositories i have to confess that i still use the github desktop on my mac but if i were using linux i would definitely go for one of these two tools now these days we're working on more projects that require connections to the internet you may be using an api from an external server you may actually set up an external server yourself to use with one of your iot projects or you might be setting up something like an esp32 or esp32 cam that acts as its own web server in order to work with web servers and remote servers there are a number of communications applications that you'll find handy and this is what we're going to install next now the first network utility that i'm going to install is an ftp and sftp utility ftp is file transfer protocol and sftp is secure file transfer protocol and you use these utilities to exchange files between your local computer and a remote server the remote server can be a server on the internet or it can be a server on your local area network now you can perform ftp and sftp operations at the command line but it's a lot easier to install a gui and the one i'm going to install is one of the most popular ones and it's called filezilla and so i've already got the command line here and as you can see it's very simply sudo apt install filezilla i'll enter that and of course my password and say yes i could have put a dash y in there couldn't i and that was it filezilla is installed let's go and take a look for it and open it up and here it is i'm going to add that to my favorites and open it and i'll say okay over here and here we are and it's a very simple program to use on this pane over here in the left side you have my local directory over here when you connect to a server you'll have the server directory and you can transfer files back and forth between the server it also has a file site manager excuse me over here where you can add a number of the sites that you use all the time so that you don't have to type them in manually so it's a very versatile program and one that you're definitely going to want to install on your developer's workstation now we already know that ubuntu linux has a terminal obviously we've been using it for just about every installation that we've performed today but there's another type of terminal in fact there are several types of terminals that can be useful when attaching to remote computers and these terminals generally emulate something like a dec vt 102 or 420 now if i was using microsoft windows i would recommend a product called putty and putty is an excellent product for use as a terminal for attaching to remote servers on the internet however putty does not run under linux but you can run it under linux using something called wine wine is a windows emulator and it provides a windows type environment and it lets you run a couple of windows programs and putty is one of the ones that will run that way another one that will run under linux natively is something called x term and we're going to install x term right now and so i've already taken it out of my cheat sheet and we're going to do the installation and it's been installed and let's go and open x term which we'll find at the very end here because it's and here it is and as you can see it is quite small another one thing you'll notice when you first get to x term is it doesn't appear to have any menus but it actually does what you need to do is hold your control key down now when you click the mouse using the left button you'll get a whole menu of things over here such as full screen allow send events etc etc log to file if you want to make this a bit better to read which i certainly do hold that control key down and hit the right one and then you can set the font i'm going to set it to huge which isn't really that huge but it is certainly a lot easier to use so if you need a different type of terminal to attach to a remote device you can certainly try x term now the next utility we're going to use has a very interesting name this is the angry ip scanner now i'm not quite certain what all the anger is about but this is a very useful utility to scan your local area network and determine what devices are attached to it and what their ip addresses are and we've used this before in previous dronebotworkshop.com videos now in order to install this you need to go to their web page download section and there's a link to that download section in the article accompanying this video as well as on the cheat sheet now you need to get the correct package obviously we're looking for a linux package and we want the debian package over here because this is for ubuntu and this is the 64-bit debian now you may be installing on a different distribution of linux and if so you may wish one of these other packages there's also a 32-bit package as well down here for debian as well at any rate you'll need to click on that and download it i've already done that so i can minimize my web browser now and go into my file manager and you can see it right here in my downloads directory i'll right click on it and say open with software install which is how you install these dev packages in ubuntu and basically i could just hit my install button i need to authenticate and the installation will start and the installation has been completed we can close this and i can also close the file manager and i can go into here and i can see my very angry ip scanner over here and i'll close this right now we'll go up here and all we need to do is do a start and it's going to scan my network now i should point out that my network doesn't have a lot of devices on it because i have a couple of different subnets in my network and also all my wireless devices are on a mesh network so they won't appear over here but as we scroll down we will see some devices attached to my network and here's a nas here's another nas here's one of the computers in my office a raspberry pi another raspberry pi so there are a few computers that i can see and i can determine what i p addresses they are using and that way if i'm assigning ip addresses to other devices they won't conflict so this is a very useful utility despite the fact that it's a bit angry now one thing that a number of advanced hobbyists do with their projects is they document them or even create printed circuit boards out of them and there are a number of applications that can be used in order to assist the creation of schematic diagrams of block diagrams and of printed circuit boards now i can't cover every single one and usually when you find one of these programs you tend to focus on that one exclusively but i'm going to show you how to install a couple of popular programs for creating schematics and printed circuit boards now the first printed circuit board utility that we're going to install is something called kicad now ki cad is a very popular pcb utility and it also comes with another utility called e-schema which allows you to do schematic diagrams now there are a number of different versions of kicad there is a professional version and an educational version and both of those require a license to use however there is a third version called the community version which is free to use and so we're going to use our cheat sheet to install it now the first thing we need to do is we need to add a software repository a repository is a place that stores all the updates for the software and we need to add one for kicad and so i'm going to add the repository with this command over here give my password and the repository has been added now i'm going to do an update right now because it's pretty standard to do that however i should note that with this version of ubuntu 20.04 it is no longer necessary to do updates after you do a software repository ad however with previous versions of ubuntu and with other distributions of linux it is necessary so i'm going to do it anyway and certainly has no harm in doing that okay now i'm going to go back to my cheat sheet and actually get the installation string that i need to enter in order to install ki-cad and the installation is complete i'll go into my show applications and here's kicad you can also see the each schema and the gerb view which is for viewing gerber files as well so this is quite a full featured utility or suite of utilities and you can use this of course to create schematics and printed circuit boards now another popular pcb editor is easy eda and easy eda is a bit different because it can be used online or as a desktop client although there are more features on the desktop client you can synchronize the work that you do online with your desktop clients an easy eda also makes it easy to pass all of your printed circuit board designs off to a number of popular pcb manufacturers so you can do it all in one shot and for this reason it's become very popular now this is the easy eda download page and you'll find the link to that page both in the cheat sheet and on the article accompanying this video on the dronebotworkshop.com website now what we want of course is the linux client and i've already downloaded my linux client and i've got it here right now in my downloads folder and this is it over here so i'm going to right click on this and open it with the archive manager and click extract and i'm just going to extract it where it lives right now and i'm going to close that because the extraction has been completed and you'll notice there's a few other files in here right now that's extracted including this zip file over here now you don't need to use the archive manager on that what we're going to do is we're going to open this in the terminal and from the cheat sheet we've got the installation line which is very basic over here it's just simply sudo bash install.sh and of course i need my password and the install is finished and one thing you'll notice actually is that it did do indeed an installation if i go into file system and i go into opt you'll note that i now have an easy eda directory so it created everything for me a bit easier than it was when we installed the arduino ide now i can close this close that and we'll go over here and we should be able to find easy eda and here it is right here and it asks you for the run mode setting and i would suggest a teamwork mode and so your projects are actually stored up on a cloud server and therefore you can work on your desktop you can work online and you can also work on other computers with a desktop client so this is very versatile and you'll apply that and you can open easy eda it's going to ask for a data storage directory i may change that later but right now i'm just going to take the default one and here's easy eda and it starts off with a little utility that shows you what all the main features are you can go through this if you wish and say done and we are now in the easy eda editor where you can create schematics and then create printed circuit boards from those schematics images and video and audio files have become more and more part of our projects and while you may not work with these type of files that much it's something that you'll probably find yourself doing more and more of when we create more advanced projects especially iot projects also you might be someone like myself who documents or videos the work that they do and in that case you're going to find some of the next applications we installed to be really useful there are applications that allow you to work with images video and audio now vlc media player is an extremely popular media player but it is more than just the program to play videos with in addition to playing video and audio files vlc is capable of recording your desktop it's also capable of taking screenshots from existing videos so for documenting your work and for documenting procedures vlc is an excellent program to have and it's very easy to install because it's on the snap store so all we need to do is insert this line put our password in and vlc has been installed and we should be able to see it over here down near the bottom of our applications and there it is vlc media player again this is much more than a media player now this next program is actually one of my favorites and i've been using it for many years it is called shuttered it is a screen capture program however shutters development seems to have frozen a few years ago and it's no longer on the distribution channel for ubuntu fortunately some people have brought it back and have created their own repository for it so you can still install shutter which makes me very happy because as i said it's one of my favorite programs now first we need to install the repository i'm going to use my cheat sheet for these commands and paste the first one in and enter it and my password press enter to to add the repository and the repository has been added now i'm going to do an update again with this version of ubuntu that's not exactly necessary but because it is for previous versions and for other distributions so let's do it to stay constant and now finally i can go back in the cheat sheet and do the installation of shutter which is actually pretty simple and shutter's been installed i'm going to install an extra addition to it though that they were kind enough to put on this repository and that's the gnome web photo edition this will allow you to take a screenshot of an entire web page just by putting its url in and so we'll paste that in and there we go so now we can go in and open shutter and here it is and this is shutter and shutter just allows you to take a selection of a window the entire desktop or a selection on your screen so you can do a manual selection if you wish so if i want to take this i'll do a manual selection i'll hit enter and now as you can see i've taken a screenshot of it the web edition is this over here and you can just put a url of a web page in and it'll take a screenshot of the entire page including what's below the fold so this is still a very useful utility despite the fact that it's not currently being developed now the final utility we're going to install today is something called peak and what peak does is it's a screen recorder but it produces animated gif files and these can be very useful when you're doing an instructional document and so in order to install this once again we need to add a new repository and i've copied this line from my cheat sheet and i'll hit enter to add the repository the repository has been added i'm going to do an update and finally the last line we're going to use from the cheat sheet is we're going to install peek and we'll go into show applications and see if we can find it and here it is now it's a pretty cool little program what you do is you put it over the area you want to record so let's say i want to record in my terminal over here i'll put it there i'll do record as gif it does a little countdown first and then it gives me back my screen and so what i'll do here is i'll just hit my arrow keys because the arrow keys inside the terminal go back through your history and i just want to do this just so i have something to show in my recording i'll stop my recording now and it asks me where i want to save it and the name it's going to save by default into the videos that's fine i'll keep its name and we'll go into there go into the videos directory and here we have our animated gif and as you can see that works pretty well and this is an excellent tool for doing documentation of your projects well believe it or not we have finally made it to the end of the video and if you come this far you really deserve a reward and i'm hoping that that reward is that you're going to also have a brand new developer's workstation that you can be using for all sorts of microcontroller and microcomputer projects now remember i have a cheat sheet available a text file that you can just use to copy and paste all of those commands into the terminal you will find a link to that cheat sheet right below this video and also below the video you'll find a link to the article on the dronebotworkshop.com website that accompanies these videos so between the video the cheat sheet and the article you should be able to get through this project with no problem at all another thing you might want to consider doing is follow the link to join the dronebot workshop newsletter the newsletter is something i occasionally send out just to let you know what's going on here in the workshop it's not a sales letter by any means it's free all you need to do is click the link and give me your email address and another thing you might want to do if you haven't done it already is discuss this video and the best place to do that well you already know is the dronebot workshop forums and you'll find the link below this video as well to the forums and information about joining and it is also free and finally a couple of the software applications that i've used today such as pycharm and platform io are so important that i am going to be doing complete videos and articles about those and the best way to find out when those are released is to subscribe to the youtube channel so if you haven't done that already please do i would very much appreciate that you just need to click the subscribe button below the video and also would you do that please click the bell notification and that way you'll be among the first to know when i make a new video so until we meet the next time please take care of yourselves please stay safe and i will see you again very soon here in the dronebot workshop goodbye for now [Music] you
Info
Channel: DroneBot Workshop
Views: 250,862
Rating: undefined out of 5
Keywords: Linux, Ubuntu Linux, Arduino IDE, PlatformIO, PyCharm, KiCad, EasyEDA, Geany, VLC Media
Id: zpGZ3rZQ90I
Channel Id: undefined
Length: 88min 10sec (5290 seconds)
Published: Wed Dec 23 2020
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.