Recent content by coffeeprogrammer

  • Be sure to checkout “Tips & Tricks”
    Dear Guest Visitor → Once you register and log-in:

    This forum does not automatically send notices of new content. So if, for example, you would like to be notified by mail when Steve posts an update to his blog (or of any other specific activity anywhere else), you need to tell the system what to “Watch” for you. Please checkout the “Tips & Tricks” page for details about that... and other tips!

    /Steve.
  1. coffeeprogrammer

    Array of pointers, VirtualAlloc and RtlMoveMemory. MASM, some kind of problem.

    32 bit registers, at some point I want to tackle 64-bit, assembler will never die, I know the calling convention is different. I've thought about getting a Win98 VM and doing some dos programming, but I have not because there are so many modern things I need to learn. I am also trying to...
  2. coffeeprogrammer

    Array of pointers, VirtualAlloc and RtlMoveMemory. MASM, some kind of problem.

    Wow, cool, I will have to see if I can figure that out exactly. Assembler feels a whole new world for me, I know my programs are short but once I get an idea I feel compelled to stick with it until I have something working. I feel like if I make a lot of small simpler programs to figure things...
  3. coffeeprogrammer

    Array of pointers, VirtualAlloc and RtlMoveMemory. MASM, some kind of problem.

    Well I am not sure if anyone cares, but in the past I have a little frustrated with assembler, because when I hit a wall it would take a lot longer to overcome than with higher level languages. But with ChatGPT and stackover flow I made good progress the last few days. This is the program I was...
  4. coffeeprogrammer

    Array of pointers, VirtualAlloc and RtlMoveMemory. MASM, some kind of problem.

    ok I am closer, but I still have a problem How do I get the value of eax ("memory location from VirtualAlloc",) where data was copied into arrayPtr (arrayPtr + count * sizeof DbRecord) .386 .model flat, stdcall option casemap :none include windows.inc include user32.inc include...
  5. coffeeprogrammer

    Array of pointers, VirtualAlloc and RtlMoveMemory. MASM, some kind of problem.

    PS I asked on StackOver flow as well and someone asked if it was an assembler error or a runtime error, it is a assembler error INVOKE argument type mismatch : argument : 1 on the invoke RtlMoveMemory line, that line was just one of my not fully educated guesses.
  6. coffeeprogrammer

    Array of pointers, VirtualAlloc and RtlMoveMemory. MASM, some kind of problem.

    Does anybody know how to fix the addElement function so it ends up as another element in the array. The idea is a dynamic array, where arrayPtr is a pointer to the first element, then new elements can be added dynamically and kept track of by increasing the arrayPtr value. So in-fact I think...
  7. coffeeprogrammer

    ReactOS happenings

    I recently started playing around with the ReactOS code, building and WinDBGing it. I have not modified it yet, just studying it, time permitting. I joined the ReactOS chat and talked to one of the devs. He has made these somewhat loud dev streams as part of the process. It can be helpful in...
  8. coffeeprogrammer

    Can some tell me what is wrong with this MASM code?

    ChatGPT does make mistakes in assembly, but if you know a little about assembly you can fix them. I made a bouncing ball app masm program over a year ago, it was a mess and it was about 340 lines. I had chatGPT help me and I rewroteit for a v2 and it came out at 139 lines, there are two minor...
  9. coffeeprogrammer

    Can some tell me what is wrong with this MASM code?

    Ok, my internet was out for most of the day today. Yesterday I asked ChatGPT a lot of questions about assembly and that got my mind in that place. Today I tried to fix yesterday’s problem of a “atoi” function for masm assembly (atoi is a function in C++ at least that converts a ansii character...
  10. coffeeprogrammer

    Can some tell me what is wrong with this MASM code?

    many times it basically said to me that there was nothing really wrong, when i pasted that simplified version that was only enough code for the problem and added a comment with the error the assembler was giving it seemed to figure it out. I knew it was something in this area, but I don't...
  11. coffeeprogrammer

    Can some tell me what is wrong with this MASM code?

    Well after starting a fresh chat it seems to have found the problem: include \masm32\include\masm32rt.inc include \masm32\include\windows.inc include \masm32\include\user32.inc include \masm32\include\kernel32.inc atoi PROTO var1 :PTR BYTE .data number dd 'Hi', 0 .code main proc invoke...
  12. coffeeprogrammer

    Can some tell me what is wrong with this MASM code?

    Well I have simplified it down, the code below shows the problem OpenGPT does not seem to think there is a problem. include \masm32\include\masm32rt.inc include \masm32\include\windows.inc include \masm32\include\user32.inc include \masm32\include\kernel32.inc atoi PROTO var1: PTR BYTE .data...
  13. coffeeprogrammer

    Can some tell me what is wrong with this MASM code?

    How did you ask it what was wrong, i don't know how to do that? I took about five or so different questions to get it to write this code.
  14. coffeeprogrammer

    Can some tell me what is wrong with this MASM code?

    Can someone tell me what is wrong with this code? I get error A2070: invalid instruction operands on line 80. It is MASM code largely written by OpenGPT. It should tell if a number is prime when it is done. OpenGPT did preatty well, but there where a few problem that i fixed, I don't know what...
  15. coffeeprogrammer

    SpinRite 6.1 alpha 4 corrupted screen on intel macbook.

    I don’t think is spinrite exactly on the macbook, I booted it again and left it at the command prompt and after a few minutes it pop into the corrupt screen, must just be freedos.