Message Edited by irob on 2007-02-1209:08 AM
Alban edited part number
Message Edited by Alban on 2007-02-12 05:51 PM
Alban wrote:May be the MCU is 'frozen'. I don't know if you are certain it is still running with other activity.When you have a reset and BKGD pin low, you force the MCU to start in Special Single Chip Mode (SCC).It's another supposition to check by leaving PTA4 floating and see it's level.
$Include "mc9s08qg8.inc" org RomStartstart mov #%11000000,PTBD ;turn off LED's mov #%11000000,PTBDD ;make outputs mov #%00010000,PTAD ;make GPIO on BKGD pin high mov #%00010000,PTADD ;set to output (not required, always output) lda #%00001100 sta PTAPE ;pullup two switches lda #$D0 sta SOPT1 ;disable BKGDloop sta SRS ;feed the dog brclr 2,PTAD,loop5 ;test switch 1 bset 6,PTBD ;turn off LED1 bra loop10loop5 bclr 6,PTBD ;turn on LED1loop10 brclr 3,PTAD,loop15 ;test switch 2 bset 7,PTBD ;turn off LED2 bset 4,PTAD ;set GPIO on BKGD pin bra loop20loop15 bclr 7,PTBD ;turn on LED2 bclr 4,PTAD ;clear GPIO on BKGD pinloop20 bra loop org Vreset DW start ;reset vector
"write-once register so only the first write after reset is honored... Any subsequent attempt to write to SOPT1 (intentionally or unintentionally) is ignored to avoid accidental changes to these sensitive settings."
Message Edited by Alban on 2007-02-12 05:51 PM
Message Edited by Alban on 2007-02-12 05:51 PM