Merge branch 'ella-support' of https://github.com/ellaism/blue-app-eth into ellaism-ella-support

This commit is contained in:
BTChip github
2018-08-02 10:23:20 +02:00
9 changed files with 19 additions and 2 deletions

View File

@@ -17,7 +17,8 @@ typedef enum chain_kind_e {
CHAIN_KIND_AKROMA,
CHAIN_KIND_MUSICOIN,
CHAIN_KIND_CALLISTO,
CHAIN_KIND_ETHERSOCIAL
CHAIN_KIND_ETHERSOCIAL,
CHAIN_KIND_ELLAISM
} chain_kind_t;
typedef struct chain_config_s {

View File

@@ -1537,6 +1537,9 @@ tokenDefinition_t* getKnownToken() {
case CHAIN_KIND_ETHERSOCIAL:
numTokens = NUM_TOKENS_ETHERSOCIAL;
break;
case CHAIN_KIND_ELLAISM:
numTokens = NUM_TOKENS_ELLAISM;
break;
}
for (i=0; i<numTokens; i++) {
switch(chainConfig->kind) {
@@ -1579,6 +1582,9 @@ tokenDefinition_t* getKnownToken() {
case CHAIN_KIND_ETHERSOCIAL:
currentToken = PIC(&TOKENS_ETHERSOCIAL[i]);
break;
case CHAIN_KIND_ELLAISM:
currentToken = PIC(&TOKENS_ELLAISM[i]);
break;
}
if (os_memcmp(currentToken->address, tmpContent.txContent.destination, 20) == 0) {
return currentToken;

View File

@@ -699,6 +699,10 @@ const tokenDefinition_t const TOKENS_ETHEREUM[NUM_TOKENS_ETHEREUM] = {
{{0xe3,0x86,0xb1,0x39,0xed,0x37,0x15,0xca,0x4b,0x18,0xfd,0x52,0x67,0x1b,0xdc,0xea,0x1c,0xdf,0xe4,0xb1}, "ZST ", 8},
};
const tokenDefinition_t const TOKENS_ELLAISM[NUM_TOKENS_ELLAISM] = {
{{0x99,0x1e,0x7f,0xe4,0xb0,0x5f,0x2b,0x3d,0xb1,0xd7,0x88,0xe7,0x05,0x96,0x3f,0x5d,0x64,0x7b,0x00,0x44}, "MINING", 18},
};
const tokenDefinition_t const TOKENS_ETHEREUM_CLASSIC[NUM_TOKENS_ETHEREUM_CLASSIC] = {};
const tokenDefinition_t const TOKENS_ETHERSOCIAL[NUM_TOKENS_ETHERSOCIAL] = {};

View File

@@ -24,6 +24,7 @@ typedef struct tokenDefinition_t {
} tokenDefinition_t;
#define NUM_TOKENS_AKROMA 0
#define NUM_TOKENS_ELLAISM 1
#define NUM_TOKENS_ETHEREUM 677
#define NUM_TOKENS_ETHEREUM_CLASSIC 0
#define NUM_TOKENS_ETHERSOCIAL 0
@@ -38,6 +39,7 @@ typedef struct tokenDefinition_t {
#define NUM_TOKENS_CALLISTO 0
extern tokenDefinition_t const TOKENS_AKROMA[NUM_TOKENS_AKROMA];
extern tokenDefinition_t const TOKENS_ELLAISM[NUM_TOKENS_ELLAISM];
extern tokenDefinition_t const TOKENS_ETHEREUM[NUM_TOKENS_ETHEREUM];
extern tokenDefinition_t const TOKENS_ETHEREUM_CLASSIC[NUM_TOKENS_ETHEREUM_CLASSIC];
extern tokenDefinition_t const TOKENS_ETHERSOCIAL[NUM_TOKENS_ETHERSOCIAL];