PULSEv2 Reliable Transport
==========================

The purpose of this document is to describe the procedures for the PULSEv2
reliable transport (TRAIN) to be used in the initial implementations, with
support for only Stop-and-Wait ARQ (Automatic Repeat reQuest). Hopefully,
limiting the scope in this way will make it simpler to implement compared to a
more performant Go-Back-N ARQ. This document is a supplement to the description
of TRAIN in [pulse2.md](pulse2.md).

The PULSEv2 reliable transport (TRAIN) is based on X.25 LAPB, which implements
reliable datagram delivery using a Go-Back-N ARQ (Automatic Repeat reQuest)
procedure. Since a Stop-and-Wait ARQ is equivalent to Go-Back-N with a window
size of 1, LAPB can be readily adapted for Stop-and-Wait ARQ. The description in
this document should hopefully be compatible with an implementation supporting
the full Go-Back-N LAPB procedures when that implementation is configured with a
window size of 1, so that there is a smooth upgrade path which doesn't require
special cases or compatibility breakages.

Documentation conventions
-------------------------

This document relies heavily on the terminology used in [ITU-T Recommendation
X.25](https://www.itu.int/rec/T-REC-X.25-199610-I/en). Readers are also assumed
to have some familiarity with section 2 of that document.

The term "station" is used in this document to mean "DCE or DTE".

Procedures for information transfer
-----------------------------------

There is no support for communicating a busy condition. It is assumed that a
station in a busy condition will silently drop packets, and that the timer
recovery procedure will be sufficient to ensure reliable delivery of the dropped
packets once the busy condition is cleared. An implementation need not support
sending or receiving RNR packets.

Sending I packets
-----------------

All Information transfer packets must be sent with the Poll bit set to 1. The
procedures from X.25 §2.4.5.1 apply otherwise.

Receiving an I packet
---------------------

When the DCE receives a valid I packet whose send sequence number N(S) is equal
to the DCE receive state variable V(R), the DCE will accept the information
fields of this packet, increment by one its receive state variable V(R), and
transmit an RR response packet with N(R) equal to the value of the DCE receive
state variable V(R). If the received I packet has the Poll bit set to 1, the
transmitted RR packet must be a response packet with Final bit set to 1.
Otherwise the transmitted RR packet should have the Final bit set to 0.

Reception of out-of-sequence I packets
--------------------------------------

Since the DTE should not have more than one packet in-flight at once, an
out-of-sequence I packet would be due to a retransmit: RR response for the most
recently received I packet got lost, so the DTE re-sent the I packet. Discard
the information fields of the packet and send an RR packet with N(R)=V(R).

Receiving acknowledgement
-------------------------

When correctly receiving a RR packet, the DCE will consider this packet as an
acknowledgement of the most recently-sent I packet if N(S) of the most
recently-sent I packet is equal to the received N(R)-1. The DCE will stop timer
T1 when it correctly receives an acknowledgement of the most recently-sent I
packet.

Since all I packets are sent with P=1, the receiving station is obligated to
respond with a supervisory packet. Therefore it is unnecessary to support
acknowledgements embedded in I packets.

Receiving an REJ packet
-----------------------

Since only one I packet may be in-flight at once, the REJ packet is due to the
RR acknowledgement from the DTE getting lost and the DCE retransmitting the I
packet. Treat it like an RR.

Waiting acknowledgement
-----------------------

The DCE maintains an internal transmission attempt variable which is set to 0
when the transport NCP signals a This-Layer-Up event, and when the DCE correctly
receives an acknowledgement of a sent I packet.

If Timer T1 runs out waiting for the acknowledgement from the DTE for an I
packet transmitted, the DCE will add one to its transmission attempt variable,
restart Timer T1 and retransmit the unacknowledged I packet.

If the transmission attempt variable is equal to N2 (a system parameter), the
DCE will initiate a restart of the transport link.


# pblprog
Utility for flashing Pebble BigBoards over SWD

Installation
------------

Install from PyPi (https://pebbletechnology.atlassian.net/wiki/display/DEV/pypi) under the package name `pebble.programmer`.

Supported devices
-----------------

It is relatively easy to add support for any STM32/SWD based Pebble BigBoard. Currently supported are:

- silk_bb
- robert_bb

This is the latest version of the internal repository from Pebble Technology providing the software to run on Pebble watches. Proprietary source code has been removed from this repository and it will not compile as-is. This is for information only.


# pyegg-pebble-loghash
A python egg for dealing with hashed TinTin logs


pebble.pulse2
=============

pulse2 is a Python implementation of the PULSEv2 protocol suite.

https://pebbletechnology.atlassian.net/wiki/display/DEV/PULSEv2+Protocol+Suite


# libOS

libOS is a helper library that makes developing software on top of FreeRTOS on ARM easier.
It is used by and built for the main FW and the Dialog Bluetooth FW.

## Dependencies:

- libc
- libutil
- FreeRTOS
- Availability of an <mcu.h> header file that includes the CMSIS headers (core_cmX.h,
  core_cmFunc.h, etc.)
- A handful of platform specific functions, see platform.c


Header Overrides for Unit Tests
===============================

Writing a test which requires overriding a header?
--------------------------------------------------

1. Create a new override tree with versions of the headers you want to
   override.  Only the header files you add to this tree will shadow
   default override headers and source-tree headers.
2. Create header files in subdirectories under this override tree so
   that the relative paths to the override headers mirrors that of the
   source tree. For example, if the header you want to override is
   included by

   ```c
   #include "applib/ui/ui.h"
   ```

   then the override file should be placed in
   `tests/overrides/my_override/applib/ui/ui.h`
3. Specify the override tree in your test's build rule.

   ```python
   clar(ctx, ..., override_includes=['my_override'])
   ```

Guidelines for writing an override header
-----------------------------------------

### Never include function prototypes in an override header. ###

It is too easy to change a function prototype in a firmware header but
forget to mirror that change in an override header. Tests could start
erroneously failing when there is nothing wrong with the code, or
(worse) tests could erroneously pass when the code contains errors.
Refactor the header so that the header itself contains function
prototypes and the inline function definitions are placed in a separate
`header.inl.h` file. At the bottom of the header file,

```c
#include "full/path/to/header.inl.h"
```

and provide an override header for just `header.inl.h`.


# Contribution Guidelines
## Patch Submission Process

The following guidelines on the submission process are provided to help you be more effective when submitting code to the JerryScript project.

When development is complete, a patch set should be submitted via GitHub pull requests. A review of the patch set will take place. When accepted, the patch set will be integrated into the master branch, verified, and tested. It is then the responsibility of the authoring developer to maintain the code throughout its lifecycle.

Please submit all patches in public by opening a pull request. Patches sent privately to Maintainers and Committers will not be considered. Because the JerryScript Project is an Open Source project, be prepared for feedback and criticism-it happens to everyone-. If asked to rework your code, be persistent and resubmit after making changes.

### 1. Scope the patch

Smaller patches are generally easier to understand and test, so please submit changes in the smallest increments possible, within reason. Smaller patches are less likely to have unintended consequences, and if they do, getting to the root cause is much easier for you and the Maintainers and Committers. Additionally, smaller patches are much more likely to be accepted.

### 2. Sign your work with the JerryScript [Developer's Certificate of Origin](DCO.md)

The sign-off is a simple line at the end of the commit message of the patch, which certifies that you wrote it or otherwise have the right to pass it on as an Open Source patch. The sign-off is required for a patch to be accepted. In addition, any code that you want to contribute to the project must be licensed under the [Apache License 2.0](LICENSE). Contributions under a different license can not be accepted.

We have the same requirements for using the signed-off-by process as the Linux kernel.
In short, you need to include a signed-off-by tag in every patch.

You should use your real name and email address in the format below:

> JerryScript-DCO-1.0-Signed-off-by: Random J Developer random@developer.example.org

"JerryScript-DCO-1.0-Signed-off-by:" this is a developer's certification that he or she has the right to submit the patch for inclusion into the project. It is an agreement to the JerryScript [Developer's Certificate of Origin](DCO.md). **Code without a proper signoff cannot be merged into the mainline.**

### 3. Open a GitHub [pull request](https://github.com/Samsung/jerryscript/pulls)

You can find instructions about opening a pull request [here](https://help.github.com/articles/creating-a-pull-request).

### 4. What if my patch is rejected?

It happens all the time, for many reasons, and not necessarily because the code is bad. Take the feedback, adapt your code, and try again. Remember, the ultimate goal is to preserve the quality of the code and maintain the focus of the Project through intensive review.

Maintainers and Committers typically have to process a lot of submissions, and the time for any individual response is generally limited. If the reason for rejection is unclear, please ask for more information from the Maintainers and Committers.
If you have a solid technical reason to disagree with feedback and you feel that reason has been overlooked, take the time to thoroughly explain it in your response.

### 5. Code review

Code review can be performed by all the members of the Project (not just Maintainers and Committers). Members can review code changes and share their opinion through comments guided by the following principles:
* Discuss code; never discuss the code's author
* Respect and acknowledge contributions, suggestions, and comments
* Listen and be open to all different opinions
* Help each other

Changes are submitted via pull requests and only the Maintainers and Committers should approve or reject the pull request (note that only Maintainers can give binding review scores).
Changes should be reviewed in reasonable amount of time. Maintainers and Committers should leave changes open for some time (at least 1 full business day) so others can offer feedback. Review times increase with the complexity of the review.

## Tips on GitHub Pull Requests

* [Fork](https://guides.github.com/activities/forking) the GitHub repository and clone it locally
* Connect your local repository to the original upstream repository by adding it as a remote
* Create a [branch](https://guides.github.com/introduction/flow) for your edits
* Pull in upstream changes often to stay up-to-date so that when you submit your pull request, merge conflicts will be less likely

For more details, see the GitHub [fork syncing](https://help.github.com/articles/syncing-a-fork) guidelines.

## How to add the DCO line to every single commit automatically

It is easy to forget adding the DCO line to the end of every commit message. Fortunately there is a nice way to do it automatically. Once you've cloned the repository into your local machine, you can add `prepare commit message hook` in `.git/hooks` directory like this:

```
#!/usr/bin/env python

import sys

commit_msg_filepath = sys.argv[1]

with open(commit_msg_filepath, "r+") as f:
	content = f.read()
	f.seek(0, 0)
	f.write("%s\n\nJerryScript-DCO-1.0-Signed-off-by: <Your Name> <Your Email>" % content)
```

Please refer [Git Hooks](http://git-scm.com/book/en/v2/Customizing-Git-Git-Hooks) for more information.


# JerryScript Developer's Certificate of Origin

The JerryScript project uses the signed-off-by language and process to give us a clear chain of trust for every patch received.

> By making a contribution to this project, I certify that:

> (a)	The contribution was created in whole or in part by me and I have the right to submit it under the open source license indicated in the file; or

> (b)	The contribution is based upon previous work that, to the best of my knowledge, is covered under an appropriate open source license and I have the right under that license to submit that work with modifications, whether created in whole or in part by me, under the same open source license (unless I am permitted to submit under a different license), as indicated in the file; or

> (c)	The contribution was provided directly to me by some other person who certified (a), (b) or (c) and I have not modified it.

> (d)	I understand and agree that this project and the contribution are public and that a record of the contribution (including all personal information I submit with it, including my sign-off) is maintained indefinitely and may be redistributed consistent with this project, under the same open source license.

We have the same requirements for using the signed-off-by process as the Linux kernel.
In short, you need to include a signed-off-by tag in the commit message of every patch.

You should use your real name and email address in the format below:

> JerryScript-DCO-1.0-Signed-off-by: Random J Developer random@developer.example.org

"JerryScript-DCO-1.0-Signed-off-by:" this is a developer's certification that he or she has the right to submit the patch for inclusion into the project. It is an agreement to the Developer's Certificate of Origin (above). **Code without a proper signoff cannot be merged into the mainline.**


![](https://github.com/Samsung/jerryscript/blob/master/LOGO.png)
# JerryScript: JavaScript engine for the Internet of Things
[![License](https://img.shields.io/badge/licence-Apache%202.0-brightgreen.svg?style=flat)](LICENSE)
[![Build Status](https://travis-ci.org/Samsung/jerryscript.svg?branch=master)](https://travis-ci.org/Samsung/jerryscript)

JerryScript is a lightweight JavaScript engine for resource-constrained devices such as microcontrollers. It can run on devices with less than 64 KB of RAM and less than 200 KB of flash memory.

Key characteristics of JerryScript:
* Full ECMAScript 5.1 standard compliance
* 160K binary size when compiled for ARM Thumb-2
* Heavily optimized for low memory consumption
* Written in C99 for maximum portability
* Snapshot support for precompiling JavaScript source code to byte code
* Mature C API, easy to embed in applications

Additional information can be found on our [project page](http://jerryscript.net) and [Wiki](https://github.com/Samsung/jerryscript/wiki).

IRC channel: #jerryscript on [freenode](https://freenode.net)
Mailing list: jerryscript-dev@gna.org, you can subscribe [here](https://mail.gna.org/listinfo/jerryscript-dev) and access the mailing list archive [here](https://mail.gna.org/public/jerryscript-dev).

## Quick Start
### Getting the sources
```bash
git clone https://github.com/Samsung/jerryscript.git
cd jerryscript
```

### Building JerryScript
```bash
python tools/build.py
```

For additional information see [Getting Started](docs/01.GETTING-STARTED.md).

## Documentation
- [Getting Started](docs/01.GETTING-STARTED.md)
- [API Reference](docs/02.API-REFERENCE.md)
- [API Example](docs/03.API-EXAMPLE.md)
- [Internals](docs/04.INTERNALS.md)

## Contributing
The project can only accept contributions which are licensed under the [Apache License 2.0](LICENSE) and are signed according to the JerryScript [Developer's Certificate of Origin](DCO.md). For further information please see our [Contribution Guidelines](CONTRIBUTING.md).

## License
JerryScript is Open Source software under the [Apache License 2.0](LICENSE). Complete license and copyright information can be found in the source code.

> Copyright 2015 Samsung Electronics Co., Ltd.

> Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.


Contributing to Nanopb development
==================================

Reporting issues and requesting features
----------------------------------------

Feel free to report any issues you see or features you would like
to see in the future to the Github issue tracker. Using the templates
below is preferred:

* [Report a bug](https://github.com/nanopb/nanopb/issues/new?body=**Steps%20to%20reproduce%20the%20issue**%0a%0a1.%0a2.%0a3.%0a%0a**What%20happens?**%0A%0A**What%20should%20happen?**&labels=Type-Defect)
* [Request a feature](https://github.com/nanopb/nanopb/issues/new?body=**What%20should%20the%20feature%20do?**%0A%0A**In%20what%20situation%20would%20the%20feature%20be%20useful?**&labels=Type-Enhancement)

Requesting help
---------------

If there is something strange going on, but you do not know if
it is actually a bug in nanopb, try asking first on the
[discussion forum](https://groups.google.com/forum/#!forum/nanopb).

Pull requests
-------------

Pull requests are welcome!

If it is not obvious from the commit message, please indicate the
same information as you would for an issue report:

* What functionality it fixes/adds.
* How can the problem be reproduced / when would the feature be useful.


Nanopb - Protocol Buffers for Embedded Systems
==============================================

![Latest change](https://github.com/nanopb/nanopb/actions/workflows/trigger_on_code_change.yml/badge.svg)
![Weekly build](https://github.com/nanopb/nanopb/actions/workflows/trigger_on_schedule.yml/badge.svg)

Nanopb is a small code-size Protocol Buffers implementation in ansi C. It is
especially suitable for use in microcontrollers, but fits any memory
restricted system.

* **Homepage:** https://jpa.kapsi.fi/nanopb/
* **Git repository:** https://github.com/nanopb/nanopb/
* **Documentation:** https://jpa.kapsi.fi/nanopb/docs/
* **Forum:** https://groups.google.com/forum/#!forum/nanopb
* **Stable version downloads:** https://jpa.kapsi.fi/nanopb/download/
* **Pre-release binary packages:** https://github.com/nanopb/nanopb/actions/workflows/binary_packages.yml

Using the nanopb library
------------------------
To use the nanopb library, you need to do two things:

1. Compile your .proto files for nanopb, using `protoc`.
2. Include *pb_encode.c*, *pb_decode.c* and *pb_common.c* in your project.

The easiest way to get started is to study the project in "examples/simple".
It contains a Makefile, which should work directly under most Linux systems.
However, for any other kind of build system, see the manual steps in
README.txt in that folder.

Generating the headers
----------------------
Protocol Buffers messages are defined in a `.proto` file, which follows a standard
format that is compatible with all Protocol Buffers libraries. To use it with nanopb,
you need to generate `.pb.c` and `.pb.h` files from it:

    python generator/nanopb_generator.py myprotocol.proto  # For source checkout
    generator-bin/nanopb_generator myprotocol.proto        # For binary package

(Note: For instructions for nanopb-0.3.9.x and older, see the documentation
of that particular version [here](https://github.com/nanopb/nanopb/blob/maintenance_0.3/README.md))

The binary packages for Windows, Linux and Mac OS X should contain all necessary
dependencies, including Python, python-protobuf library and protoc. If you are
using a git checkout or a plain source distribution, you will need to install
Python separately. Once you have Python, you can install the other dependencies
with `pip install --upgrade protobuf grpcio-tools`.

You can further customize the header generation by creating an `.options` file.
See [documentation](https://jpa.kapsi.fi/nanopb/docs/concepts.html#modifying-generator-behaviour) for details.

Running the tests
-----------------
If you want to perform further development of the nanopb core, or to verify
its functionality using your compiler and platform, you'll want to run the
test suite. The build rules for the test suite are implemented using Scons,
so you need to have that installed (ex: `sudo apt install scons` or `pip install scons`).
To run the tests:

    cd tests
    scons

This will show the progress of various test cases. If the output does not
end in an error, the test cases were successful.

Note: Mac OS X by default aliases 'clang' as 'gcc', while not actually
supporting the same command line options as gcc does. To run tests on
Mac OS X, use: `scons CC=clang CXX=clang`. Same way can be used to run
tests with different compilers on any platform.

For embedded platforms, there is currently support for running the tests
on STM32 discovery board and [simavr](https://github.com/buserror/simavr)
AVR simulator. Use `scons PLATFORM=STM32` and `scons PLATFORM=AVR` to run
these tests.

Build systems and integration
-----------------------------
Nanopb C code itself is designed to be portable and easy to build
on any platform. Often the bigger hurdle is running the generator which
takes in the `.proto` files and outputs `.pb.c` definitions.

There exist build rules for several systems:

* **Makefiles**: `extra/nanopb.mk`, see `examples/simple`
* **CMake**: `extra/FindNanopb.cmake`, see `examples/cmake`
* **SCons**: `tests/site_scons` (generator only)
* **Bazel**: `BUILD` in source root
* **Conan**: `conanfile.py` in source root
* **PlatformIO**: https://platformio.org/lib/show/431/Nanopb
* **PyPI/pip**: https://pypi.org/project/nanopb/
* **vcpkg**: https://vcpkg.info/port/nanopb

And also integration to platform interfaces:

* **Arduino**: http://platformio.org/lib/show/1385/nanopb-arduino


TimeShift.js
============

TimeShift.js allows mocking / overriding JavaScript's Date object so that you can set the current time and timezone.  It is meant for creating repeatable tests that utilize the current time or date.

Usage
-----

```javascript
new Date().toString();                      // Original Date object
"Fri Aug 09 2013 23:37:42 GMT+0300 (EEST)"

Date = TimeShift.Date;                      // Overwrite Date object
new Date().toString();
"Fri Aug 09 2013 23:37:43 GMT+0300"

TimeShift.setTimezoneOffset(-60);           // Set timezone to GMT+0100 (note the sign)
new Date().toString();
"Fri Aug 09 2013 21:37:44 GMT+0100"

TimeShift.setTime(1328230923000);           // Set the time to 2012-02-03 01:02:03 GMT
new Date().toString();
"Fri Feb 03 2012 02:02:03 GMT+0100"

TimeShift.setTimezoneOffset(0);             // Set timezone to GMT
new Date().toString();
"Fri Feb 03 2012 01:02:03 GMT"

TimeShift.getTime();                        // Get overridden values
1328230923000
TimeShift.getTimezoneOffset();
0

TimeShift.setTime(undefined);               // Reset to current time
new Date().toString();
"Fri Aug 09 2013 20:37:45 GMT"

new Date().desc();                          // Helper method
"utc=Fri, 09 Aug 2013 20:37:46 GMT   local=Fri, 09 Aug 2013 20:37:46 GMT   offset=0"

new TimeShift.OriginalDate().toString();    // Use original Date object
"Fri Aug 09 2013 23:37:47 GMT+0300 (EEST)"
```

Time zones
----------

TimeShift.js always utilizes its internal time zone offset when converting between local time and UTC.  The offset factor is fixed, and it does not take into account DST changes.  Effectively it emulates a time zone with no DST.

```javascript
new Date(1370034000000).toString();         // Original Date object uses variable offset
"Sat Jun 01 2013 00:00:00 GMT+0300 (EEST)"
new Date(1356991200000).toString();
"Tue Jan 01 2013 00:00:00 GMT+0200 (EET)"

Date = TimeShift.Date;                      // TimeShift.js uses fixed offset
new Date(1370034000000).toString();
"Sat Jun 01 2013 00:00:00 GMT+0300"
new Date(1356991200000).toString();
"Tue Jan 01 2013 01:00:00 GMT+0300"
```

The default time zone offset is the current local time zone offset.  Note that this can change depending on local DST.  Setting the time zone offset affects also previously created Date instances.

The time zone offset has the same sign as [Date.getTimezoneOffset](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/getTimezoneOffset).  For example, -120 is GMT+0200 and +120 is GMT-0200.

Caveats
-------

The mock implementation of Date is not perfect.

* Many string-generation methods are incomplete and return something indicative, but not fully correct.  In particular `toDateString`, `toLocaleDateString`, `toLocaleString`, `toLocaleTimeString`, `toTimeString` produce somewhat incorrect results.

* The `toString` method does not contain any time zone name.

* The `parse` method delegates directly to the original method and may not handle time zones correctly.

* DST changes cannot be emulated.  The time zone offset it always fixed.

* If a library or other code holds an original Date object or a reference to the Date prototype, things may break (e.g. error messages like "this is not a Date object").  In this case you should overwrite the Date object before loading the library.

If you'd like to fix some of these issues, please fork the repository, implement the desired functionality, add unit tests to `tests.js` and send a pull request.

License
-------

TimeShift.js is Copyright 2013 Mobile Wellness Solutions MWS Ltd and Sampo Niskanen.

It is released under the MIT license.


Pebble Font Renderer Script
===========================

These Python scripts take TrueType font files, renders a set of glyps and outputs them into .h files in the appropriate structure for consumption by Pebble's text rendering routines.

Requirements:
-------------
* freetype library
* freetype-py binding

http://code.google.com/p/freetype-py/

**Mac OS X and freetype-py**: the freetype binding works with the Freetype library that ships with Mac OS X (/usr/X11/lib/libfreetype.dylib), but you need to patch setup.py using this diff file:

https://gist.github.com/3345193


# Tintin Native SDK Generator
This script exports white-listed functions, `typedef`s and `#define`s in tintin source tree so that they can be used by native-watch apps.

>
> ### Note:
>
> It is *not* possible to add additional publicly exposed functions to
> an already released firmware/SDK combination.
>
> This is because the generated `src/fw/pebble.auto.c` file needs
> to have been compiled into the firmware with which the SDK will be
> used.
>
> If you just expose a new function in `exported_symbols.json`,
> generate a new SDK and compile an app that uses the new function
> then the watch will crash when that code is executed on a firmware
> without that function exposed.
>
> You will need to generate and release a new firmware alongside the
> new SDK build that has the newly exposed function.
>

The script generates 3 files required to build native watchapps:
+ `sdk/include/pebble.h` -- Header file containing the typedefs, defines and function prototypes for normal apps
+ `sdk/include/pebble_worker.h` -- Header file containing the typedefs, defines and function prototypes for workers
+ `sdk/lib/pebble.a` -- Static library containing trampolines to call the exported functions in Flash.
+ `src/fw/pebble.auto.c` -- C file containing `g_pbl_system_table`, a table of function pointers used by the trampolines to find an exported function's address in Flash.

## Running the generator
The running of the generator has now been integrated into the build, so there is no need to run it separately.

If for whatever reason, you need to run the generator by hand, run `% tools/generate_native_sdk/generate_pebble_native_sdk_files.py --help`, and it's simple enough to follow.

## Configuration
The symbols exported by the SDK generator are defined in the `exported_symbols.json` config file.

The format of the config file is as follows:

    [
        {
            "revision" : "<exported symbols revision number>",
            "version" : "x.x",
            "files" : [
                <Files to parse/search>
             ],
            "exports" : [
                <Symbols to export>
            ]
        }
    ]

Each exported symbol in the `exports` table is formatted as follows:

    {
        "type" : "<Export type",
        "name" : "<Symbol name>",
        "sortName" : "<sort order>",
        "addedRevision" : "<Revision number>"
    }

`Export type` type can be any of `function`, `define`, `type`, or `group`. A `group` type has the following structure:

    {
        "type : "group",
        "name" : "<Group Name>",
        "exports" : [
          <Symbols to export>
        ]
    }

*NB:* The generator sorts the order of the `functions` in order of addedRevision, and then alphabetically within a revision using sortName (if specified) or name. The `types` fields are left in the order in which they are entered in the types table. As well, Be sure to specify any typedefs with dependencies on other typedefs after their dependencies in the `types` list.

### Important!
When adding new functions, make sure to bump up the `revision` field, and use that value as the new functions' `addedRevision` field. This guarantees that new versions of TintinOS are backwards compatible when compiled against older `libpebble.a`. Seriously, ***make sure to do this***!!.

## Bugs
+ The script doesn't check the the resulting `pebble.h` file will compile, that is left as an exercise to the reader.
+ The script's error reporting is a little funky/unfriendly in places
+ The script does not do any checking of the function revision numbers, beyond a simple check that the file's revision is not lower than any function's.


Resource Generation
===================

The old resource code was crazy and slow. Let's redesign everything!

Design Goals
------------
1. Decouple processing different types of resources from each other into their own files
2. Be completely SDK vs Firmware independent. Any differences in behaviour between the two resource
   generation variants should be captured in parameters as opposed to explicitly checking which
   one we are.
3. No more shelling out
4. Capture as much intermediate state in the filesystem itself as possible as opposed to
   generating large data structures that need to be done on each build.
5. Remove the need to put dynamically generated resource content like the bluetooth patch and
   stored apps into our static resource definition json files for more modularity.


---
# Copyright 2025 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
#     http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

permalink: /feed.xml
title: Pebble SDK 2.0 BETA0 - Changelog
date: 2013-11-01
---

This version is a preview of what will be publicly released soon as a BETA. This means that it is the last time we introduce large changes to the APIs, they will be much more stable in the future.

It includes some last significant changes that will impact every application.

 * We have changed the format of the `wscript` file. **You must update your wscript file.** The easiest way to do this is to generate a new project with `pebble new-project` and use the generated `wscript`.
 * Header files `pebble_os.h`, `pebble_app.h` and `pebble_fonts.h` are replaced by `pebble.h`
 * `click_config_provider()` signature has changed and instead of filling a struct, you call `window_*_click_subscribe`. Please refer to the [Migration Guide](/guides/migration/).
 * On AppMessage:
   * We have changed the signature of most AppMessage functions. Please refer to the [Migration Guide](/guides/migration/).
   * We have added functions to query the size of the AppMessage buffers. They still return the same value that in previous versions ... for now.
 * We have added a [Mobile Developer Guide](/guides/communication/) covering PebbleKit iOS and Android. Please take a look at them, they should answer lots of questions.
 * [PebbleKit Android Documentation](/guides/communication/using-pebblekit-android) is now available on the website and in the SDK `Documentation` folder.
 * We have done a lot of work on PebbleKit JavaScript:
   * The [documentation](/guides/communication/using-pebblekit-js) describes the new model for loading and stopping JavaScript apps. You should take a look.
   * On Android only (for now) apps will automatically start when they get a message from Pebble.
   * On Android only (for now) you can use the gear icon to open a configuration window on the phone.
   * You can now call `Pebble.addEventListener` instead of `PebbleEventListener.addEventListener`
 * DataLogging is now supported on Android, iOS6 and iOS7

 * And of course we have fixed a large quantities of bugs.

This is a private release under NDA.


---
# Copyright 2025 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
#     http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

title: Pebble SDK 2.0 BETA1 - Changelog
date: 2013-11-06
---

 * Pebble SDK 2.0 is currently in BETA and intended for developers only.
 * SDK 2.0 will be released later this year as an over-the-air update to all Pebble users.
 * Applications written for Pebble 1.x are not compatible with SDK 2.0
 * ANCS Notifications (aka BLE notifications) are not supported for iOS users in this version

Updates:

 * 2013 11 07: Added a firmware for watch with serial number starting with a 'Q' (aka hardware 1.5)

## What has changed since BETA0

### User Bug Fixes and Feature Enhancements

 - Fixed crashing bugs on the iOS app. Users should experience improved stability.
 - New iOS users no longer need to manage access to their address book in order to see Caller ID on their Pebble.
 - The iOS app does not overflow the banner bar (at the top of the screen) on iOS7
 - The Pebble now can show >80 unread notifications, up from 8 previously.
 - Backlight is triggered on a tap from any of the 6 axes of the watch
 - Android app stability has been improved
 - On Android, switching orientation while updating firmware does not stop the firmware update
 - The music app now stays open rather than switching back to the menu after 1 minute

### Known User Issues

 - The status indication button in the main screen sometimes repeatedly throbs green then red, repeatedly.
 - (iOS7 users, iPhone4S and higher) If you select "Enable Notifications" and select the Cancel button in the system alert that comes up, it can take up to 30 seconds for the iOS app to allow selection of "Enable Notifications" again. As a workaround, if you launched this screen from the Status screen, you can hit the up arrow, then the red "Not receiving notifications" button, and retry enabling notifications again.
 - In certain conditions if you enable and disable Airplane mode on your Pebble, you may need to restart the Pebble iOS app completely in order to re-enable notifications again
 - On Android, you may need to restart the Pebble app after installing a new version of a JavaScript app to ensure that your changes are successfully loaded.
 - On Android, use of HTML5 local storage does not guarantee data will be saved across sessions.
 - Duplicate APP_LOG messages can be received while using the pebble tool; these are intermittent and developers should use timestamps to identify duplicates
 - If there is not enough app heap remaining, some essential functions that allocate on that heap will fail, such as system fonts or persistent storage
 - The iOS app can sometimes crash when opening a PBW file if it is not already running

### Developer Bug Fixes and Enhancements (Major Feature Enhancements are covered in the SDK)

 - Apps now only need one Pebble specific header, pebble.h
 - Exiting an app showing no windows will now not crash the Pebble
 - Pebble will not crash when cancelling an already cancelled timer
 - Pebble will not crash when cancelling an unregistered timer
 - Holding the up or down buttons now cause repeated clicks in menus
 - Changed the default stroke color to Black instead of White, as the default background color is White
 - Apps now cannot overwrite the system memory, and will be terminated if they attempt to
 - Int type changes on many APIs to ensure future compatability
 - User data can be attached to a window
 - The pebble tool displays an error message if you try to install an application that is not compatible with the target firmware
 - The menu icon resource is displayed even if it is not the first resource
 - Libpebble times out if no apps are installed
 - The valid range for UUIDs has changed - see the developer documentation
 - The Android app now installs bundles in Gmail attachments
 - System fonts now show capital W, Q and O
 - `pebble Install`` will now install even if the Android app is left in the “Update” screen
 - Apps will not crash if a text layer is not large enough to hold the requested text
 - `pebble install --logs` proceeds to tail logs even when install fails
 - Apps will not crash when popping/removing already popped/removed windows from the stack


---
# Copyright 2025 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
#     http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

title: Pebble SDK 2.0 BETA2 - Changelog
date: 2013-11-14
---

 * Pebble SDK 2.0 is currently in BETA and intended for developers only.
 * SDK 2.0 will be released later this year as an over-the-air update to all Pebble users.
 * Applications written for Pebble 1.x are not compatible with SDK 2.0

## What has changed since BETA1

Overview:

 - We have included ANCS in 2.0 - iOS users will get all notifications
 - We have added a screenshot tool
 - We have increased the AppMessage buffer size for PebbleKit JS Apps
 - We have changed a few firmware APIs to always pass parameter in this order: (buffer, size)
 - We have fixed many bugs

Known problems and bugs:

 - We are still working actively on improving datalogging on iOS and Android. If you wish to use this framework, please get in touch with us and tell us about your experience.
 - JavaScript apps on Android will only run if the phone is turned on and the Pebble app running (the easiest way to check this is to bring it to the foreground). This will be fixed soon.

 - If you downloaded the SDK before 5pm PST on 2013-11-14, your API documentation is probably broken. We have fixed this and pushed a new release without updating the version number because there are absolutely no changes (except the doc is now there ;).

### Firmware

 - Added support for ANCS
 - Fix UI bug when getting phone calls
 - Improved address book lookups when getting phone calls
 - Changed the behaviour when an app is closed from PebbleKit: return to the last running app or watchface (instead of the launcher)
 - Show malloc and free in the generated documentation
 - Fix doc for AccelAxisType
 - Do not animation a window disappearing if the window was pushed without animation
 - Add `GCornersRight` in the documentation of `GCornerMask`
 - Document `GTextOverflowMode`
 - Document the return value of the `persist_*` functions
 - Document `AppTimerCallback`
 - When exiting an app, all unload handlers will be called for loaded windows
 - Changed the order of parameters for `persist_read_data()`, `persist_read_string()`, `persist_write_data()`, `dict_calc_buffer_size()`, `dict_serialize_tuplets_to_buffer_with_iter()`: always ask for the pointer first and then the count or size
 - Fix bug where the status bar would not be displayed properly
 - Enabled Accelerometer high resolution output
 - Automatically reset the accelerometer when app exits
 - Removed the 1Hz accelerometer settings because it breaks the shake to backlight - Use peek() instead if you only need one sample per second.
 - Updated the guaranteed minimum buffer sizes for appmessage. They are in fact 124 / 636.
 - Fix bug where appLaunch commands would not be ACK'd
 - Increased AppMessage buffer sizes for JavaScript apps: they get 2k in and out.

### iOS App

 - Fixed several dataLogging bugs
 - Fixed most common crashes reported by TestFlight

### Android App

 - Fixed several dataLogging bugs
 - Fixed most common crashes reported by TestFlight

### PebbleKit iOS

 - DataLogging apps do not need to include an `appInfo.json` file anymore
 - Use `setAppUUID` to give the UUID of the app you want to talk to

### PebbleKit Android

 - Add `getWatchFWVersion()` to get a `FirmwareVersionInfo` object
 - Add `isDataLoggingSupported`

### SDK Tools

 - Added a `screenshot` command to the `pebble` tool
 - Revert the change in the tool where we would enforce a specific range of uuids
 - Improved error messages when the tools cannot be found
 - Do not truncate log messages coming from the JavaScript console
 - Only log app_log (and not system log) by default. Use `--verbose` to get all the logs.

### Examples

 - Fix a bug in the dataspooling demo where sealions and pelicans got mixed up
 - Fix PebbleKit Examples for the new `setAppUUID` style
 - Fix examples to use the new parameter orders for `persist` functions


---
# Copyright 2025 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
#     http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

title: Pebble SDK 2.0 BETA3 - Changelog
date: 2013-12-12
---

 * Pebble SDK 2.0 is currently in BETA and intended for developers only.
 * SDK 2.0 will be released later this year as an over-the-air update to all Pebble users.
 * Applications written for Pebble 1.x are not compatible with SDK 2.0
 * If a 2.0 version of an application exists, the Pebble mobile applications will automatically install it when when a user upgrades her/his Pebble.

## What has changed since BETA2

Overview:

 - The Android app fixes a large number of JS-related bugs.
 - The Android app fixes a bug where all messages sent to android would be automatically acknowledged. Your application should acknowledge app messages.
 - Some new user features in the firmware: Notification settings (with Do Not Disturb), better Alarms
 - Lots of small UI and stability fixes in Pebble.

Known problems and bugs:

### Firmware

 - added a Notification menu in the Settings to disable Notifications and configure a DoNotDisturb time frame
 - much better Alarm app with a nicer UI, snooze support, disabled alarms support
 - fix bugs where incoming calls could cause the vibration to stay on continuously
 - fix a rare condition where the accelerometer would crash if an interrupt comes too late or the accelerometer sent 0 samples
 - fix accelerometer behaviour when only 1 sample is requested: only send one sample (instead of 2)
 - fix a bug where an iOS device could disconnect just 1-2 seconds after connecting
 - automatically reconnect when user leaves Airplane Mode
 - show (in settings) that vibrations are disabled when Pebble is plugged
 - improved the set date/time UI to use the new DateTime UI (as in Alarms)
 - adjust the framebuffer offset for modal window transitions
 - reduced BLE connection interval
 - log more information when an application crashes
 - do not crash if an app_message section is re-opened - display warning instead
 - fix a bug which caused firmware updates to fail under some conditions (mostly android)
 - appsync will only update a dictionary if it has enough memory to do so (instead of finding out half-way that it does not have enough memory)
 - always return to the launcher after an app crash (to avoid a crash loop on a watchface)
 - *_destroy() will accept NULL pointers without errors
 - always go back to the top of the menu when launching the menu from a watchface (to make "blind" navigation easier)
 - fix a bug where an actionbar button would still be "pressed"
 - show Bluetooth Name on getting started screen
 - automatically delete old apps that are not compatible with this firmware version
 - accelerate scrolling on the menu
 - use modal window icon in the status bar as long as the modal window is displayed
 - Export dict_size so external developers don't have to do pointer math :)
 - fix a bug where scrolling in a long list of notifications could cause the display to "bounce"
 - fix a bug where lots of app logging messages could overflow the system task queue and kill app message
 - API documentation completely reviewed and updated
 - missed call modal views will timeout after 180s
 - force quit app when the back button is held for 2 seconds
 - menu_cell_basic_draw() now automatically center the text in the cell. If you do not want a subtitle, pass NULL (otherwise, space will be reserved for the subtitle).
 - fixed some bluetooth settings to avoid duplicated messages (could cause screenshot to go over 100%, duplicated log entries, firmware upgrade to fail, etc)
 - `peek()`ing the accelerometer is not allowed anymore when you have also subscribed to receive updates
 - fix a bug where the accelerometer would get stuck after a few hours

### iOS App

 - fix a bug where datalogging could dump messages to another phone on your local network
 - fix a bug where datalogging would get into a deadlock
 - fix a bug where the developer connection would appear active but would be closed

### Android App

 - fix a number of cases where a JS app would not be launched
 - fix bug where clicking the configure icon would not open the configuration view of an app
 - fix a bug which caused every AppMessage sent to Android to be acknowledged by the system
 - Select the Google Play Music App as the default music player
 - fix support email to use the Pebble bluetooth name instead of the last four digits of the serial
 - if there is an error when uploading an app, do not dismiss the update screen right away
 - do not dump large logs if stats json is not found
 - check for firmware update when foregrounded
 - fix bug where a canceled app install would be reported as completed
 - fix bug where an install would fail silently because the resources could not be loaded
 - display specific error message when a user tries to install a 2.0 app on a 1.x Pebble
 - fix a bug where the android app would display error message "Could not update" while looking for updates in the background

### PebbleKit iOS

 - allow one iOS application to exchange messages with several Pebble apps (with different UUIDs)
 - fix a crash trying to parse invalid firmware version
 - add CocoaPods support (see pebblekit-ios readme for more info)
 - enabled "all warnings" and fixed errors

### PebbleKit Android

No changes.

### SDK Tools

 - added support to upload any bundle (including firmware)
 - added test to detect missing tools
 - better implementation of the --debug flag
 - fix bug where tools would fail when installed in a folder with a space in it
 - fix bug where tools would fail on project with a space in the name
 - some 1.x to 2.x conversion bugs fixed
 - automatically re-enable applog when the watch reconnects

### Examples

 - fix crashing bugs in 91Dub


---
# Copyright 2025 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
#     http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

title: Pebble SDK 2.0 BETA4 - Changelog
date: 2013-12-23
---

 * Pebble SDK 2.0 is currently in BETA and intended for developers only.
 * SDK 2.0 will be released early next year as an over-the-air update to all Pebble users.
 * Applications written for Pebble 1.x are not compatible with SDK 2.0
 * If a 2.0 version of an application exists, the Pebble mobile applications will automatically install it when when a user upgrades her/his Pebble.

**You can start uploading your application to the Pebble appstore TODAY - [Please do so](http://dev-portal.getpebble.com/)!**

## What has changed since BETA3

Overview:

 - Fixed a problem where the iOS app would get killed after a few minutes in the background
 - Lots of Data Logging fixes on the firmware and on Android
 - Added timestamps on accelerometer samples
 - Improved error handling for PebbleKit JS apps on iOS and Android

### Firmware

 - Developers of apps can now register single and multi click handlers on the back button
 - Holding down the back button for 1.5s will force quit an existing app
 - Fixed bugs and optimize the filesystem: faster persist times, less problems with persistent storage, fix a bunch of rather complex problems where the recovery firmware could be damaged
 - Fixed scroll offset bug when displaying notifications
 - Dismiss missed call notfication after 180s
 - Fixed a bug where unicode characters were not supported in appinfo.json
 - Changed graphics_text_layout_get_max_used_size() to _not_ require a graphic context
 - Fixed a few more bluetooth bugs
 - Fixed a bug where Pebble could crash when you delete the last alarm
 - Fixed memory read exception that can occur when using a malloc-ed appsync buffer
 - Save notifications to storage during do not disturb
 - Document AccelAxisType in API Documentation
 - Fixed Music UI problems
 - Automatically center on screen a selected cell in a SimpleMenuLayer
 - Fixed bug where snprintf could crash the watch
 - Display an error message if a 2.0 pebble is connected to a 1.x mobile app
 - Fixed a bug where calling atoi() would crash an app
 - Many DataLogging improvements and fixes based on new unit tests
 - Display an alert on Pebble when we reset due to a system crash
 - Ignore NULL pointer passed to text_layer_destroy()
 - Limit the number of datalogging sessions to 20
 - Fixed a race condition that occurs when you set the sampling rate immediately after subscribing to the accel service
 - Keep persistent storage intact when upgrading an application
 - Added timestamps on accelerometer samples and a flag indicating if the watch was vibrating at the time of the sample
 - Fixed a bug where psleep could crash pebble
 - Fixed a bug where text_layer could add ellipsis to the wrong line

### iOS App

 - Fixed a bug where the iOS app would get killed in the background after just a few minutes
 - Show a local notification if a developer is connected but the app is about to get killed
 - PebbleKit JS: Fixed a bug where apps could not access localStorage with the array syntax
 - PebbleKit JS: Fixed a bug where a space in an URL opened with XmlHTTPRequest could crash the iOS app
 - PebbleKit JS: Fixed a bug where sending a byte array with 0xff in it would send 0x00 instead

### Android App

 - PebbleKit JS: Fixed a bug where a byte array would not be sent properly for named keys
 - Use new Android KitKat (4.4) APIs to do pairing on 4.4
 - PebbleKit JS: Do not send ack for ack/nack messages
 - Fixed Android crashing with OutOfMemory error when using Data Logging
 - Fixed Android Data Logging of byte array that was not working

### PebbleKit iOS

 - Do not ack ACKs...

### PebbleKit Android

 - No changes

### SDK Tools

 - Added support to libpebble to trigger reboot to recovery firmware
 - Added support for computers where python2 and python3 co-exist
 - Fixed an exception when receiving APP_LOG with extended characters
 - Fixed a bug where unicode characters were not supported in characterRegex field of `appinfo.json`
 - Fixed 30 second delay that can occur when building pebble apps on Ubuntu when there is no internet access
 - Added Pillow python dependency: needed for the screenshot functionality
 - Detect PIL/Pillow conflict and suggest a fix to the user

### Examples

 - Added a License to the examples


---
# Copyright 2025 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
#     http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

title: Pebble SDK 2.0 BETA5 - Changelog
date: 2014-01-10
---

 * Pebble SDK 2.0 is currently in BETA and intended for developers only.
 * Applications written for Pebble 1.x are not compatible with SDK 2.0
 * If a 2.0 version of an application exists, the Pebble mobile applications will automatically install it when when a user upgrades her/his Pebble.

**You can start uploading your application to the Pebble appstore TODAY - [Please do so](http://dev-portal.getpebble.com/)!**

## What has changed since BETA4

Overview:

 - Fixed Android datalogging bugs where data would get duplicated
 - Merged datalogging fixes for iOS that were supposed to be in BETA4 (sorry)
 - Added an end of session message on Android datalogging
 - Fixed accelerometer bugs where the accelerometer would stop sending data
 - Changed the animation when switching from one watchface to the next ...
 - Changed the battery API to return values going up to 100%

### Known Problems and limitations

 * **Accelerometer locking up**: Although we have fixed several bugs around the accelerometer, we have noticed a few instance of the accelerometer locking up and the accel callback not being called anymore. If you see this happen again, please use the "Contact Support" button to send us logs. Make sure you change the subject to "Accelerometer lockup". Thank you very much!

 * `getAccountToken()` (in PebbleKit JS) is not working yet. It currently returns a random string. In an upcoming update (before 2.0) it will return a unique token linked to the Pebble user account.
 This is tied with appstore functionnalities and not available yet in this beta build.
 * Some crash due to internal timers and deadlock conditions are still being investigated.
 * This version will reset your persistent storage when you install it

### Changes for Firmware:

 - Added a script in the SDK to help analyze app memory usage (analyze_static_memory_usage)
 - Changed the animation between watchfaces
 - Fix various composition bugs during animations
 - Several fix to the Pebble filesystem to fix problems occuring in persistent storage and datalogging
 - Add `bitmap_layer_get_bitmap()`
 - s/1 minutes/1 minute/ in the alarm app
 - Do not crash when loading a font from a NULL resource (can happen when memory is tight!)
 - Ignore buttons while animating from one window to another
 - Fix the back button in the getting started
 - Fix simplicity to show the time immediately
 - Fix sliding text to animate the time in immediately
 - Change simplicity to load the fonts as system fonts
 - Invert modal window status bar icons
 - Reworked `gpath_draw_filled()` to use less memory and use heap instead of stack
 - Improve persistent storage behaviour under tight memory
 - Enforce file size limits
 - Improve number of sectors of the filesystem
 - Fix a bug where in some condition going up and down after installing a watchface would not return to it
 - Fix a bug where `text_layer_get_content_size()` could return values that caused the text to be truncated
 - Do not crash in `gpath_draw_filled()` if called with 0 points
 - Added event service unsubscribe for app_focus_event (fixes a crash for Glance and Upright)
 - Changed the battery API to return values going up to 100%

### Changes for Pebble iOS App:

 - Fixes to datalogging to avoid duplicated data and iOS app getting stuck

### Changes for Pebble Android App:

 - Added an intent sent when a data logging session is finished
 - Fix a problem where JavaScript would not start on android 4.0
 - Fix some bluetooth scanning bugs that could cause timeouts or pebbles not detected
 - Improved bluetooth pairing screens for various Android versions

### Changes for PebbleKit iOS:

 - Fix some threading/deadlock bugs

### Changes for PebbleKit Android:

 - Do not retransmit same datalogging blocks more than once
 - Add a callback when the datalogging session is finished

### Changes for SDK Tools:

 - Added command `pebble analyze-size` to dump sections and symbol sizes
 - Increase timeout of the wsclient (could be triggered when installing firmware)
 - Added `--simple` option to `pebble new-project` to create a minimalist app
 - Updated to websocket-client 1.12 and removed dependency to io_sock

### Changes for Examples:

 - Update classio-battery-connection example to peek() the bluetooth connection status at startup

### Changes for Documentation:

 - Updated JS configuration example
 - Added link to the pebble-hacks/configurable project in the JS doc
 - Removed reference to the 1Hz acc sampling rate (RIP)
 - Added an example use of the `pebble install` command in the example page
 - Updated the `app_focus_subscribe` documentation in the event guide
 - Added a note in the datalogging guide to mention it's not a realtime system
 - Added doc for `only_shown_on_communication` in the anatomy of a pebble app chapter
 - Added that you can call `app_message_outbox_begin` in `outbox_sent` and `outbox_failed` now
 - Fixed formatting of the appinfo.json example in the anatomy of a pebble app chapter


---
# Copyright 2025 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
#     http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

title: Pebble SDK 2.0 BETA6 - Changelog
date: 2014-01-17
---

 * Pebble SDK 2.0 is currently in BETA and intended for developers only.
 * Applications written for Pebble 1.x are not compatible with SDK 2.0
 * If a 2.0 version of an application exists, the Pebble mobile applications will automatically install it when when a user upgrades her/his Pebble.

> **IMPORTANT NOTES FOR iOS Users**:
>
> * You must delete the Pebble app on your phone before installing this new version. It will now be called "Pebble Dev" and not "Pebble.". You must also re-install all of your JavaScript apps after installing this new version.
>
> * iPhone5S, iPad Air and Retina iPad Mini users will need to manually pair in the **Settings** of the phone.

## What has changed since BETA5

Overview:

 - The iOS Application distributed with BETA6 includes the new Pebble appstore
 - The firmware fixes a number of hard to reproduce crashes with system timers. This will fix a lot of the "Dangerously rebooting" Pebble crashes.

### Known Problems and limitations

 * `getAccountToken()` (in PebbleKit JS) is not working yet. It currently returns a random string. In an upcoming update (before 2.0) it will return a unique token linked to the Pebble user account.
 This is tied with appstore functionnalities and not available yet in this beta build.
 * The bugs that were reported on datalogging-iOS on BETA5 are not fixed yet in this release

### Changes for Firmware:

 * Rework the system timer to fix all timer related crashes
 * Add support for Pebble Steel LED to show charging status
 * Round rather than floor the battery charge percentage
 * Reverted timings for stm32 for 64MHz system clock based on stable 16Hz SPI clock.  Fixes display flicker at 30Hz, as well as saving power at the lower system clock (80->64) and sleeping more often due to faster display updates.
 * Fix a crash when canceling the bluetooth pairing dialog
 * Fix a bug where pushing a window in a window_unload callback would cause a crash
 * Export AccelData structure in the API doc
 * Vibrate when an app or watchface is installed
 * Fix a bug where the phone modal window would not update properly
 * Fix the light threshold for Pebble Steel

### Changes for Pebble iOS App:

 * Added the Pebble appstore
 * Added support for In-App Notifications
 * Add support for migrating 1.x apps into 2.0 apps
 * Fix a bug where the iOS app could crash when you switch away from a JavaScript app that has an ongoing network connection
 * PebbleKit JS iOS: sendAppMessage() now returns a transaction id

### Changes for Pebble Android App:

 * No changes.

### Changes for PebbleKit iOS:

 * add isNewer convenience call to PBWatch+Version
 * move NSJSONSerialization helper to PebbleVendor
 * add isEqualVersionOnly to just compare version number components, ignoring timestamp & hash

### Changes for PebbleKit Android:

 * No changes.

### Changes for SDK Tools:

 * Fix spelling in an error message (s/Insure/Ensure/)

### Changes for Examples:

 * No changes.

### Changes for Documentation:

 * Fix a 404 on the pebble tool link in the JS guide
 * Fix the persistence guide to reflect the new standardized parameters orders
 * Fix a typo in the title of the UI framework guide
 * Added designer resources in the UX design chapter


---
# Copyright 2025 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
#     http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

title: Pebble SDK 2.0 BETA7 - Changelog
date: 2014-01-23
---

Pebble SDK 2.0 is still in BETA and is **recommended only** for developers working on new applications for the upcoming Pebble appstore.

## Update Jan 31st: 2.0 Release Candidate 3

We fixed two more crashes. iOS user will automatically get the update. Android users can download it from this site.

Not sending an email to everyone this time because it really is a small changes and we want to spare your inbox before the week-end.

## Update Jan 30th: 2.0 Release Candidate 2

On January 30th, we released a 2.0 Release Candidate version of the firmware with the following changes:

* fixes a number of crashes
* app no longer gets killed when it cancels an invalid timer
* removes “persist_raw -9” message
* low battery message always uses the right icon
* fixes crash on watch shutdown
* fixes crash when using accel

## Updated Jan 29th: 2.0 Release Candidate

On January 29th, we released a 2.0 Release Candidate version of the firmware with the following changes:

* Fixed numerous crashes
* %Z flag passed to strftime no longer crashes the watch
* Fixed iOS connected but not receiving anything issue
* Firmware will now delete all data logging data on factory reset
* Rate limit logging to prevent apps from crashing app with logging loops
* Fixed issues were buttons become unresponsive
* Fixed gpath getting clipped in some cases
* Fixed accel lockup issue
* Fixed accel not using the right sampling rate
* Added low battery warning
* Cancel snooze timer when alarm is deleted

Please continue using BETA7 versions of the SDK and mobile applications.

## What has changed since BETA6

Overview:

 - More random crashes fixed in the firmware
 - Seriously improved datalogging on iOS (and some bugfixes on Android)
 - Fixed the URL scheme to install Pebble applications. It did not work in Beta6.
 - Added support for `getAccountToken()` in PebbleKit JS (iOS only at the moment)
 - iOS application and PebbleKit iOS are now 64 bits compatible
 - iOS application does not crash on iPhone 4 anymore
 - Some breaking changes in PebbleKit iOS: We cannot use NSNumber categories in 64 bit because their size is unknown. We added a new PBNumber class. This class is returned if you use the NSNumber Pebble category.

### Known Problems and limitations

 - Android does not include the Pebble appstore yet
 - PebbleKit iOS apps may see error messages about parsing firmware in their logs. This will be removed soon and does not impact anything in PebbleKit iOS.

### Changes for Firmware:

 - fix bugs with modal windows over fullscreen apps
 - fix bugs where action bar buttons could get "stuck"
 - reduced the power used by Pebble Steel LEDs
 - fix some data logging corruption issues on Pebble
 - fix a bug where the time of a notification would not be displayed properly
 - adjusted the battery charged thresholds so that Pebble Steel turns green when apps show 100%
 - fix a bug where you could get 110% battery
 - fix a bug where datalogging session could be incompletely initialized when pushed
 - fix a bug that could happen when looking for notifications
 - fix a bug where some original Pebbles (ev2_4) would never hit 100% battery
 - fix infinite loop if you push a modal while one is closing
 - fix some button problems on Pebble Steel

### Changes for Pebble iOS App:

 - added support for 64bits compilation
 - fix a bug where 64 bit devices would not display the bluetooth accessory picker
 - native login / signup screen
 - fix some button sizes to display text properly
 - calculate the area of the buttons on the left menu to highlight them dynamically
 - data logging: do not print error messages for partially fetched data - unless we are actually done
 - fix some bugs around the Bluetooth accessory picker
 - better management of the screens stack in onboarding process. allows users to go back.
 - do not display icon for watchfaces in the my pebble screen
 - fix bug where appstore url-scheme would not work
 - add link to terms and conditions
 - deal with timeout errors while installing apps
 - downloading apps in the Caches directory instead of Documents since that one gets pruned automatically by the system (Fixes pebblekit#39)
 - only allow to start dragging the center view if you start dragging from the left edge
 - fix crash for iPhone 4 users
 - fix bug where datalogging would try to send data to the Pebble app (instead of 3rd party apps)
 - lazy loading the web appstore views to improve loading speed
 - sort apps alphabetically in the locker
 - memory optimization to stay in the background longer
 - getAccountToken() now working in JavaScript
 - fix a bug where the configuration view was not sometimes not dismissed
 - rename the "Done" button of the configuration view to "Cancel"
 - send empty string back to the JS if the user cancels the configuration view (as per documentation)
 - only show the "notifications not set up" if there's a watch connected
 - fix a JS bug where in some conditions the 'showConfiguration' event might be fired before the 'ready' event

### Changes for Pebble Android App:

 - Datalogging: if a session contains bad data, just remove it at startup

### Changes for PebbleKit iOS:

 - PebbleKit iOS is now 64 bits (armv7s) compatible
 - We cannot use NSNumber categories in 64 bit because their size is unknown. We added a new PBNumber class. This class is returned if you use the NSNumber Pebble category.
 - Do not start the datalogging server if appUUID is all zeros

### Changes for PebbleKit Android:

No changes.

### Changes for SDK Tools:

No changes.

### Changes for Examples:

 - Classio-battery-connection is a watchface
 - Onthebutton is a watchface
 - Rumbletime is a watchface
 - Fuzzy Time is a watchface
 - Changed example UUID's to avoid appstore collisions

### Changes for Documentation:

 - Add note about datalogging size


---
# Copyright 2025 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
#     http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

title: Pebble SDK 2.0 DP2 - Changelog
date: 2013-09-24
---

>2.0 DP2.1

> We do not like making releases twice a week but we really wanted to fix the iOS/PebbleKit JS bug and so here it is. PebbleKit JS can now receive message on iOS and on Android. You only need to update your SDK for this to work. We will not release new versions of the mobile apps.

>The rest of the DP2 release notice below still applies.

### Known problems and bugs

 - Data Logging does not work on iOS7
 - The watch can run out of memory if the applications do not release the memory properly
 - On iOS, PebbleKit JS can not receive app messages (fixed in the DP2.1 release)

### In a nutshell

 * The format of applications has changed. Every application now requires an `appinfo.json` file in its base directory. This file contains the UUID, name and resources of the application. For PebbleKit JS apps, it may also contain the keys used for app_message communication.
 * The `pb-sdk` tool is gone. It is replaced by the `pebble` command line.
 * Instead of having the phone connect to the developer box, the developer tools will connect to the mobile application. When you turn on developer mode on your phone, it will display the IP address that you should use to connect to the phone. You can set a `PEBBLE_PHONE` environment variable to avoid retyping this all the time.
 * Fixed most blocking bugs reported on Developer Preview 1 (details below)
 * The Developer Guide has been completely rewritten and also includes a migration guide.

### Pebble Firmware

 - Fixed a bug where launching an application through the bluetooth protocol would cause the app to be re-launched if it was already running.
 - Added support for the middle button in the Golf app. This will send a message that is received by PebbleKit on iOS and Android.
 - Tap event is now disabled during a vibration (to avoid triggering the event)
 - Bumped firmware version and added tests to make sure that old apps will not run on the new firmware and vice-versa
 - Fixed various issue with firmware updates
 - AppLog does not need to be enabled manually anymore. It is automatically enabled by the `pebble` tool.

### Pebble SDK

 - Finalized conversion to new dynamic memory model: all _init functions have been replaced by _create() equivalent that return a pointer to a newly allocated and initialized structure (gbitmap_init functions, gpath_init, property_animation_init and app_sync_init have been updated to the new style)
 - Trigger a battery event when the percentage of battery charge changes (will trigger every 2%)
 - Data Spooling now takes a `void*` pointer (to avoid useless casting in developer code)
 - Data spooling session ids are now random
 - persist_read_int now returns 0 if the key does not exist (as per documentation)
 - Global static variables were not initialized properly
 - Fix a dataspooling bug where sometimes the close message did not contain the correct session id
 - Added a bluetooth_connection_service_peek() function
 - Export atol/atoi functions
 - Export app_comm_get_sniff_interval
 - As a developer, I can call the atan()/atan2() function to compute an arc-tangent
 - Renamed DataSpooling into DataLogging
 - Defined a new Design Pattern to subclass layers and included an example based on the famous Progress Bar layer (`watchapps/feature_layer_data`)

### PebbleKit iOS/Android

 - Redesigned completely the Android API for Data Logging (ex data spooling)

### PebbleKit JavaScript

 - Fixed a bug where only single digit integers would be passed as integers
 - On Android, the apps are now available in the "Webapps" menu
 - On iOS and Android, applications will keep on running once they are started (but they do not start automatically yet)
 - On iOS, you need to tap the appname to run it.
 - On iOS, to allow for `openURL` to work, you need to open the javascript console first
 - On iOS and Android, javascript `console.log` are sent over the developer connection (available with `pebble logs`)
 - You can now send array of bytes by passing an array of integers to `sendAppMessage()`
 - The keys in the appinfo.json file is now optional and you can use integers in strings as keys
 - If a received message as a key that is not listed in the `appKeys` block, the integer will be converted to a string
 - A bug where the navigation stack could be corrupted when calling `openURL` is fixed

### pb-sdk

 - Renamed pb-sdk into pebble
 - Added a --version option
 - Added a command to clean current project
 - Added an example of using APPLOG in the default generated project
 - Return meaningful error codes to the shell
 - Fixed a bug where `pb-sdk list` would fail if no apps are installed
 - Added a --javascript option to `pb-sdk new-project` to create a template of JS code and automatically generate the appinfo.json
 - Automatically detect old projects, refuse to build and offer the option to update the project
 - Added `convert-project` command to update old projects to the new style (note: this will not update the source code)
 - Added clean error message if a resource is missing

### iOS Application

 - The developer preview iOS application will automatically offer new version of the beta firmware
 - Added support for middle button in golf app
 - Some iOS7 fixes
 - Switched to TestFlight for distribution and crash reports

### Android Application

 - The developer preview Android application will automatically offer new version of the beta firmware
 - Added support for middle button in golf app
 - Switched to TestFlight for distribution and crash reports

### Pebble SDK Examples

 - Added an example for the persistent storage APIs
 - Fixed all the iOS examples to build out of the box
 - Reworked the Ocean Data Survey example


---
# Copyright 2025 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
#     http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

title: Pebble SDK 2.0 DP3 - Changelog
date: 2013-10-21
---

This version brings some major improvements and a lot of bugfixes. In a nutshell, the big changes are:

 * PebbleKit JavaScript now supports geolocation on all platforms
 * Pebble supports the ANCS protocol. See details below.

This is a private release under NDA.

### Pebble and ANCS

Pebble has been working on integrating Bluetooth Low Energy (BLE) technology into our upcoming software releases.  The initial goal for this work is to greatly enhance the notification experience between a Pebble and a BLE-capable iOS7 device (the iPhone4S and later) - this leverages the "ANCS" notification feature of iOS7.  A requirement for the public release of BLE-capable Pebble SW is that it will not change the Android experience.  We will work on enhancing the BLE experience specifically for Android users in future SW releases.

If you wish to help Pebble test BLE and ANCS, please read this carefully, this is pre-release software and there are still areas of the experience we are actively enhancing.  We greatly appreciate your help in testing these important features :-)

Pebble SDK DP3 (and up) include BLEs capabilities. Download the firmware and mobile apps as instructed in the installation instructions. You do not need anything else.

To configure ANCS and BLE:

- If you already had email configured in the iOS Pebble app, go into the Pebble app and turn that OFF. With ANCS, email notifications will automatically mirror the notifications that show up on your phone.
- The first time you set this up (after you install BLE/ANCS firmware) you will need to pair your phone with the watch to make the BTLE connection.
    - On the watch, go into the "Settings" view, and select "Bluetooth".
    - On your iOS7 iPhone go into the "Settings" app, select "Bluetooth".
    - You should see an entry called "Pebble-LExxxx" where xxxx is the 4 digit code that is shown at the top of the Pebble's Bluetooth screen.  Select that entry, and confirm pairing.
- Ensure that BOTH traditional Bluetooth and BLE are paired.  You will not be able to perform all of the functions (such as handling phone calls) if the Bluetooth-Classic connection is not working.
- We are actively working on enhancements to pairing, so this process will change as we near public release.

Known issues:

- Only pairing from iOS BT Settings works for now. In-Pebble-app pairing is still TODO.
- If you have a red bar "Notifications require additional setup" in your iOS app, this will not disappear when LE is paired / ANCS is activated.  You can safely ignore it.
- Gmail/IMAP in Pebble app + ANCS = Duplicate emails.  We recommend turning off email accounts from the Pebble iOS app.
- "Forget" from the watch's BT settings menu doesn't work as expected. iDevice immediately reconnects again.
- All notifications have same icon
- Max message length is shorter than Bluetooth Classic.
- Impact on battery life: we are actively characterizing and working on this, but it is currently less than Bluetooth-Classic only.

Please report any bugs by email to: [ancsbug@getpebble.com](mailto:ancsbug@getpebble.com)!

**Remember, this release is under NDA. Please do not share word of this new feature. Thanks a lot!**

### Known problems and bugs

 * Data Logging still does not work on iOS7
 * On iOS, to try the "openURL()" function, you must first click the "Details Indicator" button on the table view that lists the JavaScript process
 * On Android, to upgrade an existing JavaScript app, you must first kill it in the "JS App Processes" view (look for the Skull And Bones button)
 * On some Android phones running 4.1, we have encountered a situation where location services were not working. This problem and the appropriate fix is described by Google [in this forum post](http://productforums.google.com/forum/#!msg/mobile/LEPcl9e3dYE/3LZEhiWACigJ).

### Pebble Firmware

 - Fix a bug where Pebble would keep vibrating after answering a call

### Pebble SDK

 - Fix a bug which caused all apps to share the same persistent storage file

### PebbleKit iOS/Android

 - Removed some deprecated/private APIs call from PebbleKit-iOS
 - Update PebbleKit-iOS project files to Xcode 5
 - Fix PebbleKit Android build - moved libraries to libs/

### PebbleKit JavaScript

 - Getting current location now works on iOS and Android. It is also possible to watch the current position and be notified when it changes.
 - Fixed a bug on iOS where sending multiple digits number would not work
 - Fixed a bug with the 2.1 release on Android where it would be impossible to use AppMessage (with PebbleKit JS)
 - Receiving byte arrays now also works on iOS
 - Added Pebble.getAccountToken() to get a unique token for the current user account (Note: this is not documented yet.)

### pebble tool

 - Do not return 0 if something bad happened
 - Display the footprint of the app in RAM and the available heap space

### Pebble iOS Application

 - Fixed a UI bug on iOS7 when deleting an app
 - Fixed the Developer Mode UI on iOS7

#### 2013 10 25 - 2.0-DP3.1

We have release a 3.1 update for the iOS application which should fix the most common crash for the app.

### Pebble Android application

 - Fixed a bug where the Android app would continuously try to connect to the Pebble even after disconnecting/unpairing
 - Fixed a bug where Facebook notifications would have duplicated content in the name field and the main field
 - Automatically start an app after installation
 - Fixed a bug where it would be impossible to skip the onboarding process
 - Fixed a bug where switching the device orientation during firmware upgrade would cause the upgrade to start again

### Pebble SDK Examples

 - Fixed a crash in dropzone
 - Improved the weatherjs example to use geolocation and display the name of the city
 - Added a very cool arcade game to demonstrate use of persistent storage (watchapps/pebble_arcade)

### Documentation

 - Simplified installation instructions for Linux
 - Fixed a lot of broken links
 - Added a chapter on iOS whitelisting
 - Added a chapter on fonts
 - Reworked most of the developer guides


---
# Copyright 2025 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
#     http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

title: Pebble SDK 2.0.0 - Changelog
date: 2014-02-03
---

This is the first public release of Pebble SDK 2.0 and Pebble firmware 2.0.

## What has changed since BETA7

Overview:

 * We have fixed various crashes in the firmware (this was pre-released as 2.0-RC, 2.0-RC2 and 2.0-RC3)
 * We have restored support for direct Bluetooth connection from the computer to the pebble in the `pebble` tool
 * PebbleKit iOS now includes armv7s, arm64 and x86_64 libraries - There is a known bug in PebbleKit iOS 2.0.0 that can cause your application to crash when it is in the background. Please do not use this version to submit an application to Apple.

## Known bugs and issues

 * DataLogging disabled

    Pebble iOS 2.0.0 app can enter a crashloop situation when corrupted datalogging bytes are received from Pebble. To avoid this problem, we have disabled the datalogging APIs in firmware 2.0.0. We will re-enable datalogging when the iOS app 2.0.1 is available on the App Store.

 * PebbleKit iOS 2.0.0

    Can cause 3rd party applications to crash when it is in the background. Please do not use this version to submit an application to Apple. This will be fixed in 2.0.1.

### Changes for Firmware:

Changes since 2.0-RC3:

 * fix a deadlock when sending datalogging information
 * remove the "Your Pebble has reset" message

The changes between 2.0-BETA7 and 2.0-RC3 were:

 * fixes a number of crashes
 * app no longer gets killed when it cancels an invalid timer
 * removes “persist_raw -9” message
 * low battery message always uses the right icon
 * fixes crash on watch shutdown
 * fixes crash when using accel

### Changes for PebbleKit iOS:

 * Updated our version of CocoaLumberJack to fix a crash that could happen when logging in the background
 * Updated the build script to actually produce armv7s, arm64 and x86_64 dynamic libraries
 * Improve the datalogging protocol (between PebbleApp and PebbleKit) to be more efficient

### Changes for PebbleKit Android:

No changes.

### Changes for SDK Tools:

 * We have restored support for direct Bluetooth connection from the computer to the pebble in the `pebble` tool
 * Better handling of timeout errors with the websockets

### Changes for Examples:

No changes.

### Changes for Documentation:

 * Add parameter `did_vibrate` to AccelData and explanation.
 * Add parameter `timestamp` to AccelData and explanation.


---
# Copyright 2025 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
#     http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

title: Pebble SDK 2.0.1 - Changelog
date: 2014-02-20
---

This is a minor update to the Pebble SDK and the Pebble firmware.

## What has changed since 2.0.0

Overview:

 - We have re-enabled data logging in the Pebble firmware

## Known bugs and issues

 * PebbleKit iOS 2.0.0

    Can cause 3rd party applications to crash when it is in the background. Please do not use this version to submit an application to Apple. This will be fixed in a later release.

## Detailed list of changes

### Changes for Firmware:

 * We have re-enabled the data logging APIs.

### Changes for PebbleKit iOS:

 * No changes.

### Changes for PebbleKit Android:

 * No changes.

### Changes for SDK Tools:

 * No changes.

### Changes for Examples:

 * Reduce the accel discs step time

### Changes for Documentation:

 * Updated documentation on Android intents
 * Updated documentation on AppMessage, AppSync, Dictionary, Typlets


---
# Copyright 2025 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
#     http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

title: Pebble SDK 2.0.2 - Changelog
date: 2014-03-18
---

This is another minor update to the Pebble SDK and the Pebble firmware.

## What has changed since 2.0.1

Overview:

 - Fixes issue that prevented some users from being able to upgrade to 2.0.
 - Support for XCode 5.1
 - Removed Pillow as dependency for the SDK

## Known bugs and issues

None.

## Detailed list of changes

### Changes for Firmware:

 * Fix a bug that could prevent installation fo the firmware

### Changes for PebbleKit iOS:

 * No changes.

### Changes for PebbleKit Android:

 * No changes.

### Changes for SDK Tools:

 * LibPebble upgrade to remove PIL dependency
 * replaced PIL with pypng for taking screenshots

### Changes for Examples:

 * Update the todolist example to use graphics_text_layout_get_content_size instead of graphics_text_layout_get_max_used_size
 * Port improvements to simplicity from firmware to examples
 * Update quotes app for ready event

### Changes for Documentation:

 * Fixed error in API docs for accel
 * Fix javascript close URL in the javascript doc


---
# Copyright 2025 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
#     http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

title: Pebble SDK 2.1.1 - Changelog
date: 2014-05-08
---

## What has changed since 2.1

This release fixes a bug which caused the `pebble` tool to throw an exception when a Pebble app crashed. This is the only fix and we are not releasing a firmware 2.1.1, only the SDK is updated.

## What has changed since SDK 2.0.2

Overview:

 * Pebble dynamic memory allocation has been improved and will now detect when you try to free() memory twice.
   * With Pebble 2.1 your application will be killed and a message is shown in the console so you can detect and fix this problem, instead of potentially causing a memory corruption issue.
 * IMPORTANT: You will need to update your Pebble to run apps built with the 2.1 SDK. Applications compiled with the SDK 2.1 will not appear in the menu and will not run on Pebble firmware 2.0.

## Detailed List of Changes:
### Changes for Firmware:
 * Fixed crash caused by calling number_window_set_label
 * Fixed white line at the bottom of MenuLayer when last row is selected
 * Fixed an issue where the watch would get into a reset loop after boot
 * Fixed issue that sometimes caused persistent storage values to not persist
 * Fixed issue where caller ID shows info from the previous call
 * Fixed caller ID sometimes not displaying on outgoing calls
 * Pebble dynamic memory allocation has been improved. Your application will now be killed when you try to free() memory twice
 * Apps can no longer crash the watch on app exit
 * Bluetooth reconnection is more reliable
 * Battery monitor is more consistent
 * Multiple power reduction improvements
 * Documentation improvements
 * Clip text instead of truncating when vertical space is inadequate
 * Notifications can be cleared via the Notification section in the Settings menu

### Changes for PebbleKit iOS:

 * Some improvements to datalogging to help troubleshoot issues

### Changes for PebbleKit Android:

 * No changes

### Changes for SDK Tools:

 * Allow firmware bundles to be installed with the install command
 * Allow SDK location to be overridden by the `PEBBLE_SDK_PATH` environment variable
 * Replaced PIL with pypng for taking screenshots
 * Fixed extra row always being added to screenshots

### Changes for Examples:

 * Removed ToDoList demo from SDK examples

### Changes for Documentation:

 * Various documentation fixes and improvements


---
# Copyright 2025 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
#     http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

title: Pebble SDK 2.1 - Changelog
date: 2014-05-06
---

## What has changed since SDK 2.0.2

Overview:

 * Pebble dynamic memory allocation has been improved and will now detect when you try to free() memory twice.
   * With Pebble 2.1 your application will be killed and a message is shown in the console so you can detect and fix this problem, instead of potentially causing a memory corruption issue.
 * IMPORTANT: You will need to update your Pebble to run apps built with the 2.1 SDK. Applications compiled with the SDK 2.1 will not appear in the menu and will not run on Pebble firmware 2.0.

## Detailed List of Changes:
### Changes for Firmware:
 * Fixed crash caused by calling number_window_set_label
 * Fixed white line at the bottom of MenuLayer when last row is selected
 * Fixed an issue where the watch would get into a reset loop after boot
 * Fixed issue that sometimes caused persistent storage values to not persist
 * Fixed issue where caller ID shows info from the previous call
 * Fixed caller ID sometimes not displaying on outgoing calls
 * Pebble dynamic memory allocation has been improved. Your application will now be killed when you try to free() memory twice
 * Apps can no longer crash the watch on app exit
 * Bluetooth reconnection is more reliable
 * Battery monitor is more consistent
 * Multiple power reduction improvements
 * Documentation improvements
 * Clip text instead of truncating when vertical space is inadequate
 * Notifications can be cleared via the Notification section in the Settings menu

### Changes for PebbleKit iOS:

 * Some improvements to datalogging to help troubleshoot issues

### Changes for PebbleKit Android:

 * No changes

### Changes for SDK Tools:

 * Allow firmware bundles to be installed with the install command
 * Allow SDK location to be overridden by the `PEBBLE_SDK_PATH` environment variable
 * Replaced PIL with pypng for taking screenshots
 * Fixed extra row always being added to screenshots

### Changes for Examples:

 * Removed ToDoList demo from SDK examples

### Changes for Documentation:

 * Various documentation fixes and improvements


---
# Copyright 2025 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
#     http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

title: Pebble SDK 2.2 - Changelog
date: 2014-06-04
---

## Detailed List of Changes:
### Changes for Firmware:

* Music app redesign to fix some layout issues & add progress bar
* Fix persist reads returning too little data if previously partially read
* Additional stability improvements
* Alarm now vibrates for 10 min instead of 1 min
* Launcher menu is now re-orderable. Hold the select button to enter reorder mode
* Volume control in the music app. Hold the select button in the music app to enter volume control mode

### Changes for PebbleKit iOS:

* Removed PBWatch+PhoneVersion (moved to PebblePrivateKit)
* Make PBWatch+Version report the correct version
* Fixed a crash when calling PBNumber description

### Changes for PebbleKit Android:

No changes

### Changes for SDK Tools:

No changes

### Changes for Examples:

No changes

### Changes for Documentation:

No changes


---
# Copyright 2025 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
#     http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

title: Pebble SDK 2.3 - Changelog
date: 2014-06-30
---

## Detailed List of Changes:
### Changes for Firmware:

* Don't generate multiple single click events on release if a repeating click handler is also used
* Fixed a small memory leak when destroying number_layer objects
* Fixed a menu_layer display bug when header height is set to 0
* Allow app developers to supply their own ldscript
* Give a better error message when an unsupported libc function is used
* *_destroy functions now correctly do nothing when called with NULL pointers
* Fixed some BT LE connectivity issues
* Fixed a crash when we ran out of persist space
* Fixed a crash on reconnect when a user had a lot of pending iOS notifications
* Fixed an issue where the watch would continue to vibrate after a call is ended
* Fixed a display issue in Bluetooth settings when the status bar incorrectly says "Now Discoverable" in airplane mode
* Fixed a display issue with the notification font settings
* Fixed a display issue with the music app showing stale information when bluetooth is disconnected.
* Added the ability to skip to the next and previous notification by double clicking the up and down buttons
* Disabled the use of the back button for the Bluetooth pairing screen and the Alarm screen
* Show a status bar icon when notifications are set to "Phone Calls Only"

### Changes for PebbleKit iOS:

* Removed Bluetooth LE code from PebbleKit
* Improvements to data logging to help troubleshoot issues
* Removed PBWatch+PhoneVersion and +Polling
* Made PBWatch+Version report the correct version
* Fixed a crash when calling PBNumber description
* Changed imports from \<PebbleKit/HeaderName.h\> to "HeaderName.h" format
* Fixed on rare race-condition when sending data between phone and watch
* Made PebbleKit.podspec pass most-recent CocoaPod linter
* Prefixed internally used logging classes to fix conflict when using CocoaLumberjack in your app
* Made existing logging more descriptive

### Changes for PebbleKit Android:

No changes

### Changes for SDK Tools:

No changes

### Changes for Examples:

No changes

### Changes for Documentation:

* Added documentation for the calloc libc function
* Documented that text drawing functions use UTF-8 and will return errors on invalid input