Arduino
Heltec Cubecell HTCC AB01 Arduino Guide
Introduction to Guide
Before we begin, please make sure you've followed the steps from this guide, which goes over some initial setup steps.
Objective and Requirements
In this guide, you will learn:
- How to setup your environment
- How to program a basic application that will send packets over the Helium Network
- Verify real-time packets sent to the Helium Console via Hotspot that's in range
For this example, you will need the following:
Hardware
- Heltec CubeCell Board
- Micro USB Type B Cable - Example
Software
Hardware Setup
Adding the Antenna
Your board should have come with a U.FL antenna. All you have to do is attached it to the U.FL port as shown in the image at the top of the guide.
Connect Board
Next, let's connect our board to our computer with a USB 2.0 A-Male to Micro B cable.
Software Setup
Getting the Arduino IDE
Download and install the latest version of Arduino IDE for your preferred OS.
Arduino Board Support
The Heltec CubeCell Board requires one Arduino board support package. Follow the instructions below to install.
CubeCell Dev-boards
To install, open your Arduino IDE:
- Navigate to (File > Preferences), (Arduino > Preferences) on MacOS.
- Find the section at the bottom called Additional Boards Manager URLs:
- Add this URL in the text box:
http://resource.heltec.cn/download/package_CubeCell_index.json
- Close the Preferences windows
Next, to install this board support package:
- Navigate to (Tools > Boards > Boards Manager...)
- Search for CubeCell Dev-boards
- Select the newest version and click Install
Manual updates to the Heltec runtime libraries
Some versions of Heltec's runtime libraries have set default configuration variables to values that are incompatible with the Helium network, especially when the Heltec device is configured targeting the North American market.
The following discusses two Heltec runtime files that must be inspected to ensure compatibility. The exact location of these files will depend on which operating system you are using, Windows, Linux, or Mac as well as where the Arduino IDE is installed.
The typical top-level locations of the runtime libraries is shown below for each operating system. From there the following discussions will present to you the file locations within these top-level directories/folders. Please note the Heltec library version numbers are expected to change as time goes on.
XXXXX denotes your specfic user id.
Arduino IDE library location
- Windows
C:\Users\XXXX\AppData\Local\Arduino15\packages\CubeCell\hardware\CubeCell\1.0.0
- Linux
/home/XXXXX/.arduino15/packages/CubeCell/hardware/CubeCell/1.0.0
- Mac
/Users/XXXXX/Library/Arduino15/packages/CubeCell/hardware/CubeCell/1.0.0