Skip to content

Commit

Permalink
update rumcake revision
Browse files Browse the repository at this point in the history
  • Loading branch information
Univa committed Mar 1, 2024
1 parent d5b828d commit fce9972
Show file tree
Hide file tree
Showing 5 changed files with 12 additions and 15 deletions.
2 changes: 1 addition & 1 deletion rumcake-basic-template/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ cortex-m = { version = "0.7.6", features = ["critical-section-single-core"] }
cortex-m-rt = "0.7.0"
embassy-executor = { git = "https://github.com/embassy-rs/embassy", rev = "7703f47" }

rumcake = { git = "https://github.com/Univa/rumcake", rev = "d05cf7b", features = ["usb", "stm32f303cb", "drivers", "vial", "underglow"] }
rumcake = { git = "https://github.com/Univa/rumcake", rev = "87fbf6c", features = ["usb", "stm32f303cb", "drivers", "vial", "underglow"] }

[build-dependencies]
rust-lzma = "0.6.0"
Expand Down
17 changes: 8 additions & 9 deletions rumcake-basic-template/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -86,20 +86,19 @@ impl USBKeyboard for {{ keyboard-name }} {
const USB_PID: u16 = 0x0000; // TODO:: Change this
}

// Storage configuration, uncomment after enabling the `storage` feature flag
// use rumcake::storage::StorageDevice;
// impl StorageDevice for {{ keyboard-name }} {}

// Via configuration
// Note: since the `storage` feature flag is not enabled, changes to your keyboard in the Vial app will not be saved. If you use `storage`, be sure to update memory.x.
use rumcake::via::ViaKeyboard;
impl ViaKeyboard for {{ keyboard-name }} {
// Uncomment if using `storage`
// rumcake::setup_via_storage_buffers!({{ keyboard-name }});
}
impl ViaKeyboard for {{ keyboard-name }} {}
use rumcake::vial::VialKeyboard;
impl VialKeyboard for {{ keyboard-name }} {
const VIAL_KEYBOARD_UID: [u8; 8] = [0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00]; // TODO: Change this
const VIAL_UNLOCK_COMBO: &'static [(u8, u8)] = &[(0, 0)]; // TODO: Change this
const KEYBOARD_DEFINITION: &'static [u8] = &GENERATED_KEYBOARD_DEFINITION;
// Uncomment if using `storage`
// rumcake::setup_vial_storage_buffers!({{ keyboard-name }});
}

// Underglow configuration + driver
Expand All @@ -108,8 +107,8 @@ use rumcake::underglow::UnderglowDevice;
impl UnderglowDevice for {{ keyboard-name }} {
const NUM_LEDS: usize = 18; // TODO: Change this
}
use rumcake::drivers::ws2812_bitbang::underglow::WS2812BitbangUnderglowDriver;
impl WS2812BitbangUnderglowDriver for {{ keyboard-name }} {
ws2812_pin! { PA10 } // TODO: Change this
use rumcake::drivers::ws2812_bitbang::ws2812_bitbang_pin;
impl WS2812BitbangDriverSettings for {{ keyboard-name }} {
ws2812_bitbang_pin! { PA10 } // TODO: Change this
}

2 changes: 1 addition & 1 deletion rumcake-split-template/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ cortex-m = { version = "0.7.6" }
cortex-m-rt = "0.7.0"
embassy-executor = { git = "https://github.com/embassy-rs/embassy", rev = "7703f47" }

rumcake = { git = "https://github.com/Univa/rumcake", rev = "d05cf7b", features = ["nrf52840", "drivers", "nrf-ble"] }
rumcake = { git = "https://github.com/Univa/rumcake", rev = "87fbf6c", features = ["nrf52840", "drivers", "nrf-ble"] }

[profile.dev]
debug = 2
Expand Down
3 changes: 1 addition & 2 deletions rumcake-split-template/src/left.rs
Original file line number Diff line number Diff line change
Expand Up @@ -69,8 +69,7 @@ impl BluetoothKeyboard for {{ keyboard-name }}Left {
}

// Split keyboard setup
use rumcake::drivers::nrf_ble::central::NRFBLECentralDevice;
impl NRFBLECentralDevice for {{ keyboard-name }}Left {
impl NRFBLECentralDriverSettings for {{ keyboard-name }}Left {
const PERIPHERAL_ADDRESSES: &'static [[u8; 6]] = &[[0x00, 0x00, 0x00, 0x00, 0x00, 0x00]]; // TODO: Change this, must contain the address for the right half.
}

Expand Down
3 changes: 1 addition & 2 deletions rumcake-split-template/src/right.rs
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,6 @@ impl BluetoothDevice for {{ keyboard-name }}Right {
}

// Split keyboard setup
use rumcake::drivers::nrf_ble::peripheral::NRFBLEPeripheralDevice;
impl NRFBLEPeripheralDevice for {{ keyboard-name }}Right {
impl NRFBLEPeripheralDriverSettings for {{ keyboard-name }}Right {
const CENTRAL_ADDRESS: [u8; 6] = [0x00, 0x00, 0x00, 0x00, 0x00, 0x00]; // TODO: Change this, must match the left half's BLUETOOTH_ADDRESS
}

0 comments on commit fce9972

Please sign in to comment.