Background 


This guide assumes you have a working Raspberry Pi setup with SSH access available (or with keyboard and monitor).


NOTE: do NOT enable 1-wire in raspi-config -- the default 1-wire pin (GPIO 4) conflicts with OSPi and will prevent RPi from sending signals correctly to OSPi. If you must use 1-wire, you can follow RPi instructions to assign a different pin for 1-wire.


Table of Contents

A. New Installation of the Unified firmware on a Raspberry Pi


B. Upgrade a previously installed Unified firmware


C. Stop all sprinkler firmware/software from starting with the Raspberry Pi

A. New Installation of the Unified firmware on a Raspberry Pi


  1. Open an SSH connection to the Raspberry Pi (or use a keyboard and monitor connected to Raspberry Pi)

  2. Run the following command:
    sudo apt-get install build-essential
    cd ~
    git clone https://github.com/OpenSprinkler/OpenSprinkler-Firmware.git

  3. Change the directory to the firmware folder:
    cd OpenSprinkler-Firmware

  4. Build OpenSprinkler:
    sudo ./build.sh ospi
    • This will generate an executable program called OpenSprinkler in the firmware folder, and also set up startup script for auto-run at startup.
    • If you are using a BeagleBone Black, please replace ospi with osbo.
  5. If you answered yes to the startup script, you should be completely setup and ready to go.

  6. NOTE: it has come to our attention that some Raspbian systems installed by NOOBs will take over GPIO 4 for 1-wire interface, but that OSPi needs GPIO 4 to send control signals to the solenoid valves. If you found that the firmware runs correctly but OSPi does not turn on valves correctly, one solution is to sudo open /etc/modules, and comment out the line containing w1-gpio, then reboot. Another solution is to reinstall Raspbian OS from scratch without using NOOBs.

  7. The web interface should now be accessible from: http://localhost:8080. The default password to log into the web interface is opendoor.

   

B. Update a previously installed Unified Firmware


Warning: The firmware update process will set your controller back to factory defaults. This includes controller settings, program settings, and device password (which will be set back to the factory default of opendoor). Please ensure you back up your current configurations (e.g. Export Configurations) before proceeding with firmware update.    


  1. Open an SSH connection to your Raspberry Pi

  2. Change directory to your firmware folder, by default, it is:
    cd /home/pi/OpenSprinkler-Firmware
    

  3. Update OpenSprinkler firmware source code from github:
    git pull

  4. Re-build OpenSprinkler:
    sudo ./build.sh ospi
    • If you are using a BeagleBone Black, please replace ospi with osbo.

  5. Restart OpenSprinkler:
    sudo /etc/init.d/OpenSprinkler.sh restart

    If the above line doesn't work, try the following instead:
    sudo systemctl restart OpenSprinkler.service

 

C. Stop all sprinkler firmware/software from starting with the Raspberry Pi

  1. Open an SSH connection to your Raspberry Pi

  2. Remove Unified firmware from system startup: 
    1
    2
    3
    sudo /etc/init.d/OpenSprinkler.sh stop
    sudo rm /etc/init.d/OpenSprinkler.sh
    sudo update-rc.d OpenSprinkler.sh remove

  3. Remove Dan's Python OSPi program:  
    1
    2
    3
    sudo /etc/init.d/ospi stop
    sudo rm /etc/init.d/ospi
    sudo update-rc.d ospi remove

  4. Remove Richard Zimmerman's sprinkler_pi program:   
    1
    2
    3
    sudo /etc/init.d/sprinklers_pi stop
    sudo rm /etc/init.d/sprinklers_pi
    sudo update-rc.d sprinklers_pi remove