Giter Site home page Giter Site logo

brucehoult / bronzebeard Goto Github PK

View Code? Open in Web Editor NEW

This project forked from theandrew168/bronzebeard

0.0 1.0 0.0 797 KB

Minimal assembler and ecosystem for bare-metal RISC-V development

Home Page: https://bronzebeard.readthedocs.io

License: MIT License

Python 91.48% Assembly 8.52%

bronzebeard's Introduction

Bronzebeard

Bronzebeard is a simple, standalone assembler for developing bare metal RISC-V programs. It is designed for applications that stand on their own without relying on operating systems, frameworks, SDKs, or pre-existing software of any kind. This assembler supports the base 32-bit instruction set as well as the M, A, and C extensions (RV32IMAC).

Bronzebeard and its tools are implemented purely in Python. It has been written in order to be free from large, complex toolchains. This keeps the project portable, minimal, and easy to understand.

Motivation

Much of modern software has accrued vast amounts of bulk and complexity throughout the years. Can useful software be developed without relying on any of it? That's the question that this project seeks to answer. I believe that the rise of RISC-V provides a great opportunity to explore different methods of program development. Installing a full operating system doesn't have to be a prerequisite to building something useful.

Check out the DerzForth project for further elaboration of this idea.

Installation

If you are unfamiliar with virtual environments, I suggest taking a brief moment to learn about them and set one up. The Python docs provide a great tutorial for getting started with virtual environments and packages.

Bronzebeard can be installed via pip:

pip install bronzebeard

Or, if you'd rather clone this repo and play with the examples:

git clone https://github.com/theandrew168/bronzebeard.git
cd bronzebeard/
# I'd still create and activate a virtual environment here
pip install -e .

Assemble!

First, create a text file with some RISC-V assembly source code in it:

add x1, x2, x3
add x4, x5, x6

Then, with Bronzebeard installed:

bronzebeard my_asm_file.asm

By default, the assembled output binary will be placed in a file named bb.out.

Testing

Bronzebeard's tests are written using pytest:

pip install pytest

Once installed, the tests can be run via:

pytest

bronzebeard's People

Contributors

enthusi avatar nickherrig avatar theandrew168 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.