Skip to content

Commit

Permalink
Update neotrellis
Browse files Browse the repository at this point in the history
  • Loading branch information
alexeden committed Feb 6, 2025
1 parent b8e13e0 commit 255b46b
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 6 deletions.
2 changes: 1 addition & 1 deletion examples/neotrellis_ripples.rs
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@ fn main() -> ! {

// Update neopixels
trellis
.set_neopixel_colors_new(&matrix)
.set_neopixel_colors(&matrix)
.and_then(|_| trellis.sync_neopixel())
.expect("Failed to update neopixels");
}
Expand Down
11 changes: 6 additions & 5 deletions src/devices/neotrellis.rs
Original file line number Diff line number Diff line change
Expand Up @@ -38,10 +38,11 @@ impl<D: Driver> NeoTrellis<D> {
&mut self,
x: u8,
y: u8,
r: u8,
g: u8,
b: u8,
) -> Result<(), SeesawError<D::Error>> {
self.set_nth_neopixel_color((y * Self::NUM_COLS + x).into(), r, g, b)
color: NeoTrellisColor,
) -> Result<(), SeesawError<D::Error>>
where
[(); 2 + Self::C_SIZE]: Sized,
{
self.set_nth_neopixel_color((y * Self::NUM_COLS + x).into(), color)
}
}

0 comments on commit 255b46b

Please sign in to comment.