Hi, My code doesn't work if I compile it with ROM(HUGE) mode, but works fine if compile it under ROM(LARGE) mode. Any comments would be appreciated. Thank you! Processor: p87c51MB2 CX51: V7.04d LX51: V3.54
Hi, I found the following information from this website: "The ECRM mode is only available is some devices. For example, the Philips P8xC51MA/MB/MC and the P89C669 do not offer this mode. Check the device datasheet before setting the ECRM mode. " I know ECRM should be set to "1" if we want CALL/RET save and restore the full 3-byte program counter. To my understanding base on the information shown above, if we use p8xc51MA/MB/MC, we can't have excutable code above 64k since these chip doesn't support ECRM mode, is that right? Thank you! Xiao
You are intermixing ECRM with EIFM. EIFM is used to store 3-bytes PC on interrupts. ECALL will always save 3-bytes PC when executing. ECRM is Extended CALL Return Mode. It is available on SmartMX (SmartCard device) only.
Hi, Thank you very much! It is great help! I changed bit ECRM from "1" to "0" in START_MX.A51 and created my project. It started running from my emulator(NOHAU. Code mapped in emulator and XDATA mapped on target). But it still doesn't run if I load code to target. If code is less than 64k, I can run code from target without any problems. I made EAM,ESMM and EIFM all "1". Is there anything I should do for code beyond 64k? Thank you!
P89c669 does not support ecrm,but how can I to use or not use ecrm in keil
Such problems often stem from some bit in some SFR not being (re)set in startup.a51. I have not looked at the 669 for a long time but somwhere in the old DNA computer is floating around something about a bit that need be set to switch to 24 bit mode. Erik
such as EAM1:0=00 After reset, bits EAM1:0=00 (default value) place MX2 part in fully pin-to-pin 80C51 binary compatible micro = 16 bit address Erik