diff --git a/ssd1306/ssd1306.go b/ssd1306/ssd1306.go index f98e616..2900cd8 100644 --- a/ssd1306/ssd1306.go +++ b/ssd1306/ssd1306.go @@ -104,8 +104,12 @@ func (o *OLED) SetPixel(x, y int, v byte) error { if v > 1 { return fmt.Errorf("value needs to be either 0 or 1; given %v", v) } - i := x + (y/8)*o.w + 1 - o.buf[i] = o.buf[i] | v<