LICENSE: Add MIT Licence
This commit is contained in:
@@ -1,4 +1,8 @@
|
||||
// (c) 2023 John A. Breaux
|
||||
// This code is licensed under MIT license (see LICENSE.txt for details)
|
||||
|
||||
//! The Bus connects the CPU to Memory
|
||||
//! This is more of a memory management unit + some utils for reading/writing
|
||||
|
||||
use crate::error::Result;
|
||||
use std::{
|
||||
|
||||
@@ -1,3 +1,6 @@
|
||||
// (c) 2023 John A. Breaux
|
||||
// This code is licensed under MIT license (see LICENSE.txt for details)
|
||||
|
||||
//! Decodes and runs instructions
|
||||
|
||||
#[cfg(test)]
|
||||
|
||||
@@ -1,3 +1,6 @@
|
||||
// (c) 2023 John A. Breaux
|
||||
// This code is licensed under MIT license (see LICENSE.txt for details)
|
||||
|
||||
//! A disassembler for Chip-8 opcodes
|
||||
|
||||
use super::{Adr, Nib, Reg};
|
||||
|
||||
@@ -1,3 +1,6 @@
|
||||
// (c) 2023 John A. Breaux
|
||||
// This code is licensed under MIT license (see LICENSE.txt for details)
|
||||
|
||||
//! Represents a chip-8 instruction as a Rust enum
|
||||
|
||||
use super::{Adr, Nib, Reg};
|
||||
|
||||
@@ -1,3 +1,6 @@
|
||||
// (c) 2023 John A. Breaux
|
||||
// This code is licensed under MIT license (see LICENSE.txt for details)
|
||||
|
||||
//! Tests for cpu.rs
|
||||
//!
|
||||
//! These run instructions, and ensure their output is consistent with previous builds
|
||||
|
||||
@@ -1,3 +1,6 @@
|
||||
// (c) 2023 John A. Breaux
|
||||
// This code is licensed under MIT license (see LICENSE.txt for details)
|
||||
|
||||
//! Error type for chumpulator
|
||||
|
||||
use thiserror::Error;
|
||||
@@ -14,5 +17,5 @@ pub enum Error {
|
||||
#[error(transparent)]
|
||||
IoError(#[from] std::io::Error),
|
||||
#[error(transparent)]
|
||||
WindowError(#[from] minifb::Error)
|
||||
WindowError(#[from] minifb::Error),
|
||||
}
|
||||
|
||||
@@ -1,3 +1,6 @@
|
||||
// (c) 2023 John A. Breaux
|
||||
// This code is licensed under MIT license (see LICENSE.txt for details)
|
||||
|
||||
//! Platform-specific IO/UI code, and some debug functionality.
|
||||
//! TODO: Break this into its own crate.
|
||||
|
||||
|
||||
17
src/lib.rs
17
src/lib.rs
@@ -1,11 +1,12 @@
|
||||
#![feature(stmt_expr_attributes)]
|
||||
/*!
|
||||
This crate implements a Chip-8 interpreter as if it were a real CPU architecture,
|
||||
to the best of my current knowledge. As it's the first emulator project I've
|
||||
embarked on, and I'm fairly new to Rust, it's going to be rough around the edges.
|
||||
// (c) 2023 John A. Breaux
|
||||
// This code is licensed under MIT license (see LICENSE.txt for details)
|
||||
|
||||
Hopefully, though, you'll find some use in it.
|
||||
*/
|
||||
#![feature(stmt_expr_attributes)]
|
||||
//! This crate implements a Chip-8 interpreter as if it were a real CPU architecture,
|
||||
//! to the best of my current knowledge. As it's the first emulator project I've
|
||||
//! embarked on, and I'm fairly new to Rust, it's going to be rough around the edges.
|
||||
//!
|
||||
//! Hopefully, though, you'll find some use in it.
|
||||
|
||||
pub mod bus;
|
||||
pub mod cpu;
|
||||
@@ -20,8 +21,8 @@ pub struct Chip8 {
|
||||
|
||||
/// Common imports for chumpulator
|
||||
pub mod prelude {
|
||||
use super::*;
|
||||
pub use super::Chip8;
|
||||
use super::*;
|
||||
pub use crate::bus;
|
||||
pub use bus::{Bus, Read, Region::*, Write};
|
||||
pub use cpu::{disassemble::Disassemble, ControlFlags, CPU};
|
||||
|
||||
@@ -1,3 +1,6 @@
|
||||
// (c) 2023 John A. Breaux
|
||||
// This code is licensed under MIT license (see LICENSE.txt for details)
|
||||
|
||||
//! Chirp: A chip-8 interpreter in Rust
|
||||
//! Hello, world!
|
||||
|
||||
|
||||
Reference in New Issue
Block a user