Skip to content

Commit

Permalink
improving nanoS size
Browse files Browse the repository at this point in the history
  • Loading branch information
chcmedeiros committed Jun 26, 2024
1 parent 7379154 commit 1d7d4a1
Show file tree
Hide file tree
Showing 8 changed files with 36,322 additions and 36,061 deletions.
1 change: 0 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@ ifeq ($(BOLOS_SDK),)

ZXLIB_COMPILE_STAX ?= 1
SUBSTRATE_PARSER_FULL ?= 1
PRODUCTION_BUILD ?= 1
include $(CURDIR)/deps/ledger-zxlib/dockerized_build.mk

else
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -207,7 +207,7 @@ Please:
| Change sigs required | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | `u64`sigs_required<br/> |
| Make multisig secondary | | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | `AccountId`multisig<br/> |
| Make multisig primary | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | `AccountId`multisig<br/>`Optionu64`optional_cdd_auth_id<br/> |
| Execute scheduled proposal | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | `AccountId`multisig<br/>`u64`proposal_id<br/>`IdentityId`multisig_did<br/>`Weight`\_proposal_weight<br/> |
| Execute scheduled proposal | | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | `AccountId`multisig<br/>`u64`proposal_id<br/>`IdentityId`multisig_did<br/>`Weight`\_proposal_weight<br/> |
| Change sigs required via creator | | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | `AccountId`multisig_account<br/>`u64`signatures_required<br/> |
| Remove creator controls | | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | `AccountId`multisig_account<br/> |

Expand Down
110 changes: 55 additions & 55 deletions app/src/substrate/substrate_dispatch_V4.c
Original file line number Diff line number Diff line change
Expand Up @@ -267,16 +267,6 @@ __Z_INLINE parser_error_t _readMethod_multisig_make_multisig_primary_V4(
return parser_ok;
}

__Z_INLINE parser_error_t _readMethod_multisig_execute_scheduled_proposal_V4(
parser_context_t* c, pd_multisig_execute_scheduled_proposal_V4_t* m)
{
CHECK_ERROR(_readAccountId(c, &m->multisig))
CHECK_ERROR(_readu64(c, &m->proposal_id))
CHECK_ERROR(_readIdentityId(c, &m->multisig_did))
CHECK_ERROR(_readWeight(c, &m->_proposal_weight))
return parser_ok;
}

__Z_INLINE parser_error_t _readMethod_staking_bond_V4(
parser_context_t* c, pd_staking_bond_V4_t* m)
{
Expand Down Expand Up @@ -1058,6 +1048,16 @@ __Z_INLINE parser_error_t _readMethod_multisig_make_multisig_secondary_V4(
return parser_ok;
}

__Z_INLINE parser_error_t _readMethod_multisig_execute_scheduled_proposal_V4(
parser_context_t* c, pd_multisig_execute_scheduled_proposal_V4_t* m)
{
CHECK_ERROR(_readAccountId(c, &m->multisig))
CHECK_ERROR(_readu64(c, &m->proposal_id))
CHECK_ERROR(_readIdentityId(c, &m->multisig_did))
CHECK_ERROR(_readWeight(c, &m->_proposal_weight))
return parser_ok;
}

__Z_INLINE parser_error_t _readMethod_multisig_change_sigs_required_via_creator_V4(
parser_context_t* c, pd_multisig_change_sigs_required_via_creator_V4_t* m)
{
Expand Down Expand Up @@ -2750,9 +2750,6 @@ parser_error_t _readMethod_V4(
case 3857: /* module 15 call 17 */
CHECK_ERROR(_readMethod_multisig_make_multisig_primary_V4(c, &method->nested.multisig_make_multisig_primary_V4))
break;
case 3858: /* module 15 call 18 */
CHECK_ERROR(_readMethod_multisig_execute_scheduled_proposal_V4(c, &method->nested.multisig_execute_scheduled_proposal_V4))
break;
case 4352: /* module 17 call 0 */
CHECK_ERROR(_readMethod_staking_bond_V4(c, &method->nested.staking_bond_V4))
break;
Expand Down Expand Up @@ -3063,6 +3060,9 @@ parser_error_t _readMethod_V4(
case 3856: /* module 15 call 16 */
CHECK_ERROR(_readMethod_multisig_make_multisig_secondary_V4(c, &method->nested.multisig_make_multisig_secondary_V4))
break;
case 3858: /* module 15 call 18 */
CHECK_ERROR(_readMethod_multisig_execute_scheduled_proposal_V4(c, &method->nested.multisig_execute_scheduled_proposal_V4))
break;
case 3859: /* module 15 call 19 */
CHECK_ERROR(_readMethod_multisig_change_sigs_required_via_creator_V4(c, &method->nested.multisig_change_sigs_required_via_creator_V4))
break;
Expand Down Expand Up @@ -3804,8 +3804,6 @@ const char* _getMethod_Name_V4(uint8_t moduleIdx, uint8_t callIdx)
return STR_ME_CHANGE_SIGS_REQUIRED;
case 3857: /* module 15 call 17 */
return STR_ME_MAKE_MULTISIG_PRIMARY;
case 3858: /* module 15 call 18 */
return STR_ME_EXECUTE_SCHEDULED_PROPOSAL;
case 4352: /* module 17 call 0 */
return STR_ME_BOND;
case 4353: /* module 17 call 1 */
Expand Down Expand Up @@ -4023,6 +4021,8 @@ const char* _getMethod_Name_V4_ParserFull(uint16_t callPrivIdx)
return STR_ME_ABDICATE_MEMBERSHIP;
case 3856: /* module 15 call 16 */
return STR_ME_MAKE_MULTISIG_SECONDARY;
case 3858: /* module 15 call 18 */
return STR_ME_EXECUTE_SCHEDULED_PROPOSAL;
case 3859: /* module 15 call 19 */
return STR_ME_CHANGE_SIGS_REQUIRED_VIA_CREATOR;
case 3860: /* module 15 call 20 */
Expand Down Expand Up @@ -4482,8 +4482,6 @@ uint8_t _getMethod_NumItems_V4(uint8_t moduleIdx, uint8_t callIdx)
return 1;
case 3857: /* module 15 call 17 */
return 2;
case 3858: /* module 15 call 18 */
return 4;
case 4352: /* module 17 call 0 */
return 3;
case 4353: /* module 17 call 1 */
Expand Down Expand Up @@ -4691,6 +4689,8 @@ uint8_t _getMethod_NumItems_V4(uint8_t moduleIdx, uint8_t callIdx)
return 0;
case 3856: /* module 15 call 16 */
return 1;
case 3858: /* module 15 call 18 */
return 4;
case 3859: /* module 15 call 19 */
return 2;
case 3860: /* module 15 call 20 */
Expand Down Expand Up @@ -5358,19 +5358,6 @@ const char* _getMethod_ItemName_V4(uint8_t moduleIdx, uint8_t callIdx, uint8_t i
default:
return NULL;
}
case 3858: /* module 15 call 18 */
switch (itemIdx) {
case 0:
return STR_IT_multisig;
case 1:
return STR_IT_proposal_id;
case 2:
return STR_IT_multisig_did;
case 3:
return STR_IT__proposal_weight;
default:
return NULL;
}
case 4352: /* module 17 call 0 */
switch (itemIdx) {
case 0:
Expand Down Expand Up @@ -6226,6 +6213,19 @@ const char* _getMethod_ItemName_V4(uint8_t moduleIdx, uint8_t callIdx, uint8_t i
default:
return NULL;
}
case 3858: /* module 15 call 18 */
switch (itemIdx) {
case 0:
return STR_IT_multisig;
case 1:
return STR_IT_proposal_id;
case 2:
return STR_IT_multisig_did;
case 3:
return STR_IT__proposal_weight;
default:
return NULL;
}
case 3859: /* module 15 call 19 */
switch (itemIdx) {
case 0:
Expand Down Expand Up @@ -8485,31 +8485,6 @@ parser_error_t _getMethod_ItemValue_V4(
default:
return parser_no_data;
}
case 3858: /* module 15 call 18 */
switch (itemIdx) {
case 0: /* multisig_execute_scheduled_proposal_V4 - multisig */;
return _toStringAccountId(
&m->nested.multisig_execute_scheduled_proposal_V4.multisig,
outValue, outValueLen,
pageIdx, pageCount);
case 1: /* multisig_execute_scheduled_proposal_V4 - proposal_id */;
return _toStringu64(
&m->nested.multisig_execute_scheduled_proposal_V4.proposal_id,
outValue, outValueLen,
pageIdx, pageCount);
case 2: /* multisig_execute_scheduled_proposal_V4 - multisig_did */;
return _toStringIdentityId(
&m->nested.multisig_execute_scheduled_proposal_V4.multisig_did,
outValue, outValueLen,
pageIdx, pageCount);
case 3: /* multisig_execute_scheduled_proposal_V4 - _proposal_weight */;
return _toStringWeight(
&m->nested.multisig_execute_scheduled_proposal_V4._proposal_weight,
outValue, outValueLen,
pageIdx, pageCount);
default:
return parser_no_data;
}
case 4352: /* module 17 call 0 */
switch (itemIdx) {
case 0: /* staking_bond_V4 - controller */;
Expand Down Expand Up @@ -9878,6 +9853,31 @@ parser_error_t _getMethod_ItemValue_V4(
default:
return parser_no_data;
}
case 3858: /* module 15 call 18 */
switch (itemIdx) {
case 0: /* multisig_execute_scheduled_proposal_V4 - multisig */;
return _toStringAccountId(
&m->nested.multisig_execute_scheduled_proposal_V4.multisig,
outValue, outValueLen,
pageIdx, pageCount);
case 1: /* multisig_execute_scheduled_proposal_V4 - proposal_id */;
return _toStringu64(
&m->nested.multisig_execute_scheduled_proposal_V4.proposal_id,
outValue, outValueLen,
pageIdx, pageCount);
case 2: /* multisig_execute_scheduled_proposal_V4 - multisig_did */;
return _toStringIdentityId(
&m->nested.multisig_execute_scheduled_proposal_V4.multisig_did,
outValue, outValueLen,
pageIdx, pageCount);
case 3: /* multisig_execute_scheduled_proposal_V4 - _proposal_weight */;
return _toStringWeight(
&m->nested.multisig_execute_scheduled_proposal_V4._proposal_weight,
outValue, outValueLen,
pageIdx, pageCount);
default:
return parser_no_data;
}
case 3859: /* module 15 call 19 */
switch (itemIdx) {
case 0: /* multisig_change_sigs_required_via_creator_V4 - multisig_account */;
Expand Down
18 changes: 9 additions & 9 deletions app/src/substrate/substrate_methods_V4.h
Original file line number Diff line number Diff line change
Expand Up @@ -962,14 +962,6 @@ typedef struct {
pd_Optionu64_t optional_cdd_auth_id;
} pd_multisig_make_multisig_primary_V4_t;

#define PD_CALL_MULTISIG_EXECUTE_SCHEDULED_PROPOSAL_V4 18
typedef struct {
pd_AccountId_t multisig;
pd_u64_t proposal_id;
pd_IdentityId_t multisig_did;
pd_Weight_t _proposal_weight;
} pd_multisig_execute_scheduled_proposal_V4_t;

#define PD_CALL_STAKING_BOND_V4 0
typedef struct {
pd_AccountIdLookupOfT_t controller;
Expand Down Expand Up @@ -1537,6 +1529,14 @@ typedef struct {
pd_AccountId_t multisig;
} pd_multisig_make_multisig_secondary_V4_t;

#define PD_CALL_MULTISIG_EXECUTE_SCHEDULED_PROPOSAL_V4 18
typedef struct {
pd_AccountId_t multisig;
pd_u64_t proposal_id;
pd_IdentityId_t multisig_did;
pd_Weight_t _proposal_weight;
} pd_multisig_execute_scheduled_proposal_V4_t;

#define PD_CALL_MULTISIG_CHANGE_SIGS_REQUIRED_VIA_CREATOR_V4 19
typedef struct {
pd_AccountId_t multisig_account;
Expand Down Expand Up @@ -2146,7 +2146,6 @@ typedef union {
pd_multisig_remove_multisig_signers_via_creator_V4_t multisig_remove_multisig_signers_via_creator_V4;
pd_multisig_change_sigs_required_V4_t multisig_change_sigs_required_V4;
pd_multisig_make_multisig_primary_V4_t multisig_make_multisig_primary_V4;
pd_multisig_execute_scheduled_proposal_V4_t multisig_execute_scheduled_proposal_V4;
pd_staking_bond_V4_t staking_bond_V4;
pd_staking_bond_extra_V4_t staking_bond_extra_V4;
pd_staking_unbond_V4_t staking_unbond_V4;
Expand Down Expand Up @@ -2252,6 +2251,7 @@ typedef union {
pd_upgradecommitteemembership_reset_members_V4_t upgradecommitteemembership_reset_members_V4;
pd_upgradecommitteemembership_abdicate_membership_V4_t upgradecommitteemembership_abdicate_membership_V4;
pd_multisig_make_multisig_secondary_V4_t multisig_make_multisig_secondary_V4;
pd_multisig_execute_scheduled_proposal_V4_t multisig_execute_scheduled_proposal_V4;
pd_multisig_change_sigs_required_via_creator_V4_t multisig_change_sigs_required_via_creator_V4;
pd_multisig_remove_creator_controls_V4_t multisig_remove_creator_controls_V4;
pd_bridge_change_controller_V4_t bridge_change_controller_V4;
Expand Down
2 changes: 1 addition & 1 deletion docs/supported_4.6003001.x.md
Original file line number Diff line number Diff line change
Expand Up @@ -177,7 +177,7 @@
| Change sigs required | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | `u64`sigs_required<br/> |
| Make multisig secondary | | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | `AccountId`multisig<br/> |
| Make multisig primary | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | `AccountId`multisig<br/>`Optionu64`optional_cdd_auth_id<br/> |
| Execute scheduled proposal | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | `AccountId`multisig<br/>`u64`proposal_id<br/>`IdentityId`multisig_did<br/>`Weight`\_proposal_weight<br/> |
| Execute scheduled proposal | | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | `AccountId`multisig<br/>`u64`proposal_id<br/>`IdentityId`multisig_did<br/>`Weight`\_proposal_weight<br/> |
| Change sigs required via creator | | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | `AccountId`multisig_account<br/>`u64`signatures_required<br/> |
| Remove creator controls | | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | `AccountId`multisig_account<br/> |

Expand Down
2 changes: 1 addition & 1 deletion docs/supported_latest.md
Original file line number Diff line number Diff line change
Expand Up @@ -177,7 +177,7 @@
| Change sigs required | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | `u64`sigs_required<br/> |
| Make multisig secondary | | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | `AccountId`multisig<br/> |
| Make multisig primary | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | `AccountId`multisig<br/>`Optionu64`optional_cdd_auth_id<br/> |
| Execute scheduled proposal | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | `AccountId`multisig<br/>`u64`proposal_id<br/>`IdentityId`multisig_did<br/>`Weight`\_proposal_weight<br/> |
| Execute scheduled proposal | | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | `AccountId`multisig<br/>`u64`proposal_id<br/>`IdentityId`multisig_did<br/>`Weight`\_proposal_weight<br/> |
| Change sigs required via creator | | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | `AccountId`multisig_account<br/>`u64`signatures_required<br/> |
| Remove creator controls | | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | `AccountId`multisig_account<br/> |

Expand Down
Loading

0 comments on commit 1d7d4a1

Please sign in to comment.