You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
startColorOffset = getNewColorOffset(colorCycleLength, startColorOffset, 0); // This line is needed to condition the user's input start color offset because it could be greater than the cycle length
120
165
color_t value = getOffsetColor(data, startColorOffset);
121
166
167
+
// If value is either 0 or 1 then interpret it as a direct value...
168
+
if((uint32_t)data == 0x00){
169
+
value = (color_t)&OFF;
170
+
}
171
+
if((uint32_t)data == 0x01){
172
+
value = (color_t)&ON;
173
+
}
174
+
122
175
SSD1309_Bite_t user = *((SSD1309_Bite_t*)value);
123
176
if(user.b0){ // Check if the user's bit is set or not (this implies that the user should always set bit 0 of a 'bite' to the pixel value they want)
startColorOffset = getNewColorOffset(colorCycleLength, startColorOffset, 0); // This line is needed to condition the user's input start color offset because it could be greater than the cycle length
246
+
// color_t value = getOffsetColor(data, startColorOffset);
247
+
color_t value = data; // have to skip color sequences in buffered writing mode
186
248
249
+
hd_hw_extent_t x0w = (hd_hw_extent_t)x0; // Cast to hw extent type to be sure of integer values
250
+
hd_hw_extent_t y0w = (hd_hw_extent_t)y0;
187
251
252
+
SSD1309_Bite_t user = *((SSD1309_Bite_t*)value);
253
+
if(user.b0){ // Check if the user's bit is set or not (this implies that the user should always set bit 0 of a 'bite' to the pixel value they want)
254
+
// Need to set the pixel high
255
+
setWindowPixel(x0, y0, pCurrentWindow);
256
+
}else{
257
+
// Need to clear the pixel
258
+
clearWindowPixel(x0, y0, pCurrentWindow);
259
+
}
260
+
// updateRefreshZone( x0, x0, y0, y0); // Tell where we need updates
261
+
// refreshDisplay(); // Perform updates
262
+
}
188
263
189
264
// Functions that don't need color arguments, for simplicity.
0 commit comments