add cramium-sim target

this allows us to build a simulation-focused xous image
this was previously called cramium-fpga but that precise
configuration is less accurate as the simulation environment
makes more shortcuts (and can include more peripherals)
than the fpga environment.
This commit is contained in:
bunnie 2025-01-01 22:45:07 +08:00
parent 261c5eb9fe
commit 44ec809713
2 changed files with 16 additions and 8 deletions

View file

@ -1012,6 +1012,8 @@ impl Builder {
args.push("atsama5d2"); args.push("atsama5d2");
} else if self.utra_target.contains("cramium-soc") { } else if self.utra_target.contains("cramium-soc") {
args.push("cramium-soc") args.push("cramium-soc")
} else if self.utra_target.contains("cramium-fpga") {
args.push("cramium-soc")
} }
args.push("--"); args.push("--");

View file

@ -516,17 +516,22 @@ fn main() -> Result<(), Box<dyn std::error::Error>> {
} }
// ------ Cramium hardware image configs ------ // ------ Cramium hardware image configs ------
Some("cramium-fpga") | Some("cramium-soc") => { Some("cramium-sim") | Some("cramium-soc") => {
let board = "board-dabao"; match task.as_deref() {
// select the board Some("cramium-soc") => {
builder.add_feature(board); let board = "board-dabao";
builder.add_loader_feature(board); // select the board
builder.add_kernel_feature(board); builder.add_feature(board);
builder.add_loader_feature(board);
builder.add_kernel_feature(board);
}
_ => (), // don't add any board because this is simulation
};
// placement in flash is a tension between dev convenience and RAM usage. Things in flash // placement in flash is a tension between dev convenience and RAM usage. Things in flash
// are resident, non-swapable, but end up making the slow kernel burn process take longer. // are resident, non-swapable, but end up making the slow kernel burn process take longer.
let cramium_flash_pkgs = let cramium_flash_pkgs =
["xous-ticktimer", "xous-log", "xous-names" /* "cram-hal-service" */].to_vec(); ["xous-log", "xous-names", "cram-mbox1", "cram-mbox2" /* "cram-hal-service" */].to_vec();
let cramium_swap_pkgs = [].to_vec(); let cramium_swap_pkgs = [].to_vec();
builder.add_loader_feature("debug-print"); builder.add_loader_feature("debug-print");
@ -541,7 +546,7 @@ fn main() -> Result<(), Box<dyn std::error::Error>> {
builder.add_loader_feature("sram-margin"); builder.add_loader_feature("sram-margin");
match task.as_deref() { match task.as_deref() {
Some("cramium-fpga") => builder.target_cramium_fpga(), Some("cramium-sim") => builder.target_cramium_fpga(),
Some("cramium-soc") => builder.target_cramium_soc(), Some("cramium-soc") => builder.target_cramium_soc(),
_ => panic!("should be unreachable"), _ => panic!("should be unreachable"),
}; };
@ -787,6 +792,7 @@ Hardware images:
av-test automation framework for TRNG testing (AV directly, no CPRNG). [cratespecs] ignored. av-test automation framework for TRNG testing (AV directly, no CPRNG). [cratespecs] ignored.
tiny Precursor tiny image. For testing with services built out-of-tree. tiny Precursor tiny image. For testing with services built out-of-tree.
cramium-soc BSP validation image for Cramium. Contains a superset of features, in various states of testing. cramium-soc BSP validation image for Cramium. Contains a superset of features, in various states of testing.
cramium-sim Tiny target for verilator simulation
baosec Baosec application target image. baosec Baosec application target image.
Hosted emulation: Hosted emulation: