Skip to content
This repository was archived by the owner on Nov 30, 2022. It is now read-only.

Commit aece2e8

Browse files
committed
remove config files
1 parent 43cc8eb commit aece2e8

File tree

8 files changed

+23
-132
lines changed

8 files changed

+23
-132
lines changed

.github/workflows/embedded.yml

-23
This file was deleted.

.github/workflows/rust.yml

+18
Original file line numberDiff line numberDiff line change
@@ -80,3 +80,21 @@ jobs:
8080
DO_FEATURE_MATRIX: true
8181
run: ./contrib/test.sh
8282

83+
Embedded:
84+
runs-on: ubuntu-latest
85+
steps:
86+
- name: Checkout
87+
uses: actions/checkout@v2
88+
- name: Checkout Toolchain
89+
uses: actions-rs/toolchain@v1
90+
with:
91+
profile: minimal
92+
toolchain: stable
93+
override: true
94+
components: rust-src
95+
target: thumbv7m-none-eabi
96+
- name: Build
97+
env:
98+
RUSTFLAGS: "-C link-arg=-Tlink.x"
99+
run: cd embedded && cargo build --target thumbv7m-none-eabi
100+

.gitignore

+3
Original file line numberDiff line numberDiff line change
@@ -8,4 +8,7 @@ Cargo.lock
88
fuzz/hfuzz_target
99
fuzz/hfuzz_workspace
1010

11+
#embedded
12+
embedded/.cargo
13+
1114
*~

embedded/.cargo/config

-26
This file was deleted.

embedded/Cargo.toml

-14
Original file line numberDiff line numberDiff line change
@@ -12,20 +12,6 @@ cortex-m-semihosting = "0.3.3"
1212
panic-halt = "0.2.0"
1313
bitcoin_hashes = { path="../", default-features = false }
1414

15-
# Uncomment for the panic example.
16-
# panic-itm = "0.4.1"
17-
18-
# Uncomment for the allocator example.
19-
# alloc-cortex-m = "0.4.0"
20-
21-
# Uncomment for the device example.
22-
# Update `memory.x`, set target to `thumbv7em-none-eabihf` in `.cargo/config`,
23-
# and then use `cargo build --examples device` to build it.
24-
# [dependencies.stm32f3]
25-
# features = ["stm32f303", "rt"]
26-
# version = "0.7.1"
27-
28-
# this lets you use `cargo fix`!
2915
[[bin]]
3016
name = "embedded"
3117
test = false

embedded/build.rs

-31
This file was deleted.

embedded/memory.x

-29
Original file line numberDiff line numberDiff line change
@@ -1,34 +1,5 @@
11
MEMORY
22
{
3-
/* NOTE 1 K = 1 KiBi = 1024 bytes */
4-
/* TODO Adjust these memory regions to match your device memory layout */
5-
/* These values correspond to the LM3S6965, one of the few devices QEMU can emulate */
63
FLASH : ORIGIN = 0x00000000, LENGTH = 256K
74
RAM : ORIGIN = 0x20000000, LENGTH = 64K
85
}
9-
10-
/* This is where the call stack will be allocated. */
11-
/* The stack is of the full descending type. */
12-
/* You may want to use this variable to locate the call stack and static
13-
variables in different memory regions. Below is shown the default value */
14-
/* _stack_start = ORIGIN(RAM) + LENGTH(RAM); */
15-
16-
/* You can use this symbol to customize the location of the .text section */
17-
/* If omitted the .text section will be placed right after the .vector_table
18-
section */
19-
/* This is required only on microcontrollers that store some configuration right
20-
after the vector table */
21-
/* _stext = ORIGIN(FLASH) + 0x400; */
22-
23-
/* Example of putting non-initialized variables into custom RAM locations. */
24-
/* This assumes you have defined a region RAM2 above, and in the Rust
25-
sources added the attribute `#[link_section = ".ram2bss"]` to the data
26-
you want to place there. */
27-
/* Note that the section will not be zero-initialized by the runtime! */
28-
/* SECTIONS {
29-
.ram2bss (NOLOAD) : ALIGN(4) {
30-
*(.ram2bss);
31-
. = ALIGN(4);
32-
} > RAM2
33-
} INSERT AFTER .bss;
34-
*/

embedded/src/main.rs

+2-9
Original file line numberDiff line numberDiff line change
@@ -4,12 +4,7 @@
44
#[macro_use]
55
extern crate bitcoin_hashes;
66

7-
// pick a panicking behavior
8-
use panic_halt as _; // you can put a breakpoint on `rust_begin_unwind` to catch panics
9-
// use panic_abort as _; // requires nightly
10-
// use panic_itm as _; // logs messages over ITM; requires ITM support
11-
// use panic_semihosting as _; // logs messages to the host stderr; requires a debugger
12-
7+
use panic_halt as _;
138
use cortex_m_rt::entry;
149
use cortex_m_semihosting::{debug, hprintln};
1510
use bitcoin_hashes::sha256;
@@ -23,7 +18,5 @@ fn main() -> ! {
2318

2419
debug::exit(debug::EXIT_SUCCESS);
2520

26-
loop {
27-
// your code goes here
28-
}
21+
loop {}
2922
}

0 commit comments

Comments
 (0)