Porównaj commity

..

5 Commity

Autor SHA1 Wiadomość Data
Philip Howard 0c2f498432
Merge d3691b625b into f1ea35fbbf 2024-04-12 14:15:43 +01:00
Phil Howard d3691b625b CI: Enable ulab for Tiny 2040 8MB.
This build has plenty of room for fancy extras.

Replaces #570
2024-04-11 17:08:55 +01:00
Phil Howard 15c170e160 CI: Add linker script for tiny2040_8mb build. 2024-04-11 17:08:55 +01:00
Phil Howard 3b1c8a958a CI: Attempt to catch flash overflow.
Using a custom patch against MicroPython's CMakeLists.txt this will
optionally use a memmap_mp.ld file from the *board* directory and
allow us to check if the allocated app flash overflows.

Linker scripts need configured on a per board basis.
2024-04-11 17:08:55 +01:00
Phil Howard b9cdcf1e93 CI: Print memory usage.
Add a patch for CMakeLists.txt which adds -Wl,--print-memory-usage so
we can get at least some useful information about which builds are
running close to the limits.
2024-04-11 17:08:55 +01:00
3 zmienionych plików z 14 dodań i 23 usunięć

Wyświetl plik

@ -47,9 +47,8 @@ namespace pimoroni {
return !(sr.read() & 128);
}
void Inky73::busy_wait(uint timeout_ms) {
absolute_time_t timeout = make_timeout_time_ms(timeout_ms);
while(is_busy() && !time_reached(timeout)) {
void Inky73::busy_wait() {
while(is_busy()) {
tight_loop_contents();
}
}

Wyświetl plik

@ -70,7 +70,7 @@ namespace pimoroni {
// Methods
//--------------------------------------------------
public:
void busy_wait(uint timeout_ms=45000);
void busy_wait();
void reset();
void power_off();

Wyświetl plik

@ -133,6 +133,8 @@ namespace pimoroni {
void ST7789::configure_display(Rotation rotate) {
bool rotate180 = rotate == ROTATE_180 || rotate == ROTATE_90;
if(rotate == ROTATE_90 || rotate == ROTATE_270) {
std::swap(width, height);
}
@ -183,30 +185,20 @@ namespace pimoroni {
// Pico Display
if(width == 240 && height == 135) {
caset[0] = 40; // 240 cols
caset[1] = 40 + width - 1;
raset[0] = 52; // 135 rows
raset[1] = 52 + height - 1;
if (rotate == ROTATE_0) {
raset[0] += 1;
raset[1] += 1;
}
madctl = rotate == ROTATE_180 ? MADCTL::ROW_ORDER : MADCTL::COL_ORDER;
caset[1] = 279;
raset[0] = 53; // 135 rows
raset[1] = 187;
madctl = rotate180 ? MADCTL::ROW_ORDER : MADCTL::COL_ORDER;
madctl |= MADCTL::SWAP_XY | MADCTL::SCAN_ORDER;
}
// Pico Display at 90 degree rotation
if(width == 135 && height == 240) {
caset[0] = 52; // 135 cols
caset[1] = 52 + width - 1;
caset[1] = 186;
raset[0] = 40; // 240 rows
raset[1] = 40 + height - 1;
madctl = 0;
if (rotate == ROTATE_90) {
caset[0] += 1;
caset[1] += 1;
madctl = MADCTL::COL_ORDER | MADCTL::ROW_ORDER;
}
madctl = rotate == ROTATE_90 ? (MADCTL::COL_ORDER | MADCTL::ROW_ORDER) : 0;
raset[1] = 279;
madctl = rotate180 ? (MADCTL::COL_ORDER | MADCTL::ROW_ORDER) : 0;
}
// Pico Display 2.0
@ -215,7 +207,7 @@ namespace pimoroni {
caset[1] = 319;
raset[0] = 0;
raset[1] = 239;
madctl = (rotate == ROTATE_180 || rotate == ROTATE_90) ? MADCTL::ROW_ORDER : MADCTL::COL_ORDER;
madctl = rotate180 ? MADCTL::ROW_ORDER : MADCTL::COL_ORDER;
madctl |= MADCTL::SWAP_XY | MADCTL::SCAN_ORDER;
}
@ -225,7 +217,7 @@ namespace pimoroni {
caset[1] = 239;
raset[0] = 0;
raset[1] = 319;
madctl = (rotate == ROTATE_180 || rotate == ROTATE_90) ? (MADCTL::COL_ORDER | MADCTL::ROW_ORDER) : 0;
madctl = rotate180 ? (MADCTL::COL_ORDER | MADCTL::ROW_ORDER) : 0;
}
// Byte swap the 16bit rows/cols values