Pebble Foundation Classes
0.2.0
C++ for Pebble
|
This Pebble Package gives you the ability to code Pebble watchapps using C++. It wraps the Pebble API in an low-overhead header-only object-oriented library.
The reasonable man adapts himself to the world; the unreasonable one persists in trying to adapt the world to himself. Therefore, all progress depends on the unreasonable man.
- George Bernard Shaw
I mostly work in high-level languages like C#, Java, Python, and C++ and I started to struggle with organizing my Pebble watchapp code in C. As my projects grew larger, it became harder to juggle all the structs, callback contexts, and especially global variables.
So in the fall of 2014 I started a project to bring C++ to Pebble development. There were many false starts and difficult problems. I eventually got to where all the big problems were resolved and I just needed to build out the library. But after Pebble closed it's doors I stopped working on it.
When the first Rebble Hackathon was announced, it seemed like the time to try and finish this project or at least release what I have to the world.
std::string
, std::vector
, and std::unique_ptr
for more high-level development.To get started, please check out the following pages:
They provide detailed information about configuring the project to build C++ files and how to structure your code.
Since the Pebble Foundation Classes is fully compatible with and uses many of the base Pebble C types, this documentation is a combination of the standard Pebble SDK documentation and the additional PFC classes. The PFC classes are all contained within the Pebble namespace.
Use the tree on the left to navigate the modules and class documentation.
You can view and download various sample projects from the site below:
You can get help with this SDK using the GitHub Project Issues Tab or by using the Rebble Alliance Discord.
Also please check out the Known Issues page.
View the Pebble Foundation Classes GitHub project for information on contributing.