Shop OBEX P1 Docs P2 Docs Learn Events
How to get started with Linux ? — Parallax Forums

How to get started with Linux ?

We have a client that wants our GUI to be on Linux.
Right now it is on windows and we use either Excel or Access with VBA code to handle all the communication with our equipment (FTDI serial at 1MBaud).

I have never used Linux and I don't know where to start.
I have a laptop with windows 10 that I don't use and I would like to convert it over to Linux. I have no idea how to do that.

I'm confused about the different "versions" of Linux. Like what is the difference between "Mint" "Ubuntu" "Red Hat" etc ? Aren't they all Linux ? Will a program (.EXE or whatever it is in Linux) run on all of them ? Or do you have compile for each version ?

Any advise about how to get started would be helpful. This will be in an engineering setting if that makes any difference. Specifically product testing with lots of data to be stored.

Thanks,
Bean
«1

Comments

  • kwinnkwinn Posts: 8,697
    edited 2020-10-15 15:21
    Bean wrote: »
    We have a client that wants our GUI to be on Linux.
    Right now it is on windows and we use either Excel or Access with VBA code to handle all the communication with our equipment (FTDI serial at 1MBaud).

    I have never used Linux and I don't know where to start.
    I have a laptop with windows 10 that I don't use and I would like to convert it over to Linux. I have no idea how to do that.

    I'm confused about the different "versions" of Linux. Like what is the difference between "Mint" "Ubuntu" "Red Hat" etc ? Aren't they all Linux ? Will a program (.EXE or whatever it is in Linux) run on all of them ? Or do you have compile for each version ?

    Any advise about how to get started would be helpful. This will be in an engineering setting if that makes any difference. Specifically product testing with lots of data to be stored.

    Thanks,
    Bean

    I switched from Win10 to Linux Mint several years ago and have been very happy with the result. I found that adapting to Mint was relatively quick and easy. The latest version is 20.

    PS, common software packages are easy to find and download, and you choose when and which updates to install. I am using LibreOffice , which IMHO is every bit as good or better than MS Office. Have yet to find any task that I used MS Office for that cannot be done by LibreOffice. Also found PropellerIDE works well for P1.
  • rosco_pcrosco_pc Posts: 449
    edited 2020-10-15 15:15
    The different version are distributions and there are literally hundreds of them (often coming and going).
    The common denominator is the linux kernel and GNU userland programs (things like shell/commandline, ls, ...)
    There are 3 big distributions that have spawned 'sub' distribution. Each main distro normally has it's own package manager to install software and you can provide makefiles for each. But it is possible to run a program build for 1 distro on another distro, condition is mainly that glibc and other used libraries are similar.
    Lately there has been an effort to have a generic package manager creating packages that can run on every distro, two main contenders snap and flatpack.

    Some main distro:
    red hat - RPM based package manager, spawned: fedora, centos. Is enterprise centric and normally runs older kernels (long term support is important here).
    debian - APT based package manager, spawned distros: Ubuntu, Mint, .. . More a user disto, although also heavily used in enterprises. Ubuntu is getting very popularin enterprises.
    suse - RPM based package manager, not sure if it spawned any of it's own also enterprise centric
    arch - pacman package manager, more 'engineer' centric
    gentoo - portage package manager, focus on 'performance' and intended to build you own with optimized flags
    ...

    https://distrowatch.com/ has a nice overview of available distros with a popularity rating.
    Edit: on my home PC I currently run the latest version of linux mint, but I used Arch, Debian, Ubuntu and Slackware for longer periods of time. And I'm in the process of moving over to OpenBSD another Unix variant.
    Eric's fastspin has excellent support for linux :)

    You can dip your toes in linux while on windows 10 with WSL (https://ubuntu.com/wsl) and with a newer win10 build even WSL2: https://docs.microsoft.com/en-us/windows/wsl/compare-versions
    When running an X-server under windows you can even run graphical linux programs :)
    I use this on my work laptop.



  • RsadeikaRsadeika Posts: 3,822
    edited 2020-10-15 15:29
    First question to ask your client, what Linux are they using right now. Another thing to consider, if you have developed a GUI already, maybe a cross-compiler that does Linux binaries also, would be a consideration. Then all you would have to worry about is loading and running the "new GUI" on the Linux distribution.

    Now, if the client needs some kind of automated program update system, that gets to be a little complicated.

    If you recall, SimpleIDE had both a Windows and Linux version. I believe jazzed used the same development IDE to create both binaries. I believe he made the Linux binaries to work with the Debian, or APT based package manager system. Yes, there are those package manager things that you will have to consider.

    Ray
  • Whatever flavor of linux they choose, BST can handle the prop1 for spin, pasm, and propbasic at the time it was last released. My have to find some libs and one font, but I had no problems using it either in mint20 and FC32.
  • BeanBean Posts: 8,129
    So you are saying there is not a actual "Linux" operating system ? And that the different versions are not binary compatible ?

    Our GUI is written in VB.NET. Is there any way to convert this to run on Linux ?
    We also often use excel with VBA code to control things. Is there a program for Linux that can do something similar ?

    Thanks,
    Bean
  • Easiest to stick to one of the bug distros, I have been using Ubuntu. There are lots of good step-by-step guides to EVERYTHING.

    The VB script is not going to work, but there are several ways to go, in order of how I would use them..(Entirely driven by how comfortable I am in each)

    Shell
    Python
    Lua
    C

    The tricky part for me was getting my head around the serial ports as files, Yes, Windows does this, but in Linux it goes a bit deeper.

    The other common problem is the permissions. the user account that actually runs your programs must be part of the 'Dialout' group. Easily done -IF- you know how. Again, lots of step-by step available.

    https://askubuntu.com/questions/58119/changing-permissions-on-serial-port
  • Big distros... Freudian slip???
  • Many years ago, on this forum, there was a long discussion about Linux. Linux is a kernel, it is a command prompt version. When you are developing the GUI part for the Linux kernel, that is where these different distributions show up, as I see it. Yes the Linux kernel is an OS, but the GUI part is what makes palatable for the masses.

    Ray
  • I've been using Linux full-time for a while and have gone through the usual "distro hopping" that most users go through.
    I eventually settled on Fedora since everything just works out of the box and I was tired of spending so much time customizing everything.
    I've always really wanted the BSDs to be more successful and to use one full-time, but Linux gets way more attention from companies which results in more developer time.

    If you want to try Fedora out, go to https://getfedora.org and it has some pretty good instructions on getting setup (the other distros will have something similar as well).
    The basic idea is that you'll get a thumb drive, use their tool to write an image to it, and then boot the target computer from the thumb drive. You'll dropped into a "live" copy of Fedora (runs from the thumb drive and leave your HD alone) to mess around with before committing to install it on the hard drive.
  • Yes, binaries run on any distro. Microchip, for example distributes their MPLab X as a binary with an installer that works outside the whole competing packages mess.

    There can be dependencies, and the package systems were developed to ensure that everything the binary needed was installed with it. If you keep it simple you work outside all of that. Like, for instance FlexGUI for the Propeller1/2. You just copy the binary somewhere and run it.

    LibreOffice is great. I think it has the ability to use many scripting languages in the same way Excel, for instance used VBscripting, just not actual VB unfortunately...

    The GUIs are provided by the X-Server. Desktops on top of that come in 2 main flavors, KDE and Gnome. All distros I know can run either or both! Xfce is popular with folks running Linux on very old system It is very lightweight.

    It is a little like the old days, when Windows was a program that ran on top of DOS. The difference is that the X-server is so integrated that it is hard to find a distro that doesn't just run it by default. Very Win 10 like...
  • +1 on the live distro mentioned by emiljit
  • DavidZemonDavidZemon Posts: 2,973
    edited 2020-10-15 18:06
    Hopefully you recognize that this is a monolithic question. You could get an entire 4-year degree based on the answer to this question.

    I'd start with Ubuntu. You could choose another flavor of Ubuntu, like Mint, but I'd recommend sticking with a flavor of Ubuntu purely because it is so popular that it will be the easiest to find answers to your questions. The same could be said for Fedora; it is popular enough that you'll find plenty of answers to your questions, but I do not believe it is as popular, which means Ubuntu will be your better choice as a desktop (as opposed to server) user.

    As a total Linux noob, I'd go further and recommend you just install plain old vanilla Ubuntu. Because you have a specific goal in mind (learn how to cross-compile your app for a customer), the difference in aesthetics won't matter in the least. So don't let yourself get caught up in decision paralysis. Pick the closest thing you can to "vanilla" or "default" and you'll be on the easiest path ("easy" defined as "able to get your questions answered by a wide variety of people").

    This is probably a good place to start:

    First download Ubuntu: https://releases.ubuntu.com/20.04.1/ubuntu-20.04.1-desktop-amd64.iso
    Then create the installation media: https://ubuntu.com/tutorials/create-a-usb-stick-on-windows#1-overview
    Then install: https://ubuntu.com/tutorials/install-ubuntu-desktop

    And I see you're also asking for a brief description of what is Linux...

    Linux is an operating system Kernel.

    The kernel is the low-level (bare metal, like what we write for the Propeller) software that takes care of reading blocks from disk (hard drive, SSD, SD card, etc), loading them into RAM, communicating with the network chip to send and receive Ethernet packets, communicating with the graphics card to display visuals, interpreting mouse and keyboard inputs, etc, etc, etc. One of the most important things it does is task switching, meaning the kernel is the software in charge of switching between different programs on the same CPU core.

    What is not the Linux kernel? Some obvious stuff, like your Internet browser, text editor, and Propeller compiler. Some less obvious stuff, like everything you can see on the screen. When you're staring at the monitor displaying a Linux-based operating system, you're staring at the "desktop environment." Most DEs consist of LOTS of different programs, and most DEs are built on top of yet another layer (X11 or Wayland) called the "windowing system" which is the lowest graphical layer on top of the Linux kernel. If/when you install plain Ubuntu, you'll be staring at the "Gnome 3" desktop environment, which consists of Wayland windowing system (a relatively new X11 replacement), Gnome Display Manager (mostly just your login screen), the Gnome Shell (this is your desktop background, start menu, task bar, etc), and a common suite of applications (Gnome settings, Gedit text editor, a calculator app, etc, etc). On top of the default Gnome apps, Canonical (the makers of Ubuntu) will have also included some more applications: LibreOffice, Firefox, etc, etc.

    Will your Linux program run on every Linux OS?

    Yes and no. It is possible to get your Linux program to run on every Linux OS without needing to recompile it, and depending on how you compile, it might even be feasible to get it to run on every Linux OS that your client cares about without needing to recompile it. Things like how it is packaged (plain binary file, .rpm, .deb, etc), what shared libraries it needs, what versions of those shared libraries it needs, what kernel features it needs, etc, etc will all play into its compatibility. Let's get your toes wet in Linux before worrying too much about all this.





    Where to start? Install a version of Linux and simultaneously find out what version your client is using!

    One more thing: the Linux family tree. @rosco_pc started to get into this but I want to phrase it differently:

    I'm going to focus on three BIG names in the Linux world, and they are all at the top of their family trees (i.e.: not "based on" any currently living anscestors): RedHat Enterprise Linux (RHEL), Debian, Arch. It's important to recognize what family tree your particular distribution inherits from because it enables you to ask for help from a wider audience. If you're trying to fix something in Linux Mint, and someone describes your exact issue with Debian, chances are VERY high that it is applicable. If they describe your problem in Fedora or Arch... it's possible, but less likely... just gotta keep your eyes open.

    RHEL is a paid-only version common in the enterprise world. It has two children: Fedora and CentOS, both of which are free. Fedora is a common desktop OS used by lots of end-users and funded/maintained by the RHEL team. CentOS is community-maintained and forked off of RHEL. Though you can get CentOS with a graphical desktop environment, it is far more common to use it only on servers (aka: folks too cheap to pay for RHEL lol).

    Debian is a free version that is common on embedded systems and... I'm not sure anyone uses Debian itself for anything else anymore. A fork of Debian, called Ubuntu, was created by Canonical and quickly skyrocketed into one of (if not the) most popular Linux distribution. There are many "flavors" of Ubuntu all maintained by Canonical themselves. A "flavor" is the same operating system but with a different package suites/desktop environments (imagine Thunderbird + Firefox instead Outlook + Edge... that kind of "package suite"). If you opt for the "server" flavor, you'll get Ubuntu without any graphical component. If you opt for "Desktop" you'll get Ubuntu with the Gnome desktop environment. On a new rung of the family tree we have Mint and PopOS, two children (forks) of Ubuntu. These are maintained by groups outside Canonical and, like the "flavors" mentioned above, just vary in default settings and installed packages.

    Arch is ugly step child. Rather than bundle a bunch of updates every 6 months into a new "release", Arch provides the latest version of every package all the time. This is referred to as a "rolling" release distribution. It has a few rough edges, and so someone created "Manjaro" and probably other forks as well which make it a little easier to use. If you like bleeding edge, Arch or one of its descendants is the one for you.
  • Bean wrote: »
    Our GUI is written in VB.NET. Is there any way to convert this to run on Linux ?
    Maybe you get some answers there: Mono — Visual Basic support
  • Bean,
    I dual boot Windows 10 and Ubuntu on a Dell laptop specifically for my propeller and Stamp IDEs. For my limited skill set, Ubuntu is a nice fit. As @DavidZemon noted Ubuntu has a good following so search results for answers are plentiful. So that's my recommendation for someone just getting started with Linux.

    Doc
  • Bean, I've been wanting to get an ThinkPad on ebay just to build a Linux laptop. Ubuntu or Linux mint cinnamon get my vote
  • Peter JakackiPeter Jakacki Posts: 10,193
    edited 2020-10-15 21:58
    Over many years I have tried many different distros, and I still do, but the my work horse is Linux Mint simply because it does everything I want and it works out of the box and uses Cinnamon as the desktop manager. I normally have 9 desktop workspaces setup for Browsing, datasheets, dev, Virtualbox, documents etc so that I can quickly flick between these messy desktops windows/workspaces.

    I explained the Linux distro thing to my wife this way: You know IPhone is IPhone and you can't customize it, it is what it is but Android phones all seem to be different, right? Even though the newest models all run Android 11 or whatever, they use different "launchers" (the desktop) and may also work a bit different under the hood etc. Samsung messes about under the hood too much according to Google while others are more pure Android etc.

    My advice though is just create a live Linux boot USB Flash and boot your laptop from it. You may need to get into the BIOS to enable it to boot (I think this has more to do with Microsoft trying to lock out Linux myself). Most distros are "live" distributions that can boot and configure very quickly even from a USB Flash drive and from there you can use it or even install it which I do after I use Linux to repartition the drives etc. Once you have Linux installed on a computer it is very easy to create more Linux Flash drives with different distros that you can check out. From a live boot you can manually repartition the drive with several 20GB or so partitions to allow for different Linux flavors installed since Linux includes the GRUB boot manager that comes up with a menu at boot to select Windows (if you leave it on there) and any other Linux or other OS. But stuff like LibreOffice and a whole plethora of apps are preinstalled and ready to run. Linux normally has a software package manager which is similar to how smart phones access and install new apps.
  • evanhevanh Posts: 15,126
    edited 2020-10-15 22:19
    And after you've chosen a distro, you can further choose what desktop environment to run with it. The two big ones are Gnome and KDE but there is smaller DEs too, for smaller drives and/or slower hardware. Ubuntu offers Mate I think, which I assume is targetted at touchscreens, ie: cellphones. Not sure, never actually seen Mate.

  • I would recommend downloading "live" versions of Linux Mint (my fav) and other flavors to try them out. Install each on a CDROM or memory stick. I like KDE, but Xfce has a smaller footprint and may well fit your needs.

    -Phil
  • I would recommend downloading "live" versions of Linux Mint (my fav) and other flavors to try them out. Install each on a CDROM or memory stick. I like KDE, but Xfce has a smaller footprint and may well fit your needs.

    -Phil

    CDROM? What's that? oh wait ..... those things that take time to spin up and seek to a track and read at breakneck speeds measured in multiples of floppy read speeds? Nah.

    I have several small sticks on my keyring with different distros. It is always quick and easy to boot any computer, old or new. But sometimes, and just sometimes, they don't or won't boot USB, and if it is old then it is handy to have one of those digital drink coasters handy.
  • Phil Pilgrim (PhiPi)Phil Pilgrim (PhiPi) Posts: 23,514
    edited 2020-10-15 23:18
    CDROM? What's that?
    Yeah, yeah, I know!

    Matter of fact, I've lately been recycling computer magazines and QSTs going back to the '80s. And I still have 5.25" floppies to get rid of. Not to mention old tech manuals dating back to the same era. In the words of Mr. T, "Ah pity the foo who inherits this place!"

    -Phil
  • Well in my case, I use Slackware Linux on a Dell who's the one I started in this business with. Whatever the folks at the Pi foundation are calling their OS next, and finally Suse in Command Line mode here, via WSL.

    Uh oh, Phil, what's that bot doing driving a boat towards your location? He's got company, there are six of them in that boat.
    No mascot, off for the week, and no recorder.
  • RossHRossH Posts: 5,336
    Getting started with Linux is easy, and (as others have suggested) you can "try before you buy" by booting a live distribution from a USB drive.

    But beware - once you have experienced how much faster your machine runs under Linux, you may be sorry if you ever have to go back!

    Personally I would recommend Ubuntu as having the best combination of stability, reliability, and ease of use - but Debian is good too, and I hear from Windoze users that Mint is also good, and easier to transition to from Windows 10.

    Ross.
  • Might as well go with a few .5T or so USB SSDs since they are getting cheaper now. Then you could boot to whatever environment and all that you want. Flip out one and boot the next for a different project.
  • Rasberry pi is a good example, Debian.
  • Ubuntu is good for desktops
  • btw, I have an old i3 laptop that I use with our TV as the media center, for streaming anything etc. It used to run Linux Mint off the internal hdd but that died so I replaced it with Linux Mint installed to a Sandisk "Ultra Fit" USB Flash drive because these ones barely stuck out of the USB port. It works really well and even though it's only a normal Flash drive on USB 2 on an old i3, it is really snappy and never has problems with different video formats etc. The reason I use Linux Mint over Ubuntu has a lot to do with Ubuntu's Unity desktop and lap of codecs etc although things have changed in that respect. The good thing is you can try them out very easily. But if you install them then please partition the drive so that you have at least one spare partition to install another or newer Linux to and also a partition just for your "home" files which will always be common to any Linux you install or change to. Swap file is also recommended.
  • LtechLtech Posts: 366
    edited 2020-10-16 07:02
    something like Xojo ... https://xojo.com

    I use it long time ago as "realbasic" was the name, close to VB

    https://docs.xojo.com/UserGuide:Migrating_from_Visual_Basic
  • Cluso99Cluso99 Posts: 18,066

    My advice though is just create a live Linux boot USB Flash and boot your laptop from it. You may need to get into the BIOS to enable it to boot (I think this has more to do with Microsoft trying to lock out Linux myself).
    You’re being paranoid!
    Nah. On second thoughts I know you’re probably right :(

    And I dislike windows. This *nix stuff is a dog’s breakfast! MS all is forgiven. It may be slower, but at least it’s easier for those of us who just wan5 to get something done ;)
  • Linux can get real technical because you can get real technical with it and some distros require you to be real technical. But that's why I recommend Linux MInt above all because it is very easy to use and very Windows-like and is ready to go from live boot or install without needing to install codecs and 3rd party stuff just to do normal things.
    BIOS setting may need to be done but only the first time.

    If I load Linux onto a PC for a non-savvy user, they just use it, no problem, but the "savvy" user seems to have a "problem'.
    What could possibly be the problem do you think? :)
  • Be sure to install webmin on your linux machine. It's a web-based system that makes managing and configuring linux much easier than all that command-line fol-de-rol.

    -Phil
Sign In or Register to comment.