Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Table of Contents

Installation and Setup

To install in Arduino (required for initial install only and currently must be performed on the internal network at the office):

  1. Download Arduino (NOT 2.x, This latest version has not yet been confirmed to work with Gumband HDK)

  2. Open Arduino

  3. Navigate to File > Preferences (or Arduino > Preferences on MacOS)

  4. Under Additional Boards Manager URLs add https://bitbucket.org/deeplocal/gumband_arduino_public/raw/main/package_gumband_index.json

  5. Navigate to Tools > Boards > Boards Manager

  6. Find and install package “Gumband Hardware”

    Image of the board manager

  7. Under Tools > Boards you should now see "Gumband Boards", where you can select “Gumband Hardware”

    Image of Gumband Hardware selected in the boards menu

Programming the Hardware

 Each hardware device runs 2 programs: 

...

Info

Having trouble programming?

To manually enter the bootloader, reboot the device while holding the user button (useful if the upload fails or a sketch bricks the device). A reboot can be achieved by manually power cycling or pressing the reset button.

...

Configuring the Hardware

Talking to the Device

New devices need to be configured for the Gumband SDK. This can be done over the USB serial interface.

...

Info

You can send help to see a full list of commands, or see Serial Configuration Interface | Commands

Creating Credentials

To create credentials for the new device, you’ll need to login to app.gumband.com. Follow the steps outlined here or in Hardware UI | Create new Hardware

...

Info

See Gumband LED Status for a list of all status LED colors.

...

Tips for Use

  • Gumband only checks for callbacks once at the end of every iteration of the loop() function. In general, it's a bad idea to use delays within this loop() function because it inhibits the system from checking callbacks constantly.

  • When reading data from a callback function, you need to cast the incoming data to get it in a usable form. This allows you to more easily use the data more than once if necessary. The type you cast it to should match the type of data of the peripheral.

    • Ex: Use int32_t* dat = (int32_t*)data for the gmbnd_int32 type

  • Peripheral/Property names can only be 15 characters, anything longer will be truncated.

  • The on-board LED and button work with digitalWrite() functions using the LED_BUILTIN and BUTTON_BUILTIN pin assignments. However, you can also use the custom gumbandLed() On/Off/Toggle/SetBrightness and gumbandButtonPressed() functions within the Gumband API.

  • The on-board button does not need to be initialized with pinMode(); it will work automatically. It will not work properly if reconfigured to INPUT_PULLUP or INPUT_PULLDOWN.

  • Initializing pins with pinMode() is not necessary for most I/O. They will be initialized automatically when calling digital/analog read/write. To configure pullup/pulldown resistors, pinMode() is necessary, however.

...

Command Line Utilities

The Arduino package include an upload utility that communicates with the bootloader and can be executed directly from the command line. The gumband_loader tool is located in tools>gumband_utils directory of the installed package (typically AppData\Local\Arduino15\packages\gumband_arduino for pre 2.0 Arduino IDE under Windows).

...