Search found 487 matches

by Jarhmander
Sat Sep 15, 2018 5:52 am
Forum: NESdev
Topic: VRC7 and 5B amplifier investigation, also VRC7 LFO reset!
Replies: 53
Views: 45380

Re: VRC7 and 5B amplifier investigation, also VRC7 LFO reset

Your pMOS transistor is reversed. Flip it vertically i.e. exchange the drain and the source.
by Jarhmander
Fri Sep 14, 2018 9:37 pm
Forum: NESdev
Topic: VRC7 and 5B amplifier investigation, also VRC7 LFO reset!
Replies: 53
Views: 45380

Re: VRC7 and 5B amplifier investigation, also VRC7 LFO reset

A question about using an inverter as an amplifier: to accomplish this, we need to bias the input to some middle voltage? Right? (2.5v?) The magic is that the inverter self-bias. Yep, that's right: the output and the input converges itself to about ½ Vcc; the slight discrepancy is due to unequal ga...
by Jarhmander
Fri Sep 14, 2018 2:24 pm
Forum: General Stuff
Topic: Makefile, how to make it react to any content included?
Replies: 42
Views: 15986

Re: Makefile, how to make it react to any content included?

I realize my example in the last post didn't prove something crucial... You have no dep file to maintain, it's entirely automatic. For instance, if you add an include file in any file, the dependency information will be updated automatically by a regular make invocation. This includes (no puns inten...
by Jarhmander
Fri Sep 14, 2018 6:24 am
Forum: General Stuff
Topic: Makefile, how to make it react to any content included?
Replies: 42
Views: 15986

Re: Makefile, how to make it react to any content included?

deps is not urgent yet: as long that I just clean the project, it won't be an issue (just slow a little bit on an old core 2 duo). Well if you just made all .H files in your project a dependency of every .C file you'd should get the same result as having to do a clean rebuild for any header change ...
by Jarhmander
Mon Sep 10, 2018 7:17 pm
Forum: NESdev
Topic: Compact /10 and %10 operations?
Replies: 22
Views: 8095

Re: Compact /10 and %10 operations?

I see optimality in having numbers in tiles 246-255, at least for things like score points: you rarely substract points, if ever, in a game. From the look of it, you genuinely optimized your tile for scorekeeping. I find it actually clever.
by Jarhmander
Fri Sep 07, 2018 9:25 pm
Forum: General Stuff
Topic: Makefile, how to make it react to any content included?
Replies: 42
Views: 15986

Re: Makefile, how to make it react to any content included?

Looking at my old Makefile, here how I did it — and it works correctly: include main.mk LD := ${CC} OBJS := $(addprefix ${BUILD_DIR}/,${SOURCES:.s=.o}) DEPS := $(addprefix ${BUILD_DIR}/,${SOURCES:.s=.d}) .PHONY: all all: ${TARGET} .PHONY: clean clean: rm -rf ${BUILD_DIR} ${TGT_POSTCLEAN} .PHONY: tes...
by Jarhmander
Sat Aug 25, 2018 7:53 am
Forum: NES Music
Topic: NSF Extensions, NSF2 and NSFe (2018)
Replies: 84
Views: 60551

Re: NSF Extensions, NSF2 and NSFe (2018)

I guess it's a debate of whenever we want to add another routine address in the metadata vs reusing resources (address). Either ways looks fine, but the "init called twice", while a bit awkward, has the advantage of being simple, is almost compatible with the existing non-returning NSFs and sidestep...
by Jarhmander
Sun Aug 19, 2018 11:55 am
Forum: Newbie Help Center
Topic: wla-65816 assembler confusion
Replies: 4
Views: 2583

Re: wla-65816 assembler confusion

In particular you seem to have combined -v and -o into -vo? Maybe just separate those? Some programs accept that kind of flag combining, but this is not a universal behaviour. The option grouping is "standard" behavior. In fact, it is a recommended guideline in POSIX (per section 12.2, Utility Synt...
by Jarhmander
Fri Aug 17, 2018 4:02 am
Forum: NESdev
Topic: What is the practical use of indexed indirect addressing?
Replies: 32
Views: 7952

Re: What is the practical use of indexed indirect addressing

In fact, JMP (indirect) already existed in the stock 6502, what changed in latter models is the fact that the fetch of the indirect address is not buggy and doesn't wrap in a page...
by Jarhmander
Thu Aug 09, 2018 9:47 pm
Forum: NESdev
Topic: MMC3: What happens if a bank switch is interrupted by NMI?
Replies: 22
Views: 4990

Re: MMC3: What happens if a bank switch is interrupted by NM

What I like about the FME-7 over the other mappers (like MMC3) is that its simple protocol for its functions lends to very simple and fool-proof code when dealing with its registers: ;; calling with A: mapper register value, X: mapper register address stx mapper_reg ; shadow register stx $8000 sta $...
by Jarhmander
Thu Jul 19, 2018 5:22 am
Forum: NESdev
Topic: How much have changed regarding editor/ide?
Replies: 25
Views: 3235

Re: How much have changed regarding editor/ide?

It seems vim is very popular. I guess I should earn to use it a little bit more. I'm so used to the mouse these days that the vim paradigm, although interesting, is hard to get used unless you know enough commands. :set mouse=a Tada, you can use the mouse. You'll get more speed from knowing vim's m...
by Jarhmander
Wed Jul 18, 2018 6:05 am
Forum: NESdev
Topic: How much have changed regarding editor/ide?
Replies: 25
Views: 3235

Re: How much have changed regarding editor/ide?

I have stuck with EDIT.COM and mostly because I absolutely require the ability to place cursor anywhere on the text area and seems very few editors have that, the few I have found have always been worse or have no Win32 version available. 1- Download & install vim/gvim 2- Open a file with gvim 3- :...
by Jarhmander
Fri Jul 13, 2018 5:48 am
Forum: NESdev
Topic: Little coroutine lib for cc65. (In progress)
Replies: 3
Views: 2134

Re: Little coroutine lib for cc65. (In progress)

I'm pretty sure there's a demo on this board that uses cooperative multi-threading. If my memory serves right, it's blargg that did it, and moved 128? 256? objects on the screen. Might find it this evening if someone didn't already since then.
by Jarhmander
Thu Jun 28, 2018 6:20 am
Forum: NESdev
Topic: cc65: Unnecessary code when accessing pointers
Replies: 22
Views: 5197

Re: cc65: Unnecessary code when accessing pointers

I didn't know that char was always unsigned in cc65. I would say this goes against the C standard. The signedness of the char type is implementation-dependent ; that means it can be either signed or unsigned, and the implementer of the compiler is free to choose one. Oddly enough, whatever the sign...
by Jarhmander
Thu Jun 28, 2018 6:06 am
Forum: NESdev
Topic: Efficient way to reuse variables
Replies: 48
Views: 12447

Re: Efficient way to reuse variables

In addition, Microchip's XC8 C compiler does that too. In fact, depending on the chip model, it can use both a "compiled stack" (which is just fixed locations for variables) and a software stack; by default, it only use the later for functions that are called from multiple contexts (ex: from main an...