We are running a survey to help us improve the experience for all of our members. If you see the survey appear, please take the time to tell us about your experience if you can.
in the article "SFR Access" (http://www.keil.com/support/man/docs/isd51/isd51_sw_sfraccess.htm),it is mentioned that ISD51 includes only a few functions to write to SFRs. These functions are listed in the ISD51.A51 file. If you write to SFRs from within the µVision IDE, corresponding functions must be available in ISD51.A51. By default, only a few functions are provided (ACC, B, DPH, DPL, P0, P3, PSW, and SP). Use the following example as a template for your own SFR write routines. This template writes to the SFR at address 0xA5. ;-------------------------------------------------------------------------- ; Command: Write SFR04: SFR:0xA5 ; LOW (?ISD?WRITESFR04), HIGH (?ISD?WRITESFR04), dummy, SFR:0xA5 ; PUBLIC ?ISD?WRITESFR04 ?ISD?WRITESFR04: MOV 0A5H,A AJMP ?ISD?CMDLOOP I add a function in the ISD51.A51 for writing to 0x90(P1)In System:
;-------------------------------------------------------------------------- ; Command: Write SFR04: SFR:0xA5 ; LOW (?ISD?WRITESFR04), HIGH (?ISD?WRITESFR04), dummy, SFR:0xA5 ; PUBLIC ?ISD?WRITESFR04 ?ISD?WRITESFR04: MOV 0A5H,A AJMP ?ISD?CMDLOOP
PUBLIC ?ISD?WRITESFR06 ?ISD?WRITESFR06: MOV 090H,A AJMP ?ISD?CMDLOOP
in the article "SFR Access" (http://www.keil.com/support/man/docs/isd51/i sd51_sw_sfraccess.htm),it is mentioned that: "ISD51 includes only a few functions to write to SFRs. These functions are listed in the ISD51.A51 file. If you write to SFRs from within the µVision IDE, corresponding functions must be available in ISD51.A51. By default, only a few functions are provided (ACC, B, DPH, DPL, P0, P3, PSW, and SP). Use the following example as a template for your own SFR write routines. This template writes to the SFR at address 0xA5.
; Command: Write SFR04: SFR:0xA5 ; LOW (?ISD?WRITESFR04), HIGH (?ISD?WRITESFR04), dummy, SFR:0xA5 PUBLIC ?ISD?WRITESFR04 ?ISD?WRITESFR04: MOV 0A5H,A AJMP ?ISD?CMDLOOP