Search found 37 matches
- Mon Jan 28, 2019 1:50 pm
- Forum: Homebrew Projects
- Topic: Microgame compiler experiment (early WIP)
- Replies: 21
- Views: 20349
Re: Microgame compiler experiment (early WIP)
If you don't mind reinventing the wheel (writing your own parser) once you have the workings well defined, a VRML-style syntax would avoid quoting everything, comma separation between properties, and the need to put code in strings.
- Wed Nov 21, 2018 8:42 pm
- Forum: General Stuff
- Topic: Simple way to disable mouse middle click paste in linux?
- Replies: 10
- Views: 7048
Re: Simple way to disable mouse middle click paste in linux?
I didn't even know this was a thing. I've sometimes missed clicking the bookmarks toolbar in Firefox and ended up middle-click-pasting the same url into the middle of itself in the address bar. Not a clue what was happening (other than maybe Firefox constantly putting the url in the clipboard or som...
- Fri Oct 12, 2018 5:26 pm
- Forum: NESdev
- Topic: Writing my own assembler
- Replies: 73
- Views: 32751
Re: Writing my own assembler
yeah, I was confusing his assembler feature with the talk of the global jmp/label ret.
- Fri Oct 12, 2018 4:10 pm
- Forum: NESdev
- Topic: Writing my own assembler
- Replies: 73
- Views: 32751
Re: Writing my own assembler
Nevermind me. I get it now and could see it going either way.
- Fri Oct 12, 2018 3:39 pm
- Forum: NESdev
- Topic: Writing my own assembler
- Replies: 73
- Views: 32751
Re: Writing my own assembler
1. By far my most common label is a @Return: label in front of a nearby RTS statement. Maybe it's my style of coding, but I find that subroutines always has some branching conditions that exits early. So I realized it would be pretty nifty if I could just write a branch jump like this: LDA MyVar BE...
- Sat Apr 14, 2018 5:35 pm
- Forum: General Stuff
- Topic: Programming in C - questions
- Replies: 17
- Views: 6868
Re: Programming in C - questions
Some compilers (GCC in particular) will even optimize some loops into calls to memcpy/move/set functions.
- Mon Dec 18, 2017 6:44 pm
- Forum: General Stuff
- Topic: Can you write windows app in regular C++?
- Replies: 25
- Views: 10300
Re: Can you write windows app in regular C++?
Visual C++ for Windows Store/UWP apps is currently stuck using their proprietary C++/CX language that auto generates opaque regular C++ behind the scenes. They do plan to convert over to a new C++/Winrt "projection" that allows for native C++20 (so much co_await!). There's a github page he...
- Sun Nov 05, 2017 11:49 pm
- Forum: Newbie Help Center
- Topic: How can I use dlls in Linux?
- Replies: 5
- Views: 2932
Re: How can I use dlls in Linux?
On Linux, dynamic libraries have the '.so' extension (for 'shared object') and are also what you link with. For me on Ubuntu (which I *think* installed with the command tepples gave, it's been awhile), the include is "#include <SDL2/SDL.h>" and then the link command has `pkg-config --cflag...
- Wed Sep 20, 2017 4:35 pm
- Forum: General Stuff
- Topic: Is it possible to program Raspberry Pi in assembly?
- Replies: 91
- Views: 23021
Re: Is it possible to program Raspberry Pi in assembly?
If it's just a gcc cross compiler, binutils (which has an assembler) will likely be in there somewhere as it has the linker.
You could also compile binutils yourself targeting arm.
You could also compile binutils yourself targeting arm.
- Sat Aug 26, 2017 9:22 pm
- Forum: NESemdev
- Topic: CPU writes to PPU Memory.
- Replies: 6
- Views: 3841
Re: CPU writes to PPU Memory.
That's one option. It takes being careful about when various things trigger catch up, like sprite-0-hit. In my case, I just chose to write my cpu as NES-specific as it has calls to ppu_cycles(3) throughout instructions after emulating each cycle, although sometimes that's not necessary as not every ...
- Sat Aug 26, 2017 8:30 pm
- Forum: NESemdev
- Topic: CPU writes to PPU Memory.
- Replies: 6
- Views: 3841
Re: CPU writes to PPU Memory.
That would not work for some instructions as it doesn't represent the two happening at the same time. For example, read-modify-write instructions (from nesdev.com/6502_cpu.txt): Read-Modify-Write instructions (ASL, LSR, ROL, ROR, INC, DEC, SLO, SRE, RLA, RRA, ISB, DCP) # address R/W description --- ...
- Mon May 15, 2017 9:00 pm
- Forum: NESemdev
- Topic: Implementing BEQ and other Branch Instructions?
- Replies: 11
- Views: 5652
Re: Implementing BEQ and other Branch Instructions?
Its tricky as the 5th is actually the 1st of the next opcode. So it depends on how your system is implemented but basically it only takes 4 cycles max, as the fetch opcode is the first cycle of the next opcode. bne takenNextPage - 1 load bne 1 - 2 load offset 2 - 3 add PCL 3 - 4 add PCH 4 takenNext...
- Sat May 13, 2017 10:57 pm
- Forum: NESemdev
- Topic: Implementing BEQ and other Branch Instructions?
- Replies: 11
- Views: 5652
Re: Implementing BEQ and other Branch Instructions?
(quietly updates his emulator to not have taken branches to a different page take 5 cycles) 
- Fri Nov 08, 2013 6:04 pm
- Forum: General Stuff
- Topic: VB.NET Message Loop
- Replies: 20
- Views: 5637
Re: VB.NET Message Loop
I'm not sure if Form.Show() and Application.DoEvents() will work together (it's been forever since I've used C#), but maybe try: form.Show(); while( form not closed ) { //render Application.DoEvents(); } If it'll work like that you won't really need to override WndProc. Any code that comes after th...
- Fri Nov 08, 2013 4:56 pm
- Forum: General Stuff
- Topic: VB.NET Message Loop
- Replies: 20
- Views: 5637
Re: VB.NET Message Loop
I'm not sure if Form.Show() and Application.DoEvents() will work together (it's been forever since I've used C#), but maybe try:
form.Show();
while( form not closed )
{
//render
Application.DoEvents();
}
If it'll work like that you won't really need to override WndProc.
form.Show();
while( form not closed )
{
//render
Application.DoEvents();
}
If it'll work like that you won't really need to override WndProc.