In some cases you just want to display your data on a LaMetric Time and do it in a very simple way. This app allows you to do that in three steps:
- Expose your data to some URL available from the Internet or in in the same local network with the device in predefined JSON format (more about that below).
- Install My Data DIY app to your LaMetric Time
- Configure the app using the URL from step 1 and choose an update interval.
Data Format
Data the app understands must be in JSON format with the following structure:
{
"frames": [ frame, frame, ...]
}- "frames" is an array of "frame" objects.
- Each frame occupies a whole screen of LaMetric Time device at a single time.
- There are three "frame" types
- simple frame
- goal frame
- spike-chart frame
- Frames get displayed one by one. The time a frame is displayed can be adjusted using "duration" attribute (works only with frames with non scrollable content)
- Number of frames can vary from 1 to 20
Frame Types
Frame has the following structure
{
"icon": "<icon id or base64 encoded data>",
"text": "UTF8 encoded text",
"duration": <integer, time in miliseconds>,
"goalData" : {
"start" : <integer, start value>,
"current" : <integer, current value>,
"end" : <integer, goal value>
},
"chartData" : [ <array of integers> ]
}| Property | Description |
| icon | (optional).
|
| text | Text that will be displayed. If it is too long – it will scroll |
| duration | (optional) Specifies how long a "frame" will be displayed on the screen before proceeding to the next one. There is a limit of 10 seconds for frame. Works only with frames that do not scroll. |
| goalData | (optional) Describes frame with the progress indicator. Useful to visualize some kind of goals. |
| chartData | (optional) Describes spike chart. Useful to visualize how data changes over time. Chart will be scaled automatically. |
Simple Frame, No Icon

{
"frames" : [
{
"text" : "hello!"
}
]
}Simple Frame

{
"frames" : [
{
"icon": "794",
"text": "Hello!"
}
]
}Goal Frame, No Icon

{
"frames" : [
{
"goalData": {
"start": 0,
"current": 6000,
"end": 10000,
"unit": "MI"
}
]
}Goal Frame

{
"frames" : [
{
"icon": "22835",
"goalData": {
"start": 0,
"current": 6000,
"end": 10000,
"unit": "MI"
}
}
]
}Spike-chart Frame

{
"frames" : [
{
"chartData": [1, 10, 15, 20, 6, 9, 11, 16, 22, 24]
}
]
}Example
Let's pretend we are developing an app that displays saving for a vacation on a LaMetric Time device. In this case URL must respond with status code 200 and JSON in the following format:
{
"frames": [
{
"text": "SAVINGS",
"icon": "61"
},
{
"goalData": {
"start": 0,
"current": 1500,
"end": 2000,
"unit": ""
},
"icon": "34"
},
{
"index": 2,
"chartData": [
10,
20,
5,
40,
20,
15,
20
]
}
]
}And this is what we get
If you still have any questions – let us know!
Enjoy!