Installation & usage guide:

1. Download & Install MyPi Server.

2. Run & test MyPi Server.

3. Load MyPi Server on boot.

4. Server Settings & GPIO configuration.

5. Watch MyPi Demo on YouTube.

6. Watch this Tutorial on YouTube.

7. Relays and switches connection diagram.

Download & Install MyPi TCP Server:

  1. Open Termial or connect to your Raspberry Pi by ssh.
  2. Change the current directory to /home/pi by typing:

    cd /home/pi

  3. Download MyPi TCP Server by typing:

    wget www.ioslinks.com/mypi/server.zip

  4. Unzip the package by typing:

    unzip server.zip

Run & test MyPi Server:

  1. Start MyPi Server by typing:

    python3 mypi_server.pyc

  2. Launch MyPi iOS App and click the gear icon.
  3. Replace IP with your Raspberry Pi IP Address.
  4. Click Save and from the main screen click Connect.
  5. Tap any button to chage GPIO status.

Load MyPi Server on boot:

  1. Stop MyPi Server by pressing CTRL C twice.
  2. Edit rc.local file by typing:

    sudo nano /etc/rc.local

  3. Scroll down and type the following command BEFORE the exit 0 line:

    python3 /home/pi/mypi_server.pyc &

  4. Save changes by pressing CTRL O and ENTER.
  5. Quit by pressing CTRL X.
  6. Reboot your Raspberry Pi by typing:

    sudo reboot

Server Settings & GPIO configuration:

    MyPi Default configuration:
  1. TCP Port : 5000
  2. Connection Password : 123456
  3. Initial output level : 1
  4. Output pins : 7,11,13,15,16,18,19,21
  5. Input pins : 29,31,32,33,36,37,23,24
  6. Output modes : T = Toggle , M = Momentary.
  7. Delay : 1.0 (in seconds, applys only when output mode is momentary).
    You can chage the default configuration by performing the following steps:
  1. Open Termial or connect to your Raspberry Pi by ssh.
  2. Edit mypi.cfg file by typing:

    sudo nano /home/pi/mypi.cfg

  3. You can change the default Port and Password, initial GPIO output level, You can also change the physical pin number for each Input or Output list.
  4. If you change the default Port or Password make sure to update the iOS App as well.
  5. Save changes by pressing CTRL O and ENTER.
  6. Quit by pressing CTRL X.
  7. Reboot your Raspberry Pi by typing:

    sudo reboot

MyPi demo:

MyPi Server installation guide:

Relays and switches connection diagram.

  1. Connect your relays to the output pins : 7,11,13,15,16,18,19,21
  2. Connect your switches to the input pins : 29,31,32,33,36,37,23,24