====== Create an Assembly Project ====== Creating an Assembly project is pretty much the same as createing a [[c_project|C project]]. \\ \\ {{keil_add_file_3.png?700em}} \\ \\ |< 100% 10em >| ^Type|Choose "Asm File (.s)".| ^Name|Choose an appropriate name.| ^Location|Choose correct [[c_project#prepare_project_directory|location]] (.\App).| ===== Normal Assembly Project ===== To create a "normal" Assembly project you just have to add Assembly files to the project instead of C files. \\ The example code bellow shows a minimal main procedure. \\ AREA myCode, CODE, READONLY THUMB ADDR_LED EQU 0x60000100 ADDR_DIPSW EQU 0x60000200 main PROC EXPORT main LDR R0, =ADDR_LED LDR R1, =ADDR_DIPSW loop LDR R2, [R1, #0] STR R2, [R0, #0] B loop ENDP ALIGN END \\ ===== Minimal Assembly Project ===== The difference between a normal an d a minimal Assembly project is, that for the minimal project you don't need to choose a runtime component. This means you have to take care of every aspect yourself! \\ The example code bellow shows a very minimal setup (without access to the CT Board [[ctboard:input|input]] or [[ctboard:output|output]] peripherals). \\ AREA RESET, DATA, READONLY EXPORT __Vectors __Vectors DCD 0x2002ffff ; top of stack DCD Reset_Handler ; reset vector AREA myCode, CODE, READONLY THUMB CONST_VALUE_X EQU 12 ENTRY Reset_Handler ; -- Your code belongs here --------------------------------- LDR R0, =0 LDR R1, =CONST_VALUE_X loop ADD R0, R1 B loop ; -- Your code ends here ------------------------------------ END \\ \\ //**Back to [[software:start:getting_started|Getting Started]]**//