4 years, 1 month ago.

Pure Assembly Language Project Template

How to develop a pure assembly language project in the online compiler? Thanks

1 Answer

4 years, 1 month ago.

Create a new project and delete all files and libraries. Then add your assembly files and code.

I have tge following assembly code which suppose to turn on the LED1. But it is not working then I burn the bin into the mbed 1768. Anything idea why it wont works? Thanks a lot.

blinky.s

   AREA startup, CODE, READONLY
    EXPORT __main
__main

    LDR R0, =0x2009C020     ; FIO1DIR
    MOV R2, #0x00040000     ; 0x040000 = 1<<18 all "0"s with a "1" in bit 18
    STR R2, [R0]
    
    LDR R1, =0x2009C038     ; FIO1SET
    STR R2, [R1]  ; if==1, set LED1 bit
    END
posted by left handed 06 Dec 2015