From 65d734df58566d11365a3cf0d66f79811ac35381 Mon Sep 17 00:00:00 2001 From: Pavol Rusnak Date: Tue, 3 Mar 2015 02:09:15 +0100 Subject: [PATCH] add Darkcoin --- firmware/coins.c | 1 + firmware/coins.h | 2 +- firmware/protob/messages.options | 2 +- firmware/protob/messages.pb.h | 8 ++++---- 4 files changed, 7 insertions(+), 6 deletions(-) diff --git a/firmware/coins.c b/firmware/coins.c index 60a44429a4..59a28bf844 100644 --- a/firmware/coins.c +++ b/firmware/coins.c @@ -26,6 +26,7 @@ const CoinType coins[COINS_COUNT] = { {true, "Namecoin", true, "NMC", true, 52, true, 10000000, true, 5}, {true, "Litecoin", true, "LTC", true, 48, true, 10000000, true, 5}, {true, "Dogecoin", true, "DOGE", true, 30, true, 100000000, true, 22}, + {true, "Darkcoin", true, "DRK", true, 76, true, 100000, true, 16}, }; const CoinType *coinByShortcut(const char *shortcut) diff --git a/firmware/coins.h b/firmware/coins.h index 1995bb797d..b57566ee33 100644 --- a/firmware/coins.h +++ b/firmware/coins.h @@ -22,7 +22,7 @@ #include "types.pb.h" -#define COINS_COUNT 5 +#define COINS_COUNT 6 extern const CoinType coins[COINS_COUNT]; diff --git a/firmware/protob/messages.options b/firmware/protob/messages.options index cc66922d13..da0af37c9c 100644 --- a/firmware/protob/messages.options +++ b/firmware/protob/messages.options @@ -2,7 +2,7 @@ Features.vendor max_size:33 Features.device_id max_size:25 Features.language max_size:17 Features.label max_size:33 -Features.coins max_count:5 +Features.coins max_count:6 Features.revision max_size:20 Features.bootloader_hash max_size:32 diff --git a/firmware/protob/messages.pb.h b/firmware/protob/messages.pb.h index 50b2fd867e..873c950f79 100644 --- a/firmware/protob/messages.pb.h +++ b/firmware/protob/messages.pb.h @@ -370,7 +370,7 @@ typedef struct _Features { bool has_label; char label[33]; size_t coins_count; - CoinType coins[5]; + CoinType coins[6]; bool has_initialized; bool initialized; bool has_revision; @@ -624,7 +624,7 @@ extern const char SimpleSignTx_coin_name_default[17]; /* Initializer values for message structs */ #define Initialize_init_default {0} -#define Features_init_default {false, "", false, 0, false, 0, false, 0, false, 0, false, "", false, 0, false, 0, false, "", false, "", 0, {CoinType_init_default, CoinType_init_default, CoinType_init_default, CoinType_init_default, CoinType_init_default}, false, 0, false, {0, {0}}, false, {0, {0}}, false, 0} +#define Features_init_default {false, "", false, 0, false, 0, false, 0, false, 0, false, "", false, 0, false, 0, false, "", false, "", 0, {CoinType_init_default, CoinType_init_default, CoinType_init_default, CoinType_init_default, CoinType_init_default, CoinType_init_default}, false, 0, false, {0, {0}}, false, {0, {0}}, false, 0} #define ClearSession_init_default {0} #define ApplySettings_init_default {false, "", false, "", false, 0, false, {0, {0}}} #define ChangePin_init_default {false, 0} @@ -677,7 +677,7 @@ extern const char SimpleSignTx_coin_name_default[17]; #define DebugLinkStop_init_default {0} #define DebugLinkLog_init_default {false, 0, false, "", false, ""} #define Initialize_init_zero {0} -#define Features_init_zero {false, "", false, 0, false, 0, false, 0, false, 0, false, "", false, 0, false, 0, false, "", false, "", 0, {CoinType_init_zero, CoinType_init_zero, CoinType_init_zero, CoinType_init_zero, CoinType_init_zero}, false, 0, false, {0, {0}}, false, {0, {0}}, false, 0} +#define Features_init_zero {false, "", false, 0, false, 0, false, 0, false, 0, false, "", false, 0, false, 0, false, "", false, "", 0, {CoinType_init_zero, CoinType_init_zero, CoinType_init_zero, CoinType_init_zero, CoinType_init_zero, CoinType_init_zero}, false, 0, false, {0, {0}}, false, {0, {0}}, false, 0} #define ClearSession_init_zero {0} #define ApplySettings_init_zero {false, "", false, "", false, 0, false, {0, {0}}} #define ChangePin_init_zero {false, 0} @@ -917,7 +917,7 @@ extern const pb_field_t DebugLinkLog_fields[4]; /* Maximum encoded size of messages (where known) */ #define Initialize_size 0 -#define Features_size (230 + 5*CoinType_size) +#define Features_size (236 + 6*CoinType_size) #define ClearSession_size 0 #define ApplySettings_size 1083 #define ChangePin_size 2