summaryrefslogtreecommitdiff
path: root/src/devices.rs
Commit message (Collapse)AuthorAge
* Rewrite emulatorv1.0.0-alpha1Ben Bridle2024-10-28
| | | | | | | | | | | | | | | This is a complete rewrite and restructure of the entire emulator project, as part of the effort in locking down the Bedrock specification and in creating much better tooling for creating and using Bedrock programs. This commit adds a command-line argument scheme, an embedded assembler, a headless emulator for use in non-graphical environments, deferred window creation for programs that do not access the screen device, and new versions of phosphor and bedrock-core. The new version of phosphor supports multi-window programs, which will make it possible to implement program forking in the system device later on, and the new version of bedrock-core implements the final core specification.
* Refactor the file deviceBen Bridle2024-08-06
| | | | | | | | | | | | | | | | The major feature of this refactor is the creation of BedrockFilePath, a type which can be losslessly converted into an operating-system specific path or a Bedrock-style byte path. It also prevents file paths which can't be represented as Bedrock-style byte paths from being constructed, and allows the use of a base directory which acts as an inescapable sandbox. BedrockFilePath will support the creation of a virtual root directory on Windows which will allow navigation between drive letters via the standard hierarchical navigation ports. This commit has been tested on Linux, but not yet Windows. Further work is expected before the new code will work on Windows.
* Improve comment clarityBen Bridle2024-07-30
|
* Set file operation success flag when ascending and descendingBen Bridle2024-06-30
| | | | | This is to allow the program to detect whether the previous ascend or descend operation succeeded.
* Prevent clock device from locking out all other devicesBen Bridle2024-06-30
| | | | | | | When the clock device was first in order to be responded to, a fast enough recurring timer could successfully prevent any other device from being able to wake the emulator, if a timer was able to expire in the time it took to run the clock wake handler.
* Fix memory deviceBen Bridle2024-04-22
| | | | | | | | | | | There was confusion between the role of the page_limit variable in the memory device, where it was being used to mean both the absolute upper limit of pages that are allowed to be allocated, but also to mean the number of pages that the program would like to be allocated when needed. To fix this, the program is now just told the full number of pages that it is allowed to use, without first requiring that the program request a particular number of pages.
* Fix memory, input, screen, and file devicesBen Bridle2024-04-16
| | | | | | | The memory device was never being allocated any memory, the input device wasn't scrolling correctly, the screen device was rendering sprites incorrectly, and the device ID of the file device had not been changed over from 0xA to 0x9.
* Update devices to match new specificationsBen Bridle2024-04-16
|
* Implement new file device interfaceBen Bridle2024-01-31
| | | | | This is a complete redesign of the file device. The most notable addition is the ability to ascend and descend the file tree.
* Refactor code without changing functionalityBen Bridle2024-01-31
| | | | | An effort to make the code shorter and more readable. This mostly affects the code for the clock device.
* Change clock cumulative timer to use 256th ticks instead of secondsBen Bridle2024-01-31
| | | | | | The "Cumulative seconds" port of the CLOCK device has been changed to be called "Cumulative timer", with the units changing from seconds to 1/256 second ticks.
* First commitv0.1.0Ben Bridle2023-12-24