Added prog2; renamed blink to prog1

This commit is contained in:
Jonathan Chan 2018-01-14 10:50:49 -08:00
parent 6bb8095fcc
commit 78ada02dfa
4 changed files with 32 additions and 0 deletions

25
lab2/prog2.asm Normal file
View File

@ -0,0 +1,25 @@
#include "msp430g2553.inc"
org 0x0C000
RESET:
mov.w #0x400, SP
mov.w #WDTPW|WDTHOLD, &WDTCTL
mov.b #11110111b, &P1DIR
mov.b #01001001b, &P1OUT
mov.b #00001000b, &P1REN
mov.b #00001000b, &P1IE
mov.w #0x0049, R7
mov.b R7, &P1OUT
EINT
bis.w #CPUOFF, SR
PUSH:
xor.w #0000000001000001b, R7
mov.b R7, &P1OUT
bic.b #00001000b, &P1IFG
reti
org 0xffe4
dw PUSH
org 0xfffe
dw RESET

7
lab2/prog2.hex Normal file
View File

@ -0,0 +1,7 @@
:10C0000031400004B240805A2001F240F700220083
:10C01000F24049002100F2422700F2422500374059
:10C020004900C247210032D232D0100037E041002F
:0AC03000C2472100F2C223000013F2
:02FFE4002CC02F
:02FFFE0000C041
:00000001FF