Live data from Hacker News

.NET for NES Game Console on 6502 Microprocessors

github.com

21–25 of 25 posts

Re: .NET for NES Game Console on 6502 Microprocessors

#21

Earlier quoted context omitted.

So K&R C wasn't proper C?

It predates the first standardized C versions: * ANSI C by 11 years (C89) * ISO C by 12 years (C90) https://en.wikipedia.org/wiki/C_(programming_language)#K&R_C

So strange. Someone invented a computer language called C and is not proper C until it is stabdardised by a committee. I would say the original C is proper C. Got a whole operating system to run with it.

Organisation is nothing if we do not accept individual’s role.

Re: .NET for NES Game Console on 6502 Microprocessors

#22
post #3

No runtime No BCL No objects or GC No debugger Strings are ASCII I did not see the readme mention anything about bool/byte/char/short/int/long sizes or signed and unsigned. It can be quite a surprise to find yourself with 8 bit long longs! As some found with sdcc for gameboy.

The NES has 2K ram, where you can get carts with mappers that allow you to use prg as ram as well though, this is still limited. Also, the "stack" as it exists must fit on a page (256 bytes). Putting a runtime or sorts onto an NES itself is a big feat given this and requires a lot of manual twiddling.

The hardware stack pointer is restricted to indexing within [$0100, $01ff] but, lacking a stack-pointer-relative addressing mode, it is more preferable to realize a parameter stack using a zero-page pointer indexed with the (zp),Y addressing mode, as cc65 does.

Re: .NET for NES Game Console on 6502 Microprocessors

#23
post #21

Earlier quoted context omitted.

It predates the first standardized C versions: * ANSI C by 11 years (C89) * ISO C by 12 years (C90) https://en.wikipedia.org/wiki/C_(programming_language)#K&R_C

So strange. Someone invented a computer language called C and is not proper C until it is stabdardised by a committee. I would say the original C is proper C. Got a whole operating system to run with it. Organisation is nothing if we do not accept individual’s role.

The C language as invented for porting UNIX does not fit into a NES, nor does it expose its hardware capabilities.

Re: .NET for NES Game Console on 6502 Microprocessors

#24

Earlier quoted context omitted.

Didn't see the video but doesn't that effectively mean that .NET was ported to DOS?

.net 2.0 and later are highly dependent on windows and winapi. Parts of .net core might stand a better chance at being ported to DOS.

.NET 2.0 was fully implemented as Open Source by the Mono Project.

The most recent version includes quite a bit of Microsoft code and offers .NET 1.0 through 4.x

Re: .NET for NES Game Console on 6502 Microprocessors

#25

>For lack of a better word, .NES is a "transpiler" that takes MSIL and transforms it directly into a working 6502 microprocessor binary that can run in your favorite NES emulator. >Building a project should produce a *.nes binary, that is byte-for-byte identical to a program written in C. What about memory management? Is the garbage collector included in the generated code? If not, any idea on how memory management i…

No objects and GC so far. I guess local variables are stored on the stack and for everything on the heap (globals, strings) the transpiler maps MSIL loads and stores to 6502 loads and stores.
Post reply on HN