Announcement

Collapse
No announcement yet.

Raspberry PI2 Install for Dummies

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    #16
    The answer is probably to run a thread, sit in that thread and try and read the port to establish whether or not the termination character is there. I made changes to determine the OS type and if it was Linux then I started this thread. I then tried testing it and I only have the facility to try and run a Linux install in a VM. I loaded VMWare player and what do you know, I cannot get the COM port to pass through at all and no serial ports appear to be presented. I have no other testing facilities and I am not buying a R-Pi just for testing when there is not necessarily a guarantee what I have written will work or whether or not I could ever get it to work.
    FYI
    I have written a plugin, Omnistat 3, that uses serial communications. The same code runs under both Windows and Linux. It uses a separate thread to poll the thermostats in a continuous loop. I have not noticed nor had reported to me any heavy resource usage as a result of this methodology.

    If you used common code for both Windows and Linux then you could test it under windows. My experience is that the serial communications will work the same under both OSs.

    I could share some code snippets (C#) with you if you are interested.

    Comment


      #17
      Hi All
      I have installed the Pi version and it is asking me to register... I was expecting to have a trial period first... can anyone help me with this?

      Comment


        #18
        Order of operations for HS3 on Pi

        What is the best order of installation and updates? will any of them mess up the image that rmasonjr provided?

        I am doing something wrong, I have a persistent problem of file not found. some of the time I can see the file in GUI but not in terminal

        I can get the image rmasonjr provided to work, but some of the time I have problems with the mono install, and I always have problems with the HS3 install.

        The error messages always have to do with file or directory not found


        Thanks for all your contributions

        John

        Comment


          #19
          file not found during HS3 install

          What is the best order of installation and updates? will any of them mess up the image that rmasonjr provided?

          I am doing something wrong, I have a persistent problem of file not found. some of the time I can see the file in GUI but not in terminal

          I can get the image rmasonjr provided to work, but some of the time I have problems with the mono install, and I always have problems with the HS3 install.

          The error messages always have to do with file or directory not found

          homeseer@RPi2 ~/HomeSeer $ tar zxvf ~/hslinux_hs3_3_0_0_174.tar.gz
          tar (child): /home/homeseer/hslinux_hs3_3_0_0_174.tar.gz: Cannot open: No such file or directory
          tar (child): Error is not recoverable: exiting now
          tar: Child returned status 2
          tar: Error is not recoverable: exiting now
          homeseer@RPi2 ~/HomeSeer $ rm hslinux_hs3_3_0_0_174.tar.gz
          rm: cannot remove `hslinux_hs3_3_0_0_174.tar.gz': No such file or directory
          homeseer@RPi2 ~/HomeSeer $ cd ..
          homeseer@RPi2 ~ $ sudo mv HomeSeer /usr/local
          homeseer@RPi2 ~ $



          Thanks for all your contributions

          John

          Comment


            #20
            What is the best order of installation and updates?

            Do not install HS3 or even try until you have a good Wheezy up to date base.

            1 - sudo apt-get update
            2 - sudo apt-get upgrade

            Reboot and do it again.

            This will take a very long time. Easier to install Webmin and do the updates from the GUI.

            You can also just download most current Raspbian Jessie base from here (which might be better today). All you need to do is add mono to this build to get going.

            will any of them mess up the image that rmasonjr provided?

            No.

            Don't install HS3 until you have fully updated Rob's image.

            HomeSeer should sit in the /usr/local/HomeSeer directory as there are static references now in the Linux build to said directory.

            Create a password for root and make sure it works remotely.
            - Pete

            Auto mator
            Homeseer 3 Pro - 3.0.0.548 (Linux) - Ubuntu 18.04/W7e 64 bit Intel Haswell CPU 16Gb- Mono 6.12.X - HSTouch on Intel tabletop tablets
            Homeseer Zee2 (Lite) - 3.0.0.548 (Linux) - Ubuntu 18.04/W7e - CherryTrail x5-Z8350 BeeLink 4Gb BT3 Pro - Mono 6.12.X
            HS4 Pro - V4.1.11.0 - Ubuntu 20.01/VB W7e 64 bit Intel Kaby Lake CPU - 32Gb - Mono
            6.10.0.104
            HS4 Lite -

            X10, UPB, Zigbee, ZWave and Wifi MQTT automation-Tasmota-Espurna. OmniPro 2, Russound zoned audio, Smartthings hub, Hubitat Hub, and Home Assistant

            Comment


              #21
              Thanks Pete,

              can you tell me the difference between the Disk Image that rmasonjr created and Jessie?

              I am trying to follow the install instructions provided by Posterboy at the beginning of this post


              John

              Comment


                #22
                Thinking it just has mono Mono 3.2.8 on it and users on it.

                There are 3 users on this distro, all with the same password: homeseer
                The users are root, pi, homeseer.

                It is easy to change the passwords of root and pi and to create a new user called homeseer.

                Homeseer program is not part of the base image.

                You really want the newest RPi2 OS.

                Well too you will learn a bit more about Linux / RPi2 starting with most currently released image.

                You will need to update he posted RPi2 build anyways.

                Note I am only posting here about a DIY RPi2 / Ubuntu Homeseer 3 (Zee-2 build, HS3 Standard or HS3 Pro for Linux) build and not a purchased Zee-2, Z-Net or Linux based Hometroller.

                You cannot update mono to most current as Homeseer 3 will not work with it.

                Current release of Mono is 4.X. Homeseer 3 will not work with this version on the RPi2 or Ubuntu.

                I tried it with my Ubuntu 14.04 64 bit build of Homeseer 3 Pro a few months back.

                I trashed HS3 such that I had to remove it and downgrade to Mono 3.12 a few months ago.

                Mono 3.2.8 was released in February, 2014 as a bug released update to Mono 3.2.7 (which is too is old now).

                I am using 3.12.1 which is a March 2015 release and works with Homeseer 3 but old now.

                You can freeze the Mono build adding this to your apt sources list.

                deb hxxp://download.mono-project.com/repo/debian wheezy/snapshots/3.12.0 main
                deb hxxp://download.webmin.com/download/repository sarge contrib


                Attached image is current for Wheezy mono builds.
                Attached Files
                Last edited by Pete; October 25, 2015, 03:18 PM.
                - Pete

                Auto mator
                Homeseer 3 Pro - 3.0.0.548 (Linux) - Ubuntu 18.04/W7e 64 bit Intel Haswell CPU 16Gb- Mono 6.12.X - HSTouch on Intel tabletop tablets
                Homeseer Zee2 (Lite) - 3.0.0.548 (Linux) - Ubuntu 18.04/W7e - CherryTrail x5-Z8350 BeeLink 4Gb BT3 Pro - Mono 6.12.X
                HS4 Pro - V4.1.11.0 - Ubuntu 20.01/VB W7e 64 bit Intel Kaby Lake CPU - 32Gb - Mono
                6.10.0.104
                HS4 Lite -

                X10, UPB, Zigbee, ZWave and Wifi MQTT automation-Tasmota-Espurna. OmniPro 2, Russound zoned audio, Smartthings hub, Hubitat Hub, and Home Assistant

                Comment


                  #23
                  Thanks Pete,

                  I have created a boot using Apple Pi baker, works well on my Mac. Pi Baker has a 1 button disk image backup which is very nice.

                  I have successfully installed RealVNC https://www.realvnc.com/products/open/4.1/winvnc.html and can use that and ssh to remotely access my Pi.

                  https://youtu.be/PFIL6xuXJ20 this tutorial was very helpful.

                  One thing was different for me: The IP address of my Pi would't work, I had to look for the IP the Pi was using on my router. I think this can also be found by clicking the twin computer icon at the upper left of the Pi GUI.

                  I created a root password and homeseer user.

                  I tried adding the code you suggested using the GUI file system /ect/apt/sources

                  raspi.list is set to read only, even when logged in as root. Do I create another list or do I need to find a way to change the permissions?


                  Thanks for your suggestions, I am learning a lot about unix.

                  Comment


                    #24
                    The IP address of my Pi would't work,

                    Sudo or use root to change /etc/network/interfaces to: (note the IPs are just an example).

                    nano /etc/network/interfaces

                    I]auto eth0
                    iface eth0 inet static
                    address 192.168.1.10
                    netmask 255.255.255.0
                    gateway 192.168.1.1
                    dns-nameservers 192.168.1.1[/I]

                    You can change from DHCP to a Static IP with the GUI.

                    That said I have never used the GUI and I do not think I have it installed right now with the Zee-2 RPi2 DIY'd box I am using.

                    If you sudo or use root you should never have any permissions errors.

                    I have never seen a raspi.list. I just changed the sources.list

                    root@ICS-RPi2-Zee:/etc/apt# ls
                    apt.conf.d preferences.d sources.list sources.list.d trustdb.gpg trusted.gpg trusted.gpg~ trusted.gpg.d




                    root@ICS-RPi2-Zee:~# nano /etc/apt/sources.list
                    Attached Files
                    - Pete

                    Auto mator
                    Homeseer 3 Pro - 3.0.0.548 (Linux) - Ubuntu 18.04/W7e 64 bit Intel Haswell CPU 16Gb- Mono 6.12.X - HSTouch on Intel tabletop tablets
                    Homeseer Zee2 (Lite) - 3.0.0.548 (Linux) - Ubuntu 18.04/W7e - CherryTrail x5-Z8350 BeeLink 4Gb BT3 Pro - Mono 6.12.X
                    HS4 Pro - V4.1.11.0 - Ubuntu 20.01/VB W7e 64 bit Intel Kaby Lake CPU - 32Gb - Mono
                    6.10.0.104
                    HS4 Lite -

                    X10, UPB, Zigbee, ZWave and Wifi MQTT automation-Tasmota-Espurna. OmniPro 2, Russound zoned audio, Smartthings hub, Hubitat Hub, and Home Assistant

                    Comment


                      #25
                      I was able to add the text using nano. I was unable in visudo or terminal

                      The odd problem that I am having is this;

                      If the file is listed in GUI Then it is not visible or searchable in terminal

                      If the file is listed in GUI Then I do not have permission to edit even in root.

                      will this problem go away if I delete or disable the GUI?
                      Last edited by JohnD; October 27, 2015, 05:48 PM.

                      Comment


                        #26
                        The GUI is running in regular user mode with no root or sudo access.

                        If you want to run something in the GUI with sudo access you have to open up a terminal window and type sudo whatever program you want to run on the GUI.

                        IE: via command line you would type sudo su; then file manager or network manager or whatever the name of the gui program it is you want to use. It's a PITA to do this.

                        I wouldn't bother with the GUI as you can do everything via SSH / Winscp / Webmin.

                        You are making it more difficult for yourself. The RPi2 GUI is a nice to have but not necessary to run or manage the RPi2.

                        None of my RPi2's are connected to monitors except for one. The one running Homeseer 3 is in the attic. The KODI RPi2 is connected to a large LCD TV in my office.

                        Have a read here:

                        http://raspberrypi.stackexchange.com...gui-operations

                        Look at the attached picture. One is regular file manager with no root access via the regular user account and the other is via sudo.
                        Attached Files
                        Last edited by Pete; October 27, 2015, 06:01 PM.
                        - Pete

                        Auto mator
                        Homeseer 3 Pro - 3.0.0.548 (Linux) - Ubuntu 18.04/W7e 64 bit Intel Haswell CPU 16Gb- Mono 6.12.X - HSTouch on Intel tabletop tablets
                        Homeseer Zee2 (Lite) - 3.0.0.548 (Linux) - Ubuntu 18.04/W7e - CherryTrail x5-Z8350 BeeLink 4Gb BT3 Pro - Mono 6.12.X
                        HS4 Pro - V4.1.11.0 - Ubuntu 20.01/VB W7e 64 bit Intel Kaby Lake CPU - 32Gb - Mono
                        6.10.0.104
                        HS4 Lite -

                        X10, UPB, Zigbee, ZWave and Wifi MQTT automation-Tasmota-Espurna. OmniPro 2, Russound zoned audio, Smartthings hub, Hubitat Hub, and Home Assistant

                        Comment


                          #27
                          Here is a quickie step by step.

                          1 - create a base image on the RPi2 and expand it to the size of your microSD card.
                          (use Rob's image or RPi2 image)
                          2 - not sure if the base image comes with SSH. Test it; if not install it.
                          3 - create your users and passwords (add users to sudoers list) if not already there.
                          4 - Stop here and test out SSH for all of the users you have and root.

                          Copy and paste login here via SSH for pi, homeseer and root. Also do a sudo su for sudoers pi and homeseer and paste it here.

                          =======================================================
                          5 - Next steps will be mono install and Webmin.
                          - Pete

                          Auto mator
                          Homeseer 3 Pro - 3.0.0.548 (Linux) - Ubuntu 18.04/W7e 64 bit Intel Haswell CPU 16Gb- Mono 6.12.X - HSTouch on Intel tabletop tablets
                          Homeseer Zee2 (Lite) - 3.0.0.548 (Linux) - Ubuntu 18.04/W7e - CherryTrail x5-Z8350 BeeLink 4Gb BT3 Pro - Mono 6.12.X
                          HS4 Pro - V4.1.11.0 - Ubuntu 20.01/VB W7e 64 bit Intel Kaby Lake CPU - 32Gb - Mono
                          6.10.0.104
                          HS4 Lite -

                          X10, UPB, Zigbee, ZWave and Wifi MQTT automation-Tasmota-Espurna. OmniPro 2, Russound zoned audio, Smartthings hub, Hubitat Hub, and Home Assistant

                          Comment


                            #28
                            Pete,

                            You are a great teacher. I have learned a lot in the last couple of days.

                            I am still struggling to understand the file permissions. I added all users to the sudoers group and still can not access most files under any login; root, homeseer, or Pi

                            I was able to edit the sources.list file once using nano, but after reboot, I have read only access.


                            John

                            homeseer@Homeseer ~ $ nano /etc/apt/sources.list
                            homeseer@Homeseer ~ $ ls -l ./sources.list/
                            ls: cannot access ./sources.list/: No such file or directory
                            homeseer@Homeseer ~ $ ls -l ./ect/apt/sources.list
                            ls: cannot access ./ect/apt/sources.list: No such file or directory
                            homeseer@Homeseer ~ $ ls -l ./ect/
                            ls: cannot access ./ect/: No such file or directory
                            homeseer@Homeseer ~ $ CD ect
                            -bash: CD: command not found
                            homeseer@Homeseer ~ $ sudo cd /ect/
                            [sudo] password for homeseer:
                            sudo: cd: command not found
                            homeseer@Homeseer ~ $ visudo /ect/apt/sources.list
                            usage: visudo [-chqsV] [-f sudoers] [-x file]
                            homeseer@Homeseer ~ $ visudo -x /ect/apt/sources.list
                            visudo: unable to open /ect/apt/sources.list: No such file or directory
                            Segmentation fault
                            homeseer@Homeseer ~ $ visudo -f /ect/apt/sources.list
                            visudo: /ect/apt/sources.list: No such file or directory
                            homeseer@Homeseer ~ $ visudo -f /ect/apt/sources
                            visudo: /ect/apt/sources: No such file or directory
                            Last edited by JohnD; October 28, 2015, 05:08 AM.

                            Comment


                              #29
                              Lets try again from scratch. Baby steps. It really will only take a few minutes.

                              I will be learning from you and will document this in the how to section here on the forum.

                              You tell me after the steps below if I have not written something correctly.

                              1 - create a base image on the RPi2 and expand it to the size of your microSD card.
                              (use Rob's image or RPi2 image)
                              2 - not sure if the base image comes with SSH. Test it; if not install it.
                              3 - create your users and passwords (add users to sudoers list) if not already there.
                              4 - Stop here and test out SSH for all of the users you have and root.

                              Copy and paste login here via SSH for pi, homeseer and root. Also do a sudo su for sudoers pi and homeseer and paste it here.

                              =======================================================
                              5 - Next steps will be mono install and Webmin.
                              - Pete

                              Auto mator
                              Homeseer 3 Pro - 3.0.0.548 (Linux) - Ubuntu 18.04/W7e 64 bit Intel Haswell CPU 16Gb- Mono 6.12.X - HSTouch on Intel tabletop tablets
                              Homeseer Zee2 (Lite) - 3.0.0.548 (Linux) - Ubuntu 18.04/W7e - CherryTrail x5-Z8350 BeeLink 4Gb BT3 Pro - Mono 6.12.X
                              HS4 Pro - V4.1.11.0 - Ubuntu 20.01/VB W7e 64 bit Intel Kaby Lake CPU - 32Gb - Mono
                              6.10.0.104
                              HS4 Lite -

                              X10, UPB, Zigbee, ZWave and Wifi MQTT automation-Tasmota-Espurna. OmniPro 2, Russound zoned audio, Smartthings hub, Hubitat Hub, and Home Assistant

                              Comment


                                #30
                                Pete,

                                Here is what I have done so far. Does this look correct? I think that I was not creating the homeseer user soon enough before. The prompt looks different now on root and homeseer which are listed at the bottom of this page. I copy pasted the visudo contents below. Does this look correct?

                                Thanks


                                Using Apple Pi Baker on Mac pro running 10.10.2
                                Format card fat 32
                                Restore Disk image of 2015-09-24-raspian-jessie.img
                                Properly eject SD card and insert in Pi
                                start Pi and login as Pi using ssh included with Jessie image
                                Reboot
                                Expand file system using GUI
                                Reboot
                                Login as Pi
                                add homeseer to sudoers
                                require password for pi

                                sudo adduser homeseer

                                File: /etc/sudoers.tmp

                                #
                                # This file MUST be edited with the 'visudo' command as root.
                                #
                                # Please consider adding local content in /etc/sudoers.d/ instead of
                                # directly modifying this file.
                                #
                                # See the man page for details on how to write a sudoers file.
                                #
                                Defaults env_reset
                                Defaults mail_badpass
                                Defaults secure_path="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"

                                # Host alias specification

                                # User alias specification

                                # Cmnd alias specification

                                # User privilege specification
                                root ALL=(ALL:ALL) ALL
                                homeseer ALL=(ALL:ALL) ALL

                                # Allow members of group sudo to execute any command
                                %sudo ALL=(ALL:ALL) ALL

                                # See sudoers(5) for more information on "#include" directives:

                                #includedir /etc/sudoers.d
                                pi ALL=(ALL:ALL) ALL
                                homeseer ALL=(ALL:ALL) ALL



                                root@raspberrypi:/home/pi#

                                homeseer@raspberrypi /home/pi $

                                pi@raspberrypi ~ $
                                Last edited by JohnD; October 29, 2015, 07:52 AM. Reason: typo

                                Comment

                                Working...
                                X