Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
nickmqb
searching Neon…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
6 ms
·
1.
▲
by
nickmqb
6y ago
Shameless plug: I had a similar impression when looking at nMigen, but wasn't super happy with Verilog either, so I wrote a new HDL called Wyre [0]. No metaprogramming, but a Verilog-like language with a focus on ergonomics instead. I&
2.
▲
by
nickmqb
6y ago
It did cross my mind. However, a problem with that approach is that evaluating such a formula is too costly/inaccurate on a small FPGA like this, which just has 8 DSPs (that can only do 16x16 bit multiplication), and some of these are
3.
▲
by
nickmqb
6y ago
Most textures look fine despite the 4-bit quantization, but color artifacts/hue change do become more apparent when multiplying with a light factor (to darken the textures on the bottom and sides of blocks), so I'd say 4-bit is de
4.
▲
by
nickmqb
6y ago
VGA is an analog protocol, but the FPGA can only output a 0 (GND) or 1 (3.3v) on its I/O pins. I'm using a Digilent VGA Pmod [1] which uses a set of resistor ladders to map each color component from a 4-bit value to an analog volt
5.
▲
by
nickmqb
6y ago
That's a good observation! This technique is also known as "racing the beam". The problem is a mismatch of refresh rates; the VGA display operates at 60 Hz but the ray tracer is not capable of producing that many pixels, it c
6.
▲
by
nickmqb
6y ago
Yes, I am. This also means that any open source distribution won't include those textures. However, if I do end up open sourcing the work I'll make sure to include instructions for people that already own Minecraft; the textures a
7.
▲
by
nickmqb
6y ago
Yes and no. The design includes a custom built 16-bit CPU, which uses a custom instruction set, which I wrote an assembler for. There is a small 4kb bank of RAM that contains a program written in this instruction set. From a hardware perspe
8.
▲
by
nickmqb
6y ago
That's a good idea. The two analog sticks on the GC controller would be an improvement over the single stick on the N64 controller for movement in 3D. I think that the main benefit of the N64 controller (besides a nostalgia factor, tho
9.
▲
by
nickmqb
6y ago
Just do it ;). I don't have a blog post on how I got started, but you gave me the idea that perhaps I should write one. In terms of hardware, I'm using an iCEBreaker dev board [1] which has worked really well (A nice bonus is that
10.
▲
by
nickmqb
6y ago
In terms of I/O pins that should actually be fine (current pinout: VGA (14x), SPI (4x), CLK (1x), N64_controller (1x)), though I'm still working on the project and I don't think it'll be done by the deadline. It looks li
11.
▲
by
nickmqb
6y ago
There are definitely FPGAs that are a lot more capable than the FPGA that I'm using. For example, see my reply to flatiron here: https://news.ycombinator.com/item?id=25172781 While it would have been easier to use a la
12.
▲
by
nickmqb
6y ago
I probably won't port it to other platforms, however, as I wrote in another comment, I am considering open sourcing it when it's done, so others can port it if they like. I just looked up the MiSTer board [1]. They are using a DE1
13.
▲
by
nickmqb
6y ago
Yes, I'm using Wyre for this. Feedback is always welcome, so once you've had a chance to try it, don't hesitate to let me know what you think!
14.
▲
by
nickmqb
6y ago
Thanks! That's correct, I built the ray tracing "GPU" from scratch. It's highly optimized because it needs to trace 256 * 128 * 30 = 0.98 million rays per second on very under powered hardware. It's specifically
15.
▲
by
nickmqb
6y ago
Yup, that's correct, the design is implemented in Wyre, which is a hardware definition language that I created. The language compiles to Verilog so it can work with existing hardware development toolchains. The language is open source
16.
▲
by
nickmqb
6y ago
The FPGA that I'm using for this (the Lattice iCE40 UP5K) is really limited when it comes to RAM, which is the main constraint when it comes to world size. As per the title, there's only 143kb, which is insanely low for doing any
17.
▲
by
nickmqb
6y ago
The screen is connected to the FPGA over VGA. The output resolution is 1024x768 @ 60Hz, but the 3D portion of the screen is rendered at 256x128 @ 30Hz. The design consists of a custom 16-bit CPU (running at 32.6Mhz) and a custom raytracing
18.
▲
I'm building a Minecraft clone in hardware, on a tiny FPGA with 143kb of RAM
(twitter.com)
369 points
by
nickmqb
6y ago
|
50 comments
19.
▲
by
nickmqb
6y ago
You're not giving the older generations of programmers enough credit here. While it is true that strong typing is a requirement for the best performance (and this remains so), the productivity benefits of strong typing have been known
20.
▲
by
nickmqb
6y ago
A list of widgets, with each widget having a x, y, width and height.
21.
▲
by
nickmqb
6y ago
Do UIs need to be trees? How do things change if we were to use a list instead? What becomes easier/harder? Layout calculations might become slightly more expensive, though it seems that that may be acceptable since most time is spent
22.
▲
Show HN: Wyre, a hardware definition language that compiles to Verilog
(github.com)
4 points
by
nickmqb
6y ago
|
0 comments
23.
▲
by
nickmqb
6y ago
I have a somewhat controversial opinion on this. This paper, like some others that I've seen, treats parsing as an academic/algorithmic topic. Given some token stream we'd like to minimize some error criteria. However, these
24.
▲
by
nickmqb
6y ago
This FPGA is not open source by design, but this project seems fairly complete: http://www.clifford.at/icestorm/ "Project IceStorm aims at documenting the bitstream format of Lattice iCE40 FPGAs and providing sim
25.
▲
by
nickmqb
6y ago
Does anyone know of any minimal TUI libraries? Something in the spirit of a VGA text buffer, that allows the user to manage their own cell buffer as a block of memory, and allows them to blit that to the terminal -- and ideally have that wo
26.
▲
by
nickmqb
6y ago
> Avoid mixing spaces and tabs in the indentation of a text block This has some implications. For example, I can imagine someone editing a text block and inadvertently using a different indentation type (tabs/spaces) from the other
27.
▲
by
nickmqb
7y ago
I'm working on Muon, a modern low-level programming language: https://github.com/nickmqb/muon
28.
▲
by
nickmqb
7y ago
There is huge potential for a modern light weight C replacement. Golang went in this direction, but it has a runtime with a GC. Rust is low level, but is quite a complex language. So, there is a gap in the market. One cool aspect of all of
29.
▲
by
nickmqb
7y ago
Agreed. Non-null pointers also come with their own set of problems: - Increased language complexity. Initialization of (arrays of) structs with non-null pointer members is more complicated because there is no straightforward "default&q
30.
▲
Using libclang to generate C bindings for Muon
(nickmqb.github.io)
3 points
by
nickmqb
7y ago
|
0 comments
More ›