something is still wrong
All checks were successful
Rust/va108xx-rs/pipeline/pr-main This commit looks good
All checks were successful
Rust/va108xx-rs/pipeline/pr-main This commit looks good
This commit is contained in:
parent
52f5d42358
commit
0f3614465f
@ -22,8 +22,8 @@ codegen-units = 1
|
|||||||
debug = 2
|
debug = 2
|
||||||
debug-assertions = true # <-
|
debug-assertions = true # <-
|
||||||
incremental = false
|
incremental = false
|
||||||
# This is problematic for stepping..
|
# 1 instead of 0, the flashloader is too larger otherwise..
|
||||||
# opt-level = 'z' # <-
|
# opt-level = 1 # <-
|
||||||
overflow-checks = true # <-
|
overflow-checks = true # <-
|
||||||
|
|
||||||
# cargo build/run --release
|
# cargo build/run --release
|
||||||
|
@ -7,8 +7,6 @@ edition = "2021"
|
|||||||
cortex-m = "0.7"
|
cortex-m = "0.7"
|
||||||
cortex-m-rt = "0.7"
|
cortex-m-rt = "0.7"
|
||||||
embedded-hal = "1"
|
embedded-hal = "1"
|
||||||
embedded-hal-bus = "0.2"
|
|
||||||
dummy-pin = "1"
|
|
||||||
panic-rtt-target = { version = "0.1.3" }
|
panic-rtt-target = { version = "0.1.3" }
|
||||||
panic-halt = { version = "0.2" }
|
panic-halt = { version = "0.2" }
|
||||||
rtt-target = { version = "0.5" }
|
rtt-target = { version = "0.5" }
|
||||||
|
@ -26,8 +26,8 @@ BAUD_RATE = 115200
|
|||||||
|
|
||||||
BOOTLOADER_START_ADDR = 0x0
|
BOOTLOADER_START_ADDR = 0x0
|
||||||
BOOTLOADER_END_ADDR = 0x3000
|
BOOTLOADER_END_ADDR = 0x3000
|
||||||
BOOTLOADER_CRC_ADDR = BOOTLOADER_END_ADDR - 4
|
BOOTLOADER_CRC_ADDR = BOOTLOADER_END_ADDR - 2
|
||||||
BOOTLOADER_MAX_SIZE = BOOTLOADER_END_ADDR - BOOTLOADER_START_ADDR - 4
|
BOOTLOADER_MAX_SIZE = BOOTLOADER_END_ADDR - BOOTLOADER_START_ADDR - 2
|
||||||
|
|
||||||
APP_A_START_ADDR = 0x3000
|
APP_A_START_ADDR = 0x3000
|
||||||
APP_A_END_ADDR = 0x11800
|
APP_A_END_ADDR = 0x11800
|
||||||
@ -209,7 +209,7 @@ class ImageLoader:
|
|||||||
# Blank the checksum. For the bootloader, the bootloader will calculate the
|
# Blank the checksum. For the bootloader, the bootloader will calculate the
|
||||||
# checksum itself on the initial run.
|
# checksum itself on the initial run.
|
||||||
checksum_write_packet = pack_memory_write_command(
|
checksum_write_packet = pack_memory_write_command(
|
||||||
BOOTLOADER_CRC_ADDR, bytes([0x00, 0x00, 0x00, 0x00])
|
BOOTLOADER_CRC_ADDR, bytes([0x00, 0x00])
|
||||||
)
|
)
|
||||||
self.send_tc(checksum_write_packet)
|
self.send_tc(checksum_write_packet)
|
||||||
else:
|
else:
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
/* Special linker script for application slot A with an offset at address 0x3000 */
|
/* Special linker script for application slot A with an offset at address 0x3000 */
|
||||||
MEMORY
|
MEMORY
|
||||||
{
|
{
|
||||||
FLASH : ORIGIN = 0x00000000, LENGTH = 0x3000 /* 128K */
|
FLASH : ORIGIN = 0x00003000, LENGTH = 0x20000 /* 128K */
|
||||||
RAM : ORIGIN = 0x10000000, LENGTH = 0x08000 /* 32K */
|
RAM : ORIGIN = 0x10000000, LENGTH = 0x08000 /* 32K */
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
/* Special linker script for application slot B with an offset at address 0x11800 */
|
/* Special linker script for application slot B with an offset at address 0x11800 */
|
||||||
MEMORY
|
MEMORY
|
||||||
{
|
{
|
||||||
FLASH : ORIGIN = 0x00000000, LENGTH = 0x11800 /* 128K */
|
FLASH : ORIGIN = 0x00011800, LENGTH = 0x20000 /* 128K */
|
||||||
RAM : ORIGIN = 0x10000000, LENGTH = 0x08000 /* 32K */
|
RAM : ORIGIN = 0x10000000, LENGTH = 0x08000 /* 32K */
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -110,7 +110,7 @@ mod app {
|
|||||||
tm_prod: DataProducer<BUF_RB_SIZE_TM, SIZES_RB_SIZE_TM>,
|
tm_prod: DataProducer<BUF_RB_SIZE_TM, SIZES_RB_SIZE_TM>,
|
||||||
}
|
}
|
||||||
|
|
||||||
rtic_monotonics::systick_monotonic!(Mono, 10_000);
|
rtic_monotonics::systick_monotonic!(Mono, 1000);
|
||||||
|
|
||||||
#[init]
|
#[init]
|
||||||
fn init(cx: init::Context) -> (Shared, Local) {
|
fn init(cx: init::Context) -> (Shared, Local) {
|
||||||
@ -134,7 +134,7 @@ mod app {
|
|||||||
UART_BAUDRATE.Hz(),
|
UART_BAUDRATE.Hz(),
|
||||||
);
|
);
|
||||||
let (tx, rx) = irq_uart.split();
|
let (tx, rx) = irq_uart.split();
|
||||||
let mut rx = rx.into_rx_with_irq(&mut dp.sysconfig, &mut dp.irqsel, pac::interrupt::OC3);
|
let mut rx = rx.into_rx_with_irq(&mut dp.sysconfig, &mut dp.irqsel, pac::interrupt::OC0);
|
||||||
|
|
||||||
let verif_reporter = VerificationReportCreator::new(0).unwrap();
|
let verif_reporter = VerificationReportCreator::new(0).unwrap();
|
||||||
|
|
||||||
|
@ -451,5 +451,53 @@
|
|||||||
]
|
]
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"type": "cortex-debug",
|
||||||
|
"request": "launch",
|
||||||
|
"name": "Bootloader",
|
||||||
|
"servertype": "jlink",
|
||||||
|
"cwd": "${workspaceRoot}",
|
||||||
|
"device": "Cortex-M0",
|
||||||
|
"svdFile": "./va108xx/svd/va108xx.svd.patched",
|
||||||
|
"preLaunchTask": "bootloader",
|
||||||
|
"executable": "${workspaceFolder}/target/thumbv6m-none-eabi/debug/bootloader",
|
||||||
|
"interface": "jtag",
|
||||||
|
"runToEntryPoint": "main",
|
||||||
|
"rttConfig": {
|
||||||
|
"enabled": true,
|
||||||
|
"address": "auto",
|
||||||
|
"decoders": [
|
||||||
|
{
|
||||||
|
"port": 0,
|
||||||
|
"timestamp": true,
|
||||||
|
"type": "console"
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"type": "cortex-debug",
|
||||||
|
"request": "launch",
|
||||||
|
"name": "Flashloader",
|
||||||
|
"servertype": "jlink",
|
||||||
|
"cwd": "${workspaceRoot}",
|
||||||
|
"device": "Cortex-M0",
|
||||||
|
"svdFile": "./va108xx/svd/va108xx.svd.patched",
|
||||||
|
"preLaunchTask": "flashloader",
|
||||||
|
"executable": "${workspaceFolder}/target/thumbv6m-none-eabi/debug/flashloader",
|
||||||
|
"interface": "jtag",
|
||||||
|
"runToEntryPoint": "main",
|
||||||
|
"rttConfig": {
|
||||||
|
"enabled": true,
|
||||||
|
"address": "auto",
|
||||||
|
"decoders": [
|
||||||
|
{
|
||||||
|
"port": 0,
|
||||||
|
"timestamp": true,
|
||||||
|
"type": "console"
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
},
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
|
@ -7,9 +7,7 @@
|
|||||||
"label": "rust: cargo build",
|
"label": "rust: cargo build",
|
||||||
"type": "shell",
|
"type": "shell",
|
||||||
"command": "~/.cargo/bin/cargo", // note: full path to the cargo
|
"command": "~/.cargo/bin/cargo", // note: full path to the cargo
|
||||||
"args": [
|
"args": ["build"],
|
||||||
"build"
|
|
||||||
],
|
|
||||||
"group": {
|
"group": {
|
||||||
"kind": "build",
|
"kind": "build",
|
||||||
"isDefault": true
|
"isDefault": true
|
||||||
@ -19,13 +17,7 @@
|
|||||||
"label": "rust: cargo build hal tests",
|
"label": "rust: cargo build hal tests",
|
||||||
"type": "shell",
|
"type": "shell",
|
||||||
"command": "~/.cargo/bin/cargo", // note: full path to the cargo
|
"command": "~/.cargo/bin/cargo", // note: full path to the cargo
|
||||||
"args": [
|
"args": ["build", "--bin", "board-tests", "--features", "rt"],
|
||||||
"build",
|
|
||||||
"--bin",
|
|
||||||
"board-tests",
|
|
||||||
"--features",
|
|
||||||
"rt"
|
|
||||||
],
|
|
||||||
"group": {
|
"group": {
|
||||||
"kind": "build",
|
"kind": "build",
|
||||||
"isDefault": true
|
"isDefault": true
|
||||||
@ -35,11 +27,7 @@
|
|||||||
"label": "rust: cargo build rtt",
|
"label": "rust: cargo build rtt",
|
||||||
"type": "shell",
|
"type": "shell",
|
||||||
"command": "~/.cargo/bin/cargo", // note: full path to the cargo
|
"command": "~/.cargo/bin/cargo", // note: full path to the cargo
|
||||||
"args": [
|
"args": ["build", "--example", "rtt-log"],
|
||||||
"build",
|
|
||||||
"--example",
|
|
||||||
"rtt-log",
|
|
||||||
],
|
|
||||||
"group": {
|
"group": {
|
||||||
"kind": "build",
|
"kind": "build",
|
||||||
"isDefault": true
|
"isDefault": true
|
||||||
@ -49,13 +37,7 @@
|
|||||||
"label": "rust: cargo build systick",
|
"label": "rust: cargo build systick",
|
||||||
"type": "shell",
|
"type": "shell",
|
||||||
"command": "~/.cargo/bin/cargo", // note: full path to the cargo
|
"command": "~/.cargo/bin/cargo", // note: full path to the cargo
|
||||||
"args": [
|
"args": ["build", "--example", "timer-ticks", "--features", "rt"],
|
||||||
"build",
|
|
||||||
"--example",
|
|
||||||
"timer-ticks",
|
|
||||||
"--features",
|
|
||||||
"rt"
|
|
||||||
],
|
|
||||||
"group": {
|
"group": {
|
||||||
"kind": "build",
|
"kind": "build",
|
||||||
"isDefault": true
|
"isDefault": true
|
||||||
@ -65,11 +47,7 @@
|
|||||||
"label": "rust: cargo build uart",
|
"label": "rust: cargo build uart",
|
||||||
"type": "shell",
|
"type": "shell",
|
||||||
"command": "~/.cargo/bin/cargo", // note: full path to the cargo
|
"command": "~/.cargo/bin/cargo", // note: full path to the cargo
|
||||||
"args": [
|
"args": ["build", "--example", "uart"],
|
||||||
"build",
|
|
||||||
"--example",
|
|
||||||
"uart",
|
|
||||||
],
|
|
||||||
"group": {
|
"group": {
|
||||||
"kind": "build",
|
"kind": "build",
|
||||||
"isDefault": true
|
"isDefault": true
|
||||||
@ -79,11 +57,7 @@
|
|||||||
"label": "rust: cargo build spi",
|
"label": "rust: cargo build spi",
|
||||||
"type": "shell",
|
"type": "shell",
|
||||||
"command": "~/.cargo/bin/cargo", // note: full path to the cargo
|
"command": "~/.cargo/bin/cargo", // note: full path to the cargo
|
||||||
"args": [
|
"args": ["build", "--example", "spi"],
|
||||||
"build",
|
|
||||||
"--example",
|
|
||||||
"spi",
|
|
||||||
],
|
|
||||||
"group": {
|
"group": {
|
||||||
"kind": "build",
|
"kind": "build",
|
||||||
"isDefault": true
|
"isDefault": true
|
||||||
@ -93,13 +67,7 @@
|
|||||||
"label": "rust: cargo build pwm",
|
"label": "rust: cargo build pwm",
|
||||||
"type": "shell",
|
"type": "shell",
|
||||||
"command": "~/.cargo/bin/cargo", // note: full path to the cargo
|
"command": "~/.cargo/bin/cargo", // note: full path to the cargo
|
||||||
"args": [
|
"args": ["build", "--example", "pwm", "--features", "rt"],
|
||||||
"build",
|
|
||||||
"--example",
|
|
||||||
"pwm",
|
|
||||||
"--features",
|
|
||||||
"rt"
|
|
||||||
],
|
|
||||||
"group": {
|
"group": {
|
||||||
"kind": "build",
|
"kind": "build",
|
||||||
"isDefault": true
|
"isDefault": true
|
||||||
@ -109,13 +77,7 @@
|
|||||||
"label": "rust: cargo build cascade",
|
"label": "rust: cargo build cascade",
|
||||||
"type": "shell",
|
"type": "shell",
|
||||||
"command": "~/.cargo/bin/cargo", // note: full path to the cargo
|
"command": "~/.cargo/bin/cargo", // note: full path to the cargo
|
||||||
"args": [
|
"args": ["build", "--example", "cascade", "--features", "rt"],
|
||||||
"build",
|
|
||||||
"--example",
|
|
||||||
"cascade",
|
|
||||||
"--features",
|
|
||||||
"rt"
|
|
||||||
],
|
|
||||||
"group": {
|
"group": {
|
||||||
"kind": "build",
|
"kind": "build",
|
||||||
"isDefault": true
|
"isDefault": true
|
||||||
@ -125,11 +87,7 @@
|
|||||||
"label": "uart-echo-rtic-example",
|
"label": "uart-echo-rtic-example",
|
||||||
"type": "shell",
|
"type": "shell",
|
||||||
"command": "~/.cargo/bin/cargo", // note: full path to the cargo
|
"command": "~/.cargo/bin/cargo", // note: full path to the cargo
|
||||||
"args": [
|
"args": ["build", "--bin", "uart-echo-rtic"],
|
||||||
"build",
|
|
||||||
"--bin",
|
|
||||||
"uart-echo-rtic",
|
|
||||||
],
|
|
||||||
"group": {
|
"group": {
|
||||||
"kind": "build",
|
"kind": "build",
|
||||||
"isDefault": true
|
"isDefault": true
|
||||||
@ -139,24 +97,16 @@
|
|||||||
"label": "blinky-hal",
|
"label": "blinky-hal",
|
||||||
"type": "shell",
|
"type": "shell",
|
||||||
"command": "~/.cargo/bin/cargo", // note: full path to the cargo
|
"command": "~/.cargo/bin/cargo", // note: full path to the cargo
|
||||||
"args": [
|
"args": ["build", "--example", "blinky"],
|
||||||
"build",
|
|
||||||
"--example",
|
|
||||||
"blinky",
|
|
||||||
],
|
|
||||||
"group": {
|
"group": {
|
||||||
"kind": "build",
|
"kind": "build"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"label": "rust: cargo build led blinky",
|
"label": "rust: cargo build led blinky",
|
||||||
"type": "shell",
|
"type": "shell",
|
||||||
"command": "~/.cargo/bin/cargo", // note: full path to the cargo
|
"command": "~/.cargo/bin/cargo", // note: full path to the cargo
|
||||||
"args": [
|
"args": ["build", "--example", "blinky-leds"],
|
||||||
"build",
|
|
||||||
"--example",
|
|
||||||
"blinky-leds",
|
|
||||||
],
|
|
||||||
"group": {
|
"group": {
|
||||||
"kind": "build",
|
"kind": "build",
|
||||||
"isDefault": true
|
"isDefault": true
|
||||||
@ -166,11 +116,7 @@
|
|||||||
"label": "rust: cargo build button blinky",
|
"label": "rust: cargo build button blinky",
|
||||||
"type": "shell",
|
"type": "shell",
|
||||||
"command": "~/.cargo/bin/cargo", // note: full path to the cargo
|
"command": "~/.cargo/bin/cargo", // note: full path to the cargo
|
||||||
"args": [
|
"args": ["build", "--example", "blinky-button-irq"],
|
||||||
"build",
|
|
||||||
"--example",
|
|
||||||
"blinky-button-irq",
|
|
||||||
],
|
|
||||||
"group": {
|
"group": {
|
||||||
"kind": "build",
|
"kind": "build",
|
||||||
"isDefault": true
|
"isDefault": true
|
||||||
@ -180,11 +126,7 @@
|
|||||||
"label": "rust: cargo build temp sensor",
|
"label": "rust: cargo build temp sensor",
|
||||||
"type": "shell",
|
"type": "shell",
|
||||||
"command": "~/.cargo/bin/cargo", // note: full path to the cargo
|
"command": "~/.cargo/bin/cargo", // note: full path to the cargo
|
||||||
"args": [
|
"args": ["build", "--example", "adt75-temp-sensor"],
|
||||||
"build",
|
|
||||||
"--example",
|
|
||||||
"adt75-temp-sensor",
|
|
||||||
],
|
|
||||||
"group": {
|
"group": {
|
||||||
"kind": "build",
|
"kind": "build",
|
||||||
"isDefault": true
|
"isDefault": true
|
||||||
@ -194,11 +136,7 @@
|
|||||||
"label": "rust: cargo build button blinky rtic",
|
"label": "rust: cargo build button blinky rtic",
|
||||||
"type": "shell",
|
"type": "shell",
|
||||||
"command": "~/.cargo/bin/cargo", // note: full path to the cargo
|
"command": "~/.cargo/bin/cargo", // note: full path to the cargo
|
||||||
"args": [
|
"args": ["build", "--example", "blinky-button-rtic"],
|
||||||
"build",
|
|
||||||
"--example",
|
|
||||||
"blinky-button-rtic",
|
|
||||||
],
|
|
||||||
"group": {
|
"group": {
|
||||||
"kind": "build",
|
"kind": "build",
|
||||||
"isDefault": true
|
"isDefault": true
|
||||||
@ -208,11 +146,7 @@
|
|||||||
"label": "rust: cargo build accelerometer",
|
"label": "rust: cargo build accelerometer",
|
||||||
"type": "shell",
|
"type": "shell",
|
||||||
"command": "~/.cargo/bin/cargo", // note: full path to the cargo
|
"command": "~/.cargo/bin/cargo", // note: full path to the cargo
|
||||||
"args": [
|
"args": ["build", "--example", "adxl343-accelerometer"],
|
||||||
"build",
|
|
||||||
"--example",
|
|
||||||
"adxl343-accelerometer"
|
|
||||||
],
|
|
||||||
"group": {
|
"group": {
|
||||||
"kind": "build",
|
"kind": "build",
|
||||||
"isDefault": true
|
"isDefault": true
|
||||||
@ -222,11 +156,7 @@
|
|||||||
"label": "rust: cargo build adc",
|
"label": "rust: cargo build adc",
|
||||||
"type": "shell",
|
"type": "shell",
|
||||||
"command": "~/.cargo/bin/cargo", // note: full path to the cargo
|
"command": "~/.cargo/bin/cargo", // note: full path to the cargo
|
||||||
"args": [
|
"args": ["build", "--example", "max11619-adc"],
|
||||||
"build",
|
|
||||||
"--example",
|
|
||||||
"max11619-adc",
|
|
||||||
],
|
|
||||||
"group": {
|
"group": {
|
||||||
"kind": "build",
|
"kind": "build",
|
||||||
"isDefault": true
|
"isDefault": true
|
||||||
@ -236,11 +166,7 @@
|
|||||||
"label": "reb1-nvm",
|
"label": "reb1-nvm",
|
||||||
"type": "shell",
|
"type": "shell",
|
||||||
"command": "~/.cargo/bin/cargo", // note: full path to the cargo
|
"command": "~/.cargo/bin/cargo", // note: full path to the cargo
|
||||||
"args": [
|
"args": ["build", "--example", "nvm"],
|
||||||
"build",
|
|
||||||
"--example",
|
|
||||||
"nvm",
|
|
||||||
],
|
|
||||||
"group": {
|
"group": {
|
||||||
"kind": "build",
|
"kind": "build",
|
||||||
"isDefault": true
|
"isDefault": true
|
||||||
@ -250,21 +176,25 @@
|
|||||||
"label": "rtic-example",
|
"label": "rtic-example",
|
||||||
"type": "shell",
|
"type": "shell",
|
||||||
"command": "~/.cargo/bin/cargo", // note: full path to the cargo
|
"command": "~/.cargo/bin/cargo", // note: full path to the cargo
|
||||||
"args": [
|
"args": ["build", "--bin", "rtic-example"]
|
||||||
"build",
|
|
||||||
"--bin",
|
|
||||||
"rtic-example",
|
|
||||||
],
|
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"label": "embassy-example",
|
"label": "embassy-example",
|
||||||
"type": "shell",
|
"type": "shell",
|
||||||
"command": "~/.cargo/bin/cargo", // note: full path to the cargo
|
"command": "~/.cargo/bin/cargo", // note: full path to the cargo
|
||||||
"args": [
|
"args": ["build", "--bin", "embassy-example"]
|
||||||
"build",
|
|
||||||
"--bin",
|
|
||||||
"embassy-example",
|
|
||||||
],
|
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"label": "bootloader",
|
||||||
|
"type": "shell",
|
||||||
|
"command": "~/.cargo/bin/cargo", // note: full path to the cargo
|
||||||
|
"args": ["build", "--bin", "bootloader"]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"label": "flashloader",
|
||||||
|
"type": "shell",
|
||||||
|
"command": "~/.cargo/bin/cargo", // note: full path to the cargo
|
||||||
|
"args": ["build", "--bin", "flashloader"]
|
||||||
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user