Skip to content

Converts the esoteric programming language Brainfuck into Chip8 Assembly Code

License

Notifications You must be signed in to change notification settings

Jackson-S/BF-Chip8-Compiler

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

BF -> Chip8 Compiler

This project compiles BrainFuck Code into Chip8 assembly, which can be run on any Chip8 interpreter.

Web Version

You can play around with an online Javascript version on my website.

Limitations

  • Compiled programs must fit within 3840 bytes.
    • An empty file is 424 bytes, each operator character (i.e. one of .<>+-) requires 2 bytes and very loop instruction ([]) requires 3 bytes.
  • There are 256 tape positions, the tape will loop back to 0 on an overflow.
  • On most emulators due to stack constraints you can only have 15 nested loops.
  • Chip8 runs at 500 hertz, so any programs running on a standard interpreter will be very slow.
  • Programs cannot take any input.

Screenshots

Hello World Sample Alphabet Sample

About

Converts the esoteric programming language Brainfuck into Chip8 Assembly Code

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages