Menu

Tree [acfe01] master /
 History

HTTPS access


File Date Author Commit
 .github 2023-08-22 Agustin Izaguirre Agustin Izaguirre [8fad55] ci: Node 14 unsupported with @babel/core, add n...
 __tests__ 2025-06-10 Teo Samaržija Teo Samaržija [ed55c4] Made the N Queens Puzzle print a message before...
 seminar 2025-05-24 Teo Samaržija Teo Samaržija [f9c04f] Mentioned @Gb-JS contributions to Header Script...
 .gitignore 2024-09-16 Teo Samaržija Teo Samaržija [b4de7a] Added some files for SEO...
 .gitlab-ci.yml 2023-08-23 Teo Samaržija Teo Samaržija [01f06f] Attempted to make JEST tests work on GitLab
 Background.gif 2024-05-07 Teo Samaržija Teo Samaržija [ca44d1] Adjusted the color of the background image to b...
 LICENSE 2021-08-26 Teo Samaržija Teo Samaržija [4d74b9] Create LICENSE
 PicoBlaze.html 2025-05-06 Teo Samaržija Teo Samaržija [0dee58] New version of the documentation
 README.md 2025-05-08 Teo Samaržija Teo Samaržija [b5bedd] Noted in the README that the documentation is a...
 TreeNode.js 2025-04-10 Teo Samaržija Teo Samaržija [c432d6] Attempted to fix #38
 assembler.js 2025-04-21 Teo Samaržija Teo Samaržija [a7a92d] Attempted to make the disabled breakpoints work...
 assemblerTest.gif 2020-11-15 Teo Samarzija Teo Samarzija [86cefd] Added the "Assembler Test" example.
 assemblerTest.psm 2024-09-21 Teo Samaržija Teo Samaržija [7dd2aa] Tested the new preprocessor functions in the As...
 babel.config.js 2023-08-22 Agustin Izaguirre Agustin Izaguirre [9ded84] ci: Adds babel with a few plugins to enable imp...
 bin2dec.psm 2025-02-27 Teo Samaržija Teo Samaržija [d55674] Improved the whitespacing in Binary-to-Decimal
 breakpoint.png 2020-11-22 Teo Samarzija Teo Samarzija [ee7cd9] Added breakpoints in the GUI (doing nothing for...
 db.php 2025-05-11 Teo Samaržija Teo Samaržija [264a39] Made `db.php` set the correct MIME type for ass...
 dec2bin.psm 2025-04-13 Teo Samaržija Teo Samaržija [e36aad] Modified the Decimal to Binary and Permutations...
 examples.json 2025-04-28 Teo Samaržija Teo Samaržija [ff7615] Changed the icon of the `nQueensPuzzle.psm` exa...
 fastForward.svg 2020-11-10 Teo Samarzija Teo Samarzija [f31cbc] Added the Fast Forward button.
 fibonacci.psm 2022-09-19 Teo Samaržija Teo Samaržija [085046] Linked to my new MathOverflow question...
 footerScript.js 2024-10-03 Teo Samaržija Teo Samaržija [c1ba7b] Parsing the fetch response directly as JSON, in...
 gray.psm 2022-09-18 Teo Samaržija Teo Samaržija [3ca3e5] Linked to the Reddit discussion about Gray Code...
 headerScript.js 2025-05-20 Gb-JS Gb-JS [aa139c] Update headerScript.js
 hexadecimal_counter.png 2020-11-19 Teo Samarzija Teo Samarzija [7c8e70] The seven-segment displays are now functional.
 index.php 2024-05-22 Teo Samaržija Teo Samaržija [bbcc68] Removed the possibility of `index.php` being us...
 jest.config.js 2023-08-22 Agustin Izaguirre Agustin Izaguirre [6045d4] ci: Adds jest
 list_of_directives.js 2025-04-13 Teo Samaržija Teo Samaržija [f1c8b6] Added the support for the `PRINT_STRING` prepro...
 nQueensPuzzle.jpg 2025-04-28 Teo Samaržija Teo Samaržija [ff7615] Changed the icon of the `nQueensPuzzle.psm` exa...
 nQueensPuzzle.psm 3 days ago Teo Samaržija Teo Samaržija [acfe01] Added an empty line (vertical spacing) to impro...
 octal.psm 2025-02-22 Teo Samaržija Teo Samaržija [ddb4c8] Changed `octal.psm` to use octal numbers by def...
 package-lock.json 2023-08-26 Teo Samaržija Teo Samaržija [0d648b] Updated `package-lock.json`...
 package.json 2025-05-11 Teo Samaržija Teo Samaržija [cdd96a] Prepared for a new release
 parser.js 2024-09-24 Teo Samaržija Teo Samaržija [712255] Linked to my new StackExchange question in the ...
 pause.svg 2020-11-04 Teo Samarzija Teo Samarzija [107557] Added play, pause and stop buttons (doing nothi...
 permutations.psm 2025-04-24 Teo Samaržija Teo Samaržija [e57b82] Copied the Sep Roland's implementation of Bubbl...
 play.svg 2020-11-04 Teo Samarzija Teo Samarzija [107557] Added play, pause and stop buttons (doing nothi...
 preprocessor.js 2025-04-13 Teo Samaržija Teo Samaržija [f1c8b6] Added the support for the `PRINT_STRING` prepro...
 preprocessor_test.psm 2025-02-01 Teo Samaržija Teo Samaržija [3ae552] Switched the Preprocessor Test to the decimal base
 regbanks_flags_test.psm 2023-07-20 Teo Samaržija Teo Samaržija [7440a6] Added the backticks in the comments where neede...
 schema.sql 2024-04-07 Abidin Durdu Abidin Durdu [848839] Basic functionality works
 sevenSegment.psm 2020-11-19 Teo Samarzija Teo Samarzija [f57ba9] Added the LEDs.
 sharer.js 2025-03-30 Teo Samaržija Teo Samaržija [033047] Prepared for a new release
 simulator.js 2025-04-21 Teo Samaržija Teo Samaržija [c154c8] Attempted to mend the problem of multiple break...
 singleStep.svg 2020-11-10 Teo Samarzija Teo Samarzija [1b0762] Added the "single step" button.
 stop.svg 2023-11-16 Teo Samaržija Teo Samaržija [c6f0d8] Extracted the Stop SVG into a new file
 styles.css 2025-01-24 Teo Samaržija Teo Samaržija [de386c] Made the assemble button change the background ...
 tokenizer.js 2025-04-13 Teo Samaržija Teo Samaržija [ae96f2] Attempted to fix #39
 viewer.js 2025-03-27 Teo Samaržija Teo Samaržija [21073f] Attempted to make sure the error 404 responses ...

Read Me

PicoBlaze Assembler and Emulator in JavaScript

Picture of PicoBlaze

This is my attempt to implement a Xilinx PicoBlaze assembler and emulator in JavaScript. My Computer Architecture professor Ivan Aleksi asked me to make it in case physical laboratory exercises need to be canceled because of a pandemic, so that students can do the laboratory exercises in spite of not having access to a real PicoBlaze. Fortunately, thus far, that hasn't happened.

It is available live on SourceForge. In case that doesn't work (for instance, if I got a cross-site scripting attack), the front-end-only version is available on GitHub Pages. As the assembler is written in JavaScript, rather than in PHP, the basic functionality is available even in the front-end-only version. The fork of this program maintained by @agustiza (Agustin Izaguirre) is available live on his website.

Right now, this program has no back-end. Maybe I will add some back-end to enable users to share their own examples and comment on other users' examples later, but, for that, I will need to learn quite a bit of PHP, and it will work only on SourceForge because GitHub Pages supports no back-end scripting. Abidin Durdu (known as @abdrd on GitHub) has made a simple back-end allowing the users to upload their own PicoBlaze assembly programs. It uses MySQL and is running on the SourceForge servers.

The documentation, in Croatian, is available in the seminar folder, in DOCX, DOC, ODT, PDF and RTF formats. (UPDATE: I received a message telling me that me hosting the documentation on my website and my GitHub profile is a copyright infringement. So, the documentation, in Croatian, is available on DABAR in the PDF format.)

If you want to host this project yourself, you might want to edit the lines following the 17th line of the PicoBlaze.html file:

<script>
  var URL_of_JSON_with_examples =
      "https://flatassembler.github.io/PicoBlaze/examples.json",
    URL_prefix_of_the_examples =
      "https://raw.githubusercontent.com/FlatAssembler/PicoBlaze_Simulator_in_JS/master/";
</script>

and modify them to point to where you will host the examples.

An example of a similar project is FRISC JS. Here at the University of Osijek, we are using PicoBlaze as an example of a simple computer, but, at the University of Zagreb, they are using FRISC for that. And their students made an assembler and emulator for FRISC in JavaScript, though I guess it's not for the same reason I made PicoBlaze assembler and emulator in JavaScript (the FRISC JS project predates the pandemic by many years).

Note to the contributors: While there are some JEST tests in this project (made mostly by @agustiza), the test coverage is pretty low, so don't rely solely on them. Please do some manual testing. And, if possible, do that manual testing in Firefox 52 (the last version of Firefox to work on Windows XP, and it's also the version of Firefox that comes with Solaris 11.4), as it is important to me not to break the compatibility with Firefox 52. Many computers at my university are running Windows XP and are using Firefox 52 as the browser, and it is important to me that this program works on those computers.

UPDATE on 24/01/2021: I've started developing a version of this app for Android. As I am not a skilled Android developer, any help will be appreciated.

UPDATE on 18/07/2023: I have started a forum.hr thread where I listed non-trivial problems I currently have with my PicoBlaze Simulator.

UPDATE on 05/07/2024: I've made a YouTube video about this program.

UPDATE on 08/05/2025: The documentation is once again available in the seminar folder.

Language grade: JavaScript
code style: prettier

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.