-
Notifications
You must be signed in to change notification settings - Fork 8
Expand file tree
/
Copy pathCargo.toml
More file actions
89 lines (79 loc) · 2.74 KB
/
Cargo.toml
File metadata and controls
89 lines (79 loc) · 2.74 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
cargo-features = ["resolver"]
[package]
name = "riskeyboard70"
version = "0.1.0"
authors = ["Riskable <riskable@youknowwhat.com>"]
edition = "2018"
description = "Keyboard firmware for hall effect switches (stm32f4xx)"
license = "Apache-2.0"
readme = "README.md"
categories = ["embedded", "no-std"]
keywords = ["keyboard", "firmware", "blackpill"]
exclude = [
".gitignore",
"target/*"
]
[features]
# All features enabled by default (for now)
default = ["ws2812"]
ws2812 = []
# This is necessary because there's a bug in Cargo's resolver where if a
# single dev-dependency needs std it'll try to build *all* packages of
# the same name (serde) with std too. Using the v2 resolver fixes that bug:
[workspace]
resolver = "2"
[dependencies]
nb = "1.0"
analog-multiplexer = "1.0"
embedded-hal = "0.2"
panic-halt = "0.2"
cortex-m = "0.7"
cortex-m-rtic = "0.5"
cortex-m-rt = { version = "0.7", features = ["device"] }
# keyberon = { path = "/home/riskable/workspace/rust/embedded/keyberon", version = "0.2" }
keyberon = { git = "https://github.com/riskable/keyberon", version = "0.2"}
usb-device = { version = "0.2", features = ["control-buffer-256"] }
usbd-hid = "0.5"
# usbd-hid = { path = "/home/riskable/workspace/rust/embedded/usbd-hid", version = "0.4" }
usbd-serial = "0.1"
arraydeque = { version = "0.4", default-features = false}
heapless = "0.7"
numtoa = "0.2"
num-format = { version = "0.4", default-features = false }
smart-leds = "0.3"
ws2812-spi = { version = "0.4", features = [] }
max7219 = "0.3"
font8x8 = { version = "0.3", default-features = false, features = ["unicode"] }
# infrared = { git = "https://github.com/jkristell/infrared.git", branch = "next" }
infrared = { git = "https://github.com/jkristell/infrared.git", branch = "master" }
# infrared = "0.12"
serde = { version = "1.0", default-features = false, features = ["derive"] }
serde-json-core = { version = "0.4", default-features = false }
spi-memory = "0.2"
[dependencies.rtt-target]
version = "0.3"
features = ["cortex-m"]
[dependencies.stm32f4xx-hal]
version = "0.9"
features = ["rt", "stm32f401", "usb_fs"]
# My version that fixes the spi writes latching bug:
# [dependencies.stm32f4xx-hal]
# path = "/home/riskable/workspace/rust/embedded/stm32f4xx-hal"
# version = "0.8"
# features = ["rt", "stm32f411", "usb_fs"]
[build-dependencies]
heapless = "0.7"
num-format = { version = "0.4", default-features = false }
serde = { version = "1.0", features = ["derive"] }
toml = "0.5"
chrono = "0.4"
[profile.dev]
opt-level = 1
codegen-units = 16
debug = true
lto = false
[profile.release]
opt-level = "s" # optimize for size
codegen-units = 1 # better optimizations
debug = true # symbols are nice and they don't increase the size on Flash
lto = true # better optimizations