Mish

Mish

0-day streak
For day 11 of my #C045S4393CY|, I finished the logic of the assembler for my Rusty-Man Computer project! I just have to add some more tests and write up some documentation about it, and then I'll have a fully-functional assembler for the Little-Man Computer system :P You can take a look at all of today's work on the Github repo. Here's a screenshot of it running (after a few Rust warnings that I might want to fix at some point)
https://scrapbook-into-the-redwoods.s3.us-east-1.amazonaws.com/daf05031-fe46-4cbc-b35a-ee3a5e25a97d-image.pnghttps://scrapbook-into-the-redwoods.s3.us-east-1.amazonaws.com/c3c39a28-ee1f-46f5-9a8a-359450f95fa9-c5512cc9-64d4-442f-abe7-86a8f771203d.png
wom emoji
rustlang emoji
github emoji
10daysinpublic emoji
Today I worked on a Little-Man Computer assembler for my Rusty-Man Computer Rust project. After doing a lot of thinking and coding, I wrote all of the parsing logic in one go, to create something similar to an AST. That bit seems to have worked, which is great! Next, I just need to create a symbol table to keep track of labels, and then actually converting the parsed structure to machine code. I've implemented it by splitting each line into space-separated parts, and parsing each part (which also has to depend on if the first part is a valid opcode or not... I should probably just pop the first part off if it's a label so that the rest of the code can be consistent but that's for later me). This isn't as flexible as a proper parser (which would go character-by-character) but seems to work well for LMC assembly. I'm pretty sure this is now day 10 of my #C045S4393CY|! 🎉
https://scrapbook-into-the-redwoods.s3.us-east-1.amazonaws.com/462eeda2-d95c-404f-bccc-3b2acbf087b5-image.pnghttps://scrapbook-into-the-redwoods.s3.us-east-1.amazonaws.com/c4a266e9-0992-4b3d-ba45-36eebcc4e973-d336719c-60a6-4e75-8c17-9aa2b30c377a.png
Today was day 7 of my #C045S4393CY|, and while I don't have much to show, I started work on a new program in my Rusty-Man Computer project called rmc_assemble (an assembler for LMC assembly) that will be able to be used with the LMC emulator I've made. I decided to develop this tool using test-driven development, because I can steal the example programs from the online simulator and use them as test data. Today I set up a test and a stub function, but haven't started implementing yet. I also updated my project to the 2024 edition of Rust (which became stable this month). This didn't require any code changes. Tomorrow I plan to continue working on the assembler program :)
https://scrapbook-into-the-redwoods.s3.us-east-1.amazonaws.com/ae51e41f-7b45-4e62-9800-e971c4d1b754-screenshot_20250303-223800_github.png
wom emoji
rustlang emoji
goose-honk-technologist emoji
10daysinpublic emoji
For day 7 of my #C045S4393CY|, I improved my bin_creator program (part of Rusty-Man Computer) by letting it accept multi-line input, because that's the format you get when you copy memory data from the online LMC simulator. This should make it much more convenient to use (previously, you had to manually remove the newlines). This involved learning how to get the last two digits of a string in Rust, which is a bit more involved than it sounds (I got away with line.chars().rev().take(2).collect::<String>()) I also wrote a script (build_binaries.sh) to use cross to cross-compile my code for 3 different target platforms, and then copy the generated binaries into a single folder to make them easy to upload to GH Releases. Naturally, I used that script to publish my first release that contains pre-compiled binaries for multiple platforms, which you can read about at github.com/RandomSearch18/rusty_man_computer/releases/tag/v0.4.0 Next, I want to start work on an assembler tool to add to the project :D
https://scrapbook-into-the-redwoods.s3.us-east-1.amazonaws.com/987e2013-1118-4d97-96c9-3f9e0f4cc1ed-a2d53194-487c-40c2-a26b-d8a9152cfb6c.png
For day 7 of #C045S4393CY|, I started work on automatic cross-compilation of Rusty-Man Computer for various platforms. I added a list of fully-supported platforms that I intend to build binaries for to the README, and set up a Github Action to use cross (Github) to compile the code for various platforms. (Of course, users can still run the Rust compiler themselves if they wish.) This is an important step for distributing my program and making it accessible to more people. I also added 14 more tests to the code, which test that each individual instruction works correctly. This should make it easy to pin down any regressions during development in the future.
https://scrapbook-into-the-redwoods.s3.us-east-1.amazonaws.com/95d1a58c-e28b-4064-9896-2596fda93d92-a992950d-1a84-41b7-a880-67ace72a7b67.png
Today in my Rust LMC emulatior, I implemented a custom integer struct that will only allow values between -999 and +999 (to match the behaviour of the online simulator). I wrote more about that change in pull request #6 (read the embed below :)) I learnt how to use modules for organisation and to keep my private fields private. I also wrote a whole bunch of tests (8 tests) for my struct's behaviour. This marks my 5th day of #C045S4393CY|, which means I'm half-way to the 10-day goal! Tomorrow, I want to investigate cross-compiling my program with cross, working towards perhaps releasing a stable version. But for now, it's 7pm, and I should really be revising for my Physics mock tomorrow morning. Cya!
https://scrapbook-into-the-redwoods.s3.us-east-1.amazonaws.com/0cd0c6b9-c0a2-47b2-862a-404ef99e218f-image.pnghttps://scrapbook-into-the-redwoods.s3.us-east-1.amazonaws.com/9c0d9cc8-0e1d-450f-a13f-9413cb88b0f9-3f494460-79e5-46ef-93a4-712309a86f02.png
I've spent the past 5 days working on a Little Man Computer emulator, but until today I hadn't actually read through the Wikipedia article for it! I also discovered an alternative simulator on 101computing.net, and I borrowed its factorial example code to use as a demo for my emulator. I also added an intergration test that uses that program. This marks Day 6 of my #C045S4393CY| submission
https://scrapbook-into-the-redwoods.s3.us-east-1.amazonaws.com/cee071f2-8f25-4017-953e-1f2ab9e631c4-6e339e88-2d6e-4a15-a02f-a2e3c6b1aa1a.png
wom emoji
goose-honk-technologist emoji
10daysinpublic emoji
I had an exam today so didn't expect to get anything done for day 4 of #C045S4393CY|, but I managed! I added integration and unit tests to Rusty-Man Computer, which should help to ensure I don't break any parts of the emulator while I work on more complex features! I plan to add more tests later too. I merged this work in PR #5 but haven't cut a release because there weren't any user-facing changes today :)
https://scrapbook-into-the-redwoods.s3.us-east-1.amazonaws.com/5f89ee40-cf6a-4b7f-a4a6-5421cacee31f-image.pnghttps://scrapbook-into-the-redwoods.s3.us-east-1.amazonaws.com/57bfba09-c3ce-4071-a360-bf10cf03c49b-1111b808-40f8-4bcd-97a2-81b9dd9d21e0.png
For day 3 of #C045S4393CY|, I finished updating the output format of Rusty-Man Computer, so it now matches the official simulator for all the demo programs! I also learnt how to do CLI arg parsing using the clap crate, and used it to implement a new --output-only option that should help make the emulator more suitable for practical purposes. I also set up a Github Action to automatically build my code every time I commit/merge to master, so I know that my code compiles. I published today's changes as v0.3.0. Tomorrow, I want to write some tests for the program :)
https://scrapbook-into-the-redwoods.s3.us-east-1.amazonaws.com/74b0dbeb-9602-42a1-b29f-639a2b3c3a5c-image.pnghttps://scrapbook-into-the-redwoods.s3.us-east-1.amazonaws.com/13b9a597-7ba4-413a-b305-8c148ac57bfc-13cb09f1-8d41-419c-ac1a-556f98ca0503.png
wom emoji
goose-honk-technologist emoji
github emoji
10daysinpublic emoji
I'm working on my Rust Little Man Computer implementation for #C045S4393CY|. Today (day 2), I wanted to improve how output is presented to more closely match how the official simulator does it. I tried representing the output as a Vec<[char; 4]>, toyed with the idea of a Vec<String>, before deciding to go back to a simple String and only split it into lines when rendering the output. A challenge came from trying to work out how the LMC simulator decides when to insert a line break: numbers on their own are always on their own line, but numbers with some letters after them all end up on the same line... but if I just print a 1 and a Space a bunch of times, there's a new line in between each iteration... I'm still trying to wrap my head around the logic for those line breaks, so I haven't finished "fixing" my output-printing code, but the work-in progress commit is on GitHub.
https://scrapbook-into-the-redwoods.s3.us-east-1.amazonaws.com/2cdeea70-7ca0-43a9-a73d-abc18a79e83b-023586d7-3aa1-4b13-bfde-74b51d357525.png
I worked on my LMC emulator today for day 1 of #C045S4393CY|! I started by writing a README file because the project didn't have one before, and then I added support for the Input instruction. This means that my program has reached feature parity with the online simulator, so tomorrow I can work on improving how output is shown, and providing command-line options to reduce the amount of info that is printed.
https://scrapbook-into-the-redwoods.s3.us-east-1.amazonaws.com/f1b1ad4c-e109-43fc-a275-fb3920351c13-image.pnghttps://scrapbook-into-the-redwoods.s3.us-east-1.amazonaws.com/ea2e5bc8-2fe0-4893-97f7-88a1e3bb5c45-36aae201-9828-4805-a3b7-54b20d9bae43.png
wom emoji
github emoji
10daysinpublic emoji
Investigating how the OSMnx library converts OSM data to graphs
https://scrapbook-into-the-redwoods.s3.us-east-1.amazonaws.com/7f222654-f5c2-4535-975f-e91bf5806b28-image.pnghttps://scrapbook-into-the-redwoods.s3.us-east-1.amazonaws.com/9deed44d-4c9f-48a7-9e22-b5fffc8dcd78-image.png
I'm ready to give y'all the first look at Outstanding, the millionth markdown-based note-taking app built with web tech. The main goal of this one is to create a great app for writing lesson notes, revision notes, or assessed work. Simple for when you just need to write, and simultaneously customizable to fit your preferences. Outstanding isn't yet ready to become your primary note-taking tool (most of the buttons in the screenshot don't function yet!), but it does indeed edit notes, with the ability to store them in a local folder or internally in the browser. It's also built to be highly extendible, using JavaScript or JSON, with a system of providers, registries, and datapacks 😅 Try it now:
tw_earth_africa emoji
outstanding.slevel.xyz Take a look at the source code or project goals:
github emoji
github.com/RandomSearch18/outstanding Am I shipping the last Arcade project I need to reach my goal, the very night the event ends? You bet I am.
https://scrapbook-into-the-redwoods.s3.amazonaws.com/1bcf1fbb-26eb-4057-b45a-78af6687e5a5-screen_shot_2024-08-31_at_22.26.06.pnghttps://scrapbook-into-the-redwoods.s3.amazonaws.com/45d99600-f490-48e8-a5cb-5ab80471781e-image.png
summer-of-making emoji
github emoji
js emoji
goose-honk-technologist emoji
I learnt to use Kivy (a cross-platform GUI framework for Python) by making a flashcard program. You can create your own set of flashcards by writing a CSV file in the app or in your favourite external editor, and then view them at your leisure. Should run anywhere you can get Python + SDL working (any desktop OS), as well as on Android! See the README for details, over at github.com/RandomSearch18/kivy-flash-cards
https://scrapbook-into-the-redwoods.s3.us-east-1.amazonaws.com/7dbd6b9e-8037-4813-97a3-695568a688fd-f4d796f7-dc6b-403a-97e8-75ff3d99fcea.png
summer-of-making emoji
github emoji
python emoji
Today I'm releasing StatsApp, a command-line tool to help with processing WhatsApp chat exports and turning them into pretty graphs and analytics 📈 It has two jobs: • Parse the plain-text chat export format to extract the different message types, content, and metadata • Perform some data processing to generate statistics for your group chats Take a look at
github emoji
<https://github.com/MMK21Hub/statsapp|the Github repo (MMK21Hub/statsapp)> for further documentation, or to try it out with your own group chats!
https://scrapbook-into-the-redwoods.s3.amazonaws.com/fec118f9-5a88-4553-97e3-d751396dd788-image.pnghttps://scrapbook-into-the-redwoods.s3.amazonaws.com/5d5e8a03-11af-425e-a6b8-f82fae4d236f-image.pnghttps://scrapbook-into-the-redwoods.s3.amazonaws.com/d116ca66-97d8-48df-be30-5ea5f42e5fa5-image.png
summer-of-making emoji
github emoji
https://scrapbook-into-the-redwoods.s3.us-east-1.amazonaws.com/dde35f88-fd8f-4be0-9297-6396019d0e30-397fa193-4ec7-478c-9c40-6ac7bab6f085.png
summer-of-making emoji
goose-honk-technologist emoji
github emoji
I made Slime Hook - a tool for Terraria server owners to automatically send server logs to a Discord channel, made for servers running in Docker. Find out more or deploy it for yourself: github.com/MMK21Hub/slime-hook
https://scrapbook-into-the-redwoods.s3.amazonaws.com/5cace398-5815-490a-9768-df3553c7338b-image.png