Home Using the Apple Watch as a PHL Interface
Post
Cancel

Using the Apple Watch as a PHL Interface

It’s possible to connect an Apple watch to the PHL and then control parameters using the watch screen. The connection is via WiFi and it takes a few slightly inconvenient work arounds, but it is possible to replace the phone or computer with this smaller interface device.

Apple Watch browser

When using the Node Red interface from a computer or phone the GUI is accessed by opening a browser and pointing it to the address ‘http://10.0.0.1:1880/ui’. The watch uses the same method, but this is difficult to do because the Apple Watch doesn’t come with a web browser and even if you install one, typing anything on the watch is tedious and error prone.

One of the easiest ways to get around this is to email yourself the link, ‘http://10.0.0.1:1880/ui’. Reading the email from the watch then selecting the link will launch a browser and you’ll be taken to the interface.

New Node Red interface

Once you’ve connected, the current standard GUI will run on the watch but the small screen makes it difficult to use. The basic steps to generate a new Node Red interface are as follows:

  • In the directory /etc/mahalia/nodered, delete the file openMHAcontrol.flow
  • Restart PHL, (or restart mahalia-nodered service).
  • Connect host computer to PHL via WiFi
  • Open link ‘http://10.0.0.1:1880’
  • Use the Node Red GUI to add your own controls
  • Connect the watch to the PHL via WiFi and open the link (described above) to your new GUI

The details of designing a Node Red interface will be reviewed in another post, but a good way to learn is by examining the existing interfaces that come with the PHL. Run a configuration, then connect to ‘http://10.0.0.1:1880’ to see the controls.

Example screen

The dummy screen shown here consists of 2 large buttons and a slider along the bottom edge. The buttons here are size 3x3 on the Node Red layout grid. The slider is functional but feels small and not that easy to use. The screen size is maximized by removing some tab labels and titles (In ‘dashboard’, Site->Options-> Hide the title bar). The Node Red framework provides a lot of flexibility for developing useful minimal interfaces within the constraints imposed by the small screen.

This post is licensed under CC BY 4.0 by the author.
Trending Tags