implements PLN-0100
This commit is contained in:
@@ -2,7 +2,10 @@ use crate::firmware::firmware_state::{FirmwareState, LaunchHubStep};
|
||||
use crate::firmware::prometeu_context::PrometeuContext;
|
||||
use prometeu_hal::color::Color;
|
||||
use prometeu_hal::log::{LogLevel, LogSource};
|
||||
use prometeu_hal::{FrameId, GfxUiCommand, RenderSubmission, ShellUiFramePacket};
|
||||
use prometeu_hal::{
|
||||
FrameId, GfxUiCommand, LegacyHardwareRenderSubmissionSink, RenderSubmission,
|
||||
RenderSubmissionSink, ShellUiFramePacket,
|
||||
};
|
||||
use prometeu_system::CrashReport;
|
||||
|
||||
#[derive(Debug, Clone)]
|
||||
@@ -24,7 +27,9 @@ impl AppCrashesStep {
|
||||
ctx.hw.pad_mut().begin_frame(ctx.signals);
|
||||
|
||||
let packet = ShellUiFramePacket::new(vec![GfxUiCommand::Clear { color: Color::RED }]);
|
||||
ctx.hw.publish_render_submission(&RenderSubmission::shell_ui(FrameId::ZERO, packet));
|
||||
LegacyHardwareRenderSubmissionSink::new(ctx.hw)
|
||||
.submit_render_submission(RenderSubmission::shell_ui(FrameId::ZERO, packet))
|
||||
.expect("firmware crash render submission should publish");
|
||||
|
||||
// If START is pressed, return to the Hub
|
||||
if ctx.hw.pad().start().down {
|
||||
|
||||
@@ -3,7 +3,10 @@ use crate::firmware::prometeu_context::PrometeuContext;
|
||||
use prometeu_hal::color::Color;
|
||||
use prometeu_hal::log::{LogLevel, LogSource};
|
||||
use prometeu_hal::primitives::Rect;
|
||||
use prometeu_hal::{FrameId, GfxUiCommand, RenderSubmission, ShellUiFramePacket};
|
||||
use prometeu_hal::{
|
||||
FrameId, GfxUiCommand, LegacyHardwareRenderSubmissionSink, RenderSubmission,
|
||||
RenderSubmissionSink, ShellUiFramePacket,
|
||||
};
|
||||
|
||||
#[derive(Debug, Clone)]
|
||||
pub struct SplashScreenStep {
|
||||
@@ -44,7 +47,9 @@ impl SplashScreenStep {
|
||||
color: Color::WHITE,
|
||||
},
|
||||
]);
|
||||
ctx.hw.publish_render_submission(&RenderSubmission::shell_ui(FrameId::ZERO, packet));
|
||||
LegacyHardwareRenderSubmissionSink::new(ctx.hw)
|
||||
.submit_render_submission(RenderSubmission::shell_ui(FrameId::ZERO, packet))
|
||||
.expect("firmware splash render submission should publish");
|
||||
|
||||
// Transition logic
|
||||
// If any button is pressed at any time after the animation ends
|
||||
|
||||
Reference in New Issue
Block a user