• Stars
    star
    652
  • Rank 66,412 (Top 2 %)
  • Language
    Java
  • License
    Apache License 2.0
  • Created over 9 years ago
  • Updated over 3 years ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

android tv metro framework and server API

TV Metro android lib and API

Design doc: https://github.com/XiaoMi/android_tv_metro/raw/master/design/app_api.ppt

#API & Data structure the Metro style is constructed by two kinds of elements: Album and Display Item

Album can contain multi albums and display items.

Display item can be defined as video, game, app, music and so on.

You can deprive your own game/app/video detail item from display item.

                         Album
                           |
         __________________|___________________
         |    ...  |           |       ...    |
       Album      Album    Display Item     Display Item

The main page is also defined as Album.

##API Style ###API description http://host/v1/ns/type/?id=res_id

ns : namespace, resource type

type: item or item list

id : resource id in back-end server system

###Details http://host/game(video/app)/item?id=12346 return item list

###Album http://host/game(video/app)/album?id=6464 return album

###Category http://host/game(video/app)/category?id=123456 return album

Note: Album and Category are most same concept.

##Tab "app/game"

##Tab "video"

##Tab "video category"

##Home JSON definition

Home JSON Sample

Server API definition refer to: https://github.com/XiaoMi/android_tv_metro/raw/master/server/TVMarketAPI.md

##Home display data { "data": [ { "items": [display items], "images": {}, "name": "TAB 1", "id": "recommend", "type": "album", "ns": "video" }, { "items": [display item], "images": {}, "name": "TAB 2", "id": "recommend", "type": "album", "ns": "video" } ] }

##Display Item: { "target": { "type": "item" }, "images": { "back": { "url": "", "ani": {}, "pos": {} } }, "name": "Display Name)", "times": { "updated": 1409202939, "created": 1409202939 }, "_ui": { "layout": { "y": 2, "x": 3, "w": 1, "h": 1 }, "type": "metro_cell_banner" }, "id": "987722", "type": "item", "ns": "video" }

##Album {

"data": [
    {
        "items": [display items],
        "images": { },
        "name":"game tab name",
        "times": {
            "updated": 0,
            "created": 0
        },
        "_ui": {
            "type": "metro"
        },
        "id": "recommend",
        "type": "album",
        "ns": "game"
    },
    {
        "items": [display items],
        "images": { },
        "name": "game tab Name",
        "times": {
            "updated": 0,
            "created": 0
        },
        "_ui": {
            "type": "metro"
        },
        "id": "categories",
        "type": "album",
        "ns": "game"
    },
    {
        "items": [dispay items],
        "images": { },
        "name": "video tab name",
        "times": {
            "updated": 0,
            "created": 0
        },
        "_ui": {
            "type": "metro"
        },
        "id": "recommend",
        "type": "album",
        "ns": "video"
    },
    {
        "items": [display items],
        "images": { },
        "name": "video tab name",
        "times": {
            "updated": 0,
            "created": 0
        },
        "_ui": {
            "type": "metro"
        },
        "id": "categories",
        "type": "album",
        "ns": "video"
    }
],
"preload": {
    "images": []
},
"update_time": 0

}

##Display Item

{
    
"target": {
    "type": "item"
},
"images": {
    "text": {
        "url": "",
        "ani": {},
        "pos": {}
    },
    "icon": {
        "url": "",
        "ani": {},
        "pos": {}
    },
    "back": {
        "url": "http://xxx/fffff.png",
        "ani": {},
        "pos": {}
    },
    "spirit": {
        "url": "",
        "ani": {},
        "pos": {}
    }
},
"name": "name",
"times": {
    "updated": 1404466152,
    "created": 1404454443
},
"_ui": {
    "type": "metro_cell_banner",
    "layout": {
        "y": 1,
        "x": 1,
        "w": 1,
        "h": 2
    }
},
"id": "180",
"type": "item",
"ns": "game"

}

##TV Metro liberary and API ###android lib: supply one framework to build sw540dp metro layout.

###API: server API and data structure.

This framework help you easy to build one TV metro UI style applicaiton. As for detail business data definition, you need handle by your selft.

##android Lib RecommendCardView Card view GenericSubjectLoader Loader for album(tabs is one instance of album)

##How to integrate the android lib? you just need inherit MainActity and implement your Tabs Loader. Refer to TVMetroSample application

How to implement your owver server? step one: 1, define your home data

2, implement your details/list API

##Download test APK

Download test apk, you can run it at android pad or TV

Click Download

##Welcome to Contact US

More Repositories

1

soar

SQL Optimizer And Rewriter
Go
8,595
star
2

mace

MACE is a deep learning inference framework optimized for mobile heterogeneous computing platforms.
C++
4,871
star
3

open-falcon

A Distributed and High-Performance Monitoring System
3,031
star
4

Gaea

Gaea is a mysql proxy, it's developed by xiaomi b2c-dev team.
Go
2,552
star
5

naftis

An awesome dashboard for Istio built with love.
Go
1,898
star
6

mone

No description, website, or topics provided
Java
1,088
star
7

MiNLP

XiaoMi Natural Language Processing Toolkits
Scala
771
star
8

hiui

HIUI is a solution that is adequate for the fomulation and implementation of interaction and UI design standard for front, middle and backend.
TypeScript
713
star
9

minos

Minos is beyond a hadoop deployment system.
Python
520
star
10

rose

Rose is not only a framework.
Java
498
star
11

shepher

Java
492
star
12

MiLM-6B

414
star
13

chronos

Network service to provide globally strictly monotone increasing timestamp
Java
397
star
14

LuckyMoneyTool

Java
375
star
15

mace-models

Mobile AI Compute Engine Model Zoo
Python
368
star
16

mobile-ai-bench

Benchmarking Neural Network Inference on Mobile Devices
C++
346
star
17

kaldi-onnx

Kaldi model converter to ONNX
Python
233
star
18

linden

Java
230
star
19

themis

Themis provides cross-row/cross-table transaction on HBase based on google's percolator.
Java
226
star
20

rdsn

Has been migrated to https://github.com/apache/incubator-pegasus/tree/master/rdsn
C++
144
star
21

thain

Thain is a distributed flow schedule platform.
TypeScript
81
star
22

misound

MiSound is a Android application making XiaoMi's SoundBar more powerful. EQ, control, player all in one.
Java
63
star
23

galaxy-sdk-java

Java SDK for Xiaomi Structured Datastore Service
Java
63
star
24

C3KG

Python
61
star
25

ozhera

Java
54
star
26

jack

Jack is a cluster manager built on top of Zookeeper and thrift.
51
star
27

galaxy-fds-sdk-python

Python SDK for Xiaomi File Data Storage.
Python
50
star
28

nnlib

Fork of https://source.codeaurora.org/quic/hexagon_nn/nnlib
C
49
star
29

pegasus-rocksdb

Has been migrated to https://github.com/pegasus-kv/rocksdb
C++
34
star
30

cloud-ml-sdk

Python
32
star
31

pegasus-java-client

Has been migrated to https://github.com/apache/incubator-pegasus/tree/master/java-client
Java
31
star
32

ECFileCache

Java
30
star
33

cmath

CMATH: Can your language model pass Chinese elementary school math test?
Python
30
star
34

talos-sdk-golang

Go SDK for Xiaomi Streaming Message Queue
Go
28
star
35

mace-kit

C++
27
star
36

pegasus-go-client

Has been migrated to https://github.com/apache/incubator-pegasus/tree/master/go-client
Go
23
star
37

emma

Python
22
star
38

xiaomi.github.com

JavaScript
21
star
39

galaxy-fds-sdk-java

Java SDK for Xiaomi File Data Storage.
Java
21
star
40

StableDiffusionOnDevice

本项目是一个通过文字生成图片的项目,基于开源模型Stable Diffusion V1.5生成可以在手机的CPU和NPU上运行的模型,包括其配套的模型运行框架。
C++
20
star
41

galaxy-fds-sdk-android

Android SDK for Xiaomi File Data Storage.
Java
17
star
42

galaxy-sdk-python

Python SDK for Xiaomi Structured Datastore Service
Python
16
star
43

go-fds

Next-generation fds golang sdk
Go
15
star
44

galaxy-fds-sdk-php

PHP SDK for Xiaomi File Data Storage.
PHP
15
star
45

galaxy-sdk-go

Go SDK for Xiaomi Structured Datastore Service
Go
15
star
46

galaxy-hadoop

Hadoop interface for Xiaomi Open Storage
Java
13
star
47

galaxy-thrift-api

Thrift API for Xiaomi Structured Datastore Service
Thrift
11
star
48

galaxy-fds-sdk-cpp

C++ SDK for Xiaomi File Data Storage
C++
10
star
49

galaxy-fds-sdk-javascript

JavaScript
9
star
50

pegasus-python-client

Has been migrated to https://github.com/apache/incubator-pegasus/tree/master/python-client
Python
8
star
51

galaxy-sdk-php

PHP SDK for Xiaomi Structured Datastore Service
PHP
8
star
52

pegasus-datax

Provide pegasus plugin in alibaba/DataX, please refer to 'pegasuswriter/doc/pegasuswriter.md'.
Java
8
star
53

galaxy-fds-migration-tool

A MapReduce tool to migrate objects or files parallely between different object storage systems
Java
7
star
54

galaxy-sdk-nodejs

Node.js SDK for Xiaomi Structured Datastore Service
JavaScript
6
star
55

pegasus-nodejs-client

Has been migrated to https://github.com/apache/incubator-pegasus/tree/master/nodejs-client
JavaScript
6
star
56

pegasus-scala-client

Has been migrated to https://github.com/apache/incubator-pegasus/tree/master/scala-client
Scala
6
star
57

PowerTestDemo

Java
5
star
58

DetermLR

Open source code for paper
Python
5
star
59

galaxy-fds-sdk-ios

ios sdk for galaxy-fds
Objective-C
5
star
60

SiMuST-C

Python
5
star
61

pegasus-YCSB

Provide pegasus plugin in YCSB, please refer to 'Test Pegasus' section in README.
Java
5
star
62

nlpcc-2023-shared-task-9

https://mp.weixin.qq.com/s/pBDvTmr_oOHUPzBhjXG-aw
Python
5
star
63

galaxy-sdk-cpp

C++ SDK for Xiaomi Structured Datastore Service
C++
4
star
64

TED-MMST

1
star
65

PowerTestDemoGlobal

The demo script of Power Consumption Test.
Java
1
star
66

galaxy-sdk-javascript

Javascript SDK for Xiaomi Structured Datastore Service
JavaScript
1
star