In SX Microcontrollers, SX/B Compiler and SX-Key Tool, Peter Van der Zee wrote: Hi Peter; No, that still does not work. Perhaps I'm not explaining myself well enough. I wish to create a macro (several in fact, one for indirect jump, one for indirect call, and one for indirect statejump, and perhaps more) that I will name IJump, ICall etc. These macros will each have one parameter; the label of the address were the jump is to end up. What the macro is to do, is test for a modified label, particularly IPARAM where the parameter passed to the macro is pre-pended with something to differentiate it from the target jump address (so address FOUR is modified to IFOUR), and if that label does not exist, then append an entry in the jump table on page zero for address FOUR passed to the macro IJump. Each entry in the table has the page and the jump address of the target. Naturally the macro needs to restore the program counter with an org to the value it had at the point of the macro call. I can get this to work for the first instance I make the macro call to any target address, but subsequent calls to the SAME address will not work. Naturally I wish to have only one entry in my jump table per jump location, but be able to access that multiple times, and from anywhere. So my issue is the multiple call situation. At present (that is without this feature) I have to manually remember whether or not the indirect entry has already been entered, and I thought the macro should be able to do this for me. Thanks for your interest, and putting up with my ranting. Cheers, Peter (pjv) ---------- End of Message ---------- You can view the post on-line at: http://forums.parallax.com/forums/default.aspx?f=7&p=1&m=244787#m245775 Need assistance? Send an email to the Forum Administrator at forumadmin@parallax.com The Parallax Forums are powered by dotNetBB Forums, copyright 2002-2008 (http://www.dotNetBB.com)