Browse Source

Enable the system core by setting our time limit percentage

pull/36/head
AzureMarker 3 years ago
parent
commit
39adc8590e
No known key found for this signature in database
GPG Key ID: 47A133F3BF9D03D3
  1. 4
      ctru-rs/examples/futures-basic.rs

4
ctru-rs/examples/futures-basic.rs

@ -18,6 +18,10 @@ fn main() { @@ -18,6 +18,10 @@ fn main() {
let apt = Apt::init().expect("Couldn't obtain APT controller");
let _console = Console::init(gfx.top_screen.borrow_mut());
// Give ourselves up to 30% of the system core's time
apt.set_app_cpu_time_limit(30)
.expect("Failed to enable system core");
println!("Starting executor...");
let (exit_sender, mut exit_receiver) = futures::channel::oneshot::channel();

Loading…
Cancel
Save