mirror of
https://github.com/lupyuen/pinephone-nuttx.git
synced 2025-01-12 20:58:34 +08:00
Change Panel Width and Height to Parameters
This commit is contained in:
parent
3f352782a1
commit
15111a227a
3 changed files with 5 additions and 5 deletions
|
@ -4617,7 +4617,7 @@ But to render graphics on PinePhone we need the following drivers, which are sti
|
|||
|
||||
So we created this Test Program in Zig that calls the C and Zig Drivers, in the right sequence...
|
||||
|
||||
https://github.com/lupyuen/pinephone-nuttx/blob/32351d5a189b50af3bcfa2347bd993db615c465d/render.zig#L1146-L1183
|
||||
https://github.com/lupyuen/pinephone-nuttx/blob/3f352782a116da27d03871251bf8f09ce13e7bd9/render.zig#L1146-L1183
|
||||
|
||||
[(Download the binaries here)](https://github.com/lupyuen/pinephone-nuttx/releases/tag/v1.1.9)
|
||||
|
||||
|
|
|
@ -1107,7 +1107,7 @@ pub export fn hello_main(
|
|||
|
||||
} else if (std.mem.eql(u8, cmd, "c")) {
|
||||
// Init PMIC (in C)
|
||||
_ = a64_tcon0_init();
|
||||
_ = a64_tcon0_init(PANEL_WIDTH, PANEL_HEIGHT);
|
||||
|
||||
} else if (std.mem.eql(u8, cmd, "d")) {
|
||||
// Enable MIPI DSI Block (in C)
|
||||
|
@ -1153,7 +1153,7 @@ pub export fn hello_main(
|
|||
|
||||
// Init Timing Controller TCON0 (in C)
|
||||
// https://github.com/lupyuen2/wip-pinephone-nuttx/blob/tcon2/arch/arm64/src/a64/a64_tcon0.c#L180-L474
|
||||
_ = a64_tcon0_init();
|
||||
_ = a64_tcon0_init(PANEL_WIDTH, PANEL_HEIGHT);
|
||||
|
||||
// Init PMIC (in Zig)
|
||||
pmic.display_board_init();
|
||||
|
@ -1307,7 +1307,7 @@ extern fn a64_de_init() c_int;
|
|||
extern fn a64_mipi_dphy_enable() c_int;
|
||||
extern fn a64_mipi_dsi_enable() c_int;
|
||||
extern fn a64_mipi_dsi_start() c_int;
|
||||
extern fn a64_tcon0_init() c_int;
|
||||
extern fn a64_tcon0_init(width: u16, height: u16) c_int;
|
||||
extern fn pinephone_panel_init() c_int;
|
||||
extern fn render_graphics() c_int;
|
||||
|
||||
|
|
|
@ -26,7 +26,7 @@ int main()
|
|||
ginfo("TODO: Turn on Display Backlight\n");
|
||||
|
||||
// Init Timing Controller TCON0
|
||||
ret = a64_tcon0_init();
|
||||
ret = a64_tcon0_init(A64_TCON0_PANEL_WIDTH, A64_TCON0_PANEL_HEIGHT);
|
||||
assert(ret == OK);
|
||||
|
||||
ginfo("TODO: Init PMIC\n");
|
||||
|
|
Loading…
Reference in a new issue