[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Mixing ORCA/M and ORCA/C



In article <behrenss.735404706@hpalle9> Soenke Behrens writes:
>gudat@avalon.physik.unizh.ch (gudat henrik) writes:

>>Has anyone tried this: I want to call an ASM routine from C, but I need
>>to set the A,X,Y registers to a specific value. The assmebly code sets
>>the registers to new values and then returns to the C code. How can I
>>set the registers with a C statement without asm (if possible) commands?
>>And how can I read them?

>W/o ASM statements, you are stuck, at least as far as setting the regs goes.
>I'd have to check which registers are left alone by the subroutine-caller,,
>anyway. As for returning values of registers: You can do it with either A

I'm pretty sure that Orca/C leaves y-reg alone as I use y-reg to pass
screen offsets to my asm sprite routines.


>Soenke
>--
>===========================================================================
>More than silver, more than gold, I need   !    behrenss@informatik.
>electricity. I need it for my dreams.      !    tu-muenchen.de
>(RACTER)                                   !  FIDO: 2:246/13 Soenke Behrens

Joseph
--
jlee@bonnie.ics.uci.edu             | Type, type, type, type......
                                    | Can you hear the typing in my head? :)