1
0
mirror of https://github.com/trezor/trezor-firmware.git synced 2024-11-22 15:38:11 +00:00
Commit Graph

75 Commits

Author SHA1 Message Date
matejcik
2aa427a6e3 feat(core/rust): make Rust buildable without Micropython
Features `micropython` and `protobuf` are defined. Protobuf implies micropython
because our protobuf impl is pretty much _for_ micropython.

The respective subdirs are included only if the matching feature is defined.

util.rs is moved to micropython because it mostly concerns micropython interop

ResultExt, useful only for ui_debug, is moved to ui::util.

A new module `trezorhal::time` is provided. It mirrors functionality of
`micropython::time` via stmlib functions.  The intended use is to always use
functions from `trezorhal::time`. The right micropython variants are used when
micropython is available, otherwise the pure stmlib versions are called.

ui::*::layout is conditional for micropython feature, because it only concerns
micropython layouts. If we want to reuse layouts defined there, we will need to
export them to not depend on Objs and Qstrs etc.
2022-06-16 13:08:07 +02:00
grdddj
feb96c84b0 chore(core/rust): use clippy for all features 2022-05-16 10:49:04 +02:00
tychovrahe
0a735ead1e build(core) - Move comments to separate lines to avoid spaces being added to the value 2022-04-13 17:26:14 +02:00
Ondrej Mikle
2ced50ed16 fix(core): update JLink command line flashing parameters
[no changelog]
2022-04-11 12:26:01 +02:00
Martin Milata
1f612580f7 feat(core): enable UI tests for redesigned UI
[no changelog]
2022-04-07 17:58:41 +02:00
matejcik
61718aff49 feat(tools): make pyright_tool more user-friendly
[no changelog]

* passed in directory respects absolute and relative paths instead of
  working "from repository root"
* we don't require the enableTypeIgnoreComments to be set so both
  `pyright` and `pyright_tool` can work with the same config at the same
  time
* use click's magic functionality to deal with missing / unreadable /
  unwriteable files
* read the error results via a pipe, do not write to filesystem unless
  requested
* simplified logic regarding "test mode"/"dev mode"
* renamed `--log` to more typical `--verbose`
* use pathlib more extensively
2022-03-23 14:55:05 +01:00
grdddj
3d505874aa feat(ci): create pyright tool and include it in CI
[no changelog]
2022-03-02 15:43:50 +01:00
matejcik
59b5f48dc1 build(core): fix echo invocation for dash 2022-02-18 11:27:23 +01:00
Martin Milata
f2b8822d76 refactor(core): improve build-time option for old/new UI
[no changelog]
2022-02-10 14:57:42 +01:00
matejcik
abc593d19a tests: drop skip_ui support 2022-02-08 16:34:54 +01:00
Martin Milata
e3541997f0 ci(core): run nightly device tests with AddressSanitizer
[no changelog]
2022-01-19 15:22:03 +01:00
matejcik
8d8cfd6692 build: fully replace mypy with pyright
[no changelog]
2022-01-07 21:41:17 +01:00
grdddj
9fc5bb546b style(core): full pyright-based type-checking
Changes many fields to required -- as far as we were able to figure out,
signing would fail if these fields aren't provided anyway, so this
should not pose a compatibility problem.

Co-authored-by: matejcik <ja@matejcik.cz>
2022-01-07 21:41:17 +01:00
Martin Milata
52f719ad81 ci: add core unit test t1
[no changelog]
2021-11-24 15:36:34 +01:00
Jan Pochyla
2703d714c2 feat(core): add Rust UI components, layouts, text rendering
[no changelog]
2021-10-07 15:01:55 +02:00
matejcik
98f0496b2c feat(core/stellar): add type checking to Stellar app 2021-09-24 10:30:19 +02:00
Martin Milata
81e66cb024 style(core/rust): enable clippy lints
[no changelog]
2021-09-23 14:22:40 +02:00
matejcik
d0efdfa715 fix(core/rust): enable "test" feature for Rust unit test 2021-09-21 12:43:31 +02:00
Martin Milata
a7a7570496 ci(core): enable rust unit tests
[no changelog]
2021-09-16 14:57:06 +02:00
matejcik
e80077e0a4 feat(core/ethereum): enable type-checking for Ethereum app 2021-09-10 15:09:03 +02:00
Martin Milata
31052007ff refactor(core): enable mypy for apps.management 2021-08-04 15:03:11 +02:00
Martin Milata
312876ab67 refactor(core): convert apps.management.reset_device to layouts 2021-08-04 15:03:11 +02:00
Pavol Rusnak
23aa69caea fix(core): unify Features.revision reporting with legacy 2021-06-04 12:50:49 +02:00
Jan Pochyla
6257584951 feat(core): Add Rust bindings to MicroPython and trezorhal
core: Remove dangling module decls

core: Use new Cargo feature resolver, use external MacOS debug info

core: Rust docs improvements

core: Upgrade bindgen

core: Add test target to Rust

ci: build rust sources

build(core): .ARM.exidx.text.__aeabi_ui2f in t1 firmware size

It's an unwind table for softfloat function inserted by rustc, probably
can be removed to save 8 bytes:
599c58db70/link.x.in (L175-L182)

scons: Remove dead code

core: Move Rust target to build/rust

core: Replace extern with a FFI version

core: Add some explanatory Rust comments

core: Use correct path for the Rust lib

core: Remove Buffer::as_mut()

Mutable buffer access needs MP_BUFFER_WRITE flag. TBD in the Protobuf PR.

core: Improve docs for micropython::Buffer

core: Minor Rust docs changes

core: Rewrite trezor_obj_get_ll_checked

core: Fix incorrect doc comment

core: Remove cc from deps

fixup! core: Rewrite trezor_obj_get_ll_checked

core: update safety comments
2021-05-05 16:00:21 +02:00
Pavol Rusnak
dfbdcf5b2b
feat(core): add support for olimex-arm-usb-tiny-h via openocd
[skip_ci]
2021-03-24 18:01:50 +01:00
Pavol Rusnak
b37e5c916f
fix(core): add missing targets to make clean
[skip_ci]
2021-03-22 22:06:29 +01:00
mcudev
b50f1e0b89 openocd: separate stlink configs deprecated - now combined 2021-03-09 11:41:55 +01:00
Ondrej Mikle
ed57320c86
build(flashing): nogui flag for flashing for newer JLink versions (#1482) 2021-02-16 14:35:06 +01:00
matejcik
bf562cfd4b feat(core/misc): enable typing for misc app 2021-02-10 10:56:52 +01:00
matejcik
ccd241fe55 feat(core/cardano): enable typing for Cardano app 2021-02-10 10:56:52 +01:00
Pavol Rusnak
c25e5daad2 chore(core): use SYSTEM_VIEW as feature flag, not make flag 2021-01-26 20:53:38 +01:00
Ondrej Mikle
b51ed55ea8 build(core): parameters for SystemView instrumentation 2021-01-26 20:53:38 +01:00
Pavol Rusnak
6508d0a3c7 refactor(core): turn RDI into a firmware feature flag 2021-01-22 14:06:29 +01:00
matejcik
fe55f0c1f0 build(core): do not regenerate resources for a mypy run 2020-11-20 18:55:35 +01:00
Martin Milata
c89a8b7bd5 ci(core): add memory profiler job 2020-11-02 14:14:00 +01:00
matejcik
d89c42e139 feat(core): add more mypy targets 2020-09-23 16:00:10 +02:00
Martin Milata
c7934116ec
core: introduce TREZOR_MODEL flag (#1233) 2020-08-28 14:50:38 +02:00
Ondrej Mikle
8d3d3be09c
core/bootloader_ic: introduce CI bootloader for TT device tests (#1182) 2020-08-21 14:39:56 +02:00
Martin Milata
71c5bc4e3b ci: fail if coverage falls under threshold 2020-08-18 21:08:46 +02:00
Pavol Rusnak
063aba910d core: rename emulator to trezor-emu-core 2020-07-30 15:27:34 +02:00
matejcik
c3a61998cb core: generate resdata by Mako, use if/elif trick to save RAM 2020-07-24 14:09:31 +02:00
Ondrej Mikle
10f0f107e0 core: Adds T1 core port FW flashing options for for openocd and jlink 2020-05-21 10:05:12 +02:00
Tomas Susanka
25d2d130a0 tests: use maxfail option for fido2 tests 2020-05-12 09:48:23 +00:00
Tomas Susanka
53c43ac305 core/tests: initialize emu with slip14 before running fido2 test suite 2020-05-06 14:36:04 +00:00
Ondřej Vejpustek
c461692f3a core: implement random delay interrupts 2020-04-16 11:51:28 +02:00
Ondrej Mikle
634ed5aabc
core: commands for flashing via JLink (#911) 2020-03-23 10:40:06 +01:00
Tomas Susanka
577daf09fe tests: introduce --ui-check-missing to test/remove missing tests 2020-02-18 09:33:21 +01:00
matejcik
741c0c8888 core: improve stability of Monero test runner 2020-02-11 11:16:28 +01:00
matejcik
5d052678a6 build: make sure resources are built for 'make mypy' 2020-01-28 16:42:24 +01:00
matejcik
6cf48bf485 ci: use explicit trezor.log location 2020-01-23 18:43:20 +01:00