This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

How to Write function in Assemble and interface to C code

Please give some example that will show how write and interface assembly function to C

Parents
  • 00000000   LDR   PC, =__initial_sp
    ---> 4 Bytes
    00000004   LDR   PC, =Reset_Handler
    00000008   LDR   PC, =NMI_Handler
    ======================================
    0x00000000 0268      LSLS     r0,r5,#9
    ---> 2 Bytes
    0x00000002 1000      ASRS     r0,r0,#0
    0x00000004 0169      LSLS     r1,r5,#5
    0x00000006 0000      MOVS     r0,r0
    0x00000008 0171      LSLS     r1,r6,#5
    0x0000000A 0000      MOVS     r0,r0
    0x0000000C 0173      LSLS     r3,r6,#5
    0x0000000E 0000      MOVS     r0,r0
    

Reply
  • 00000000   LDR   PC, =__initial_sp
    ---> 4 Bytes
    00000004   LDR   PC, =Reset_Handler
    00000008   LDR   PC, =NMI_Handler
    ======================================
    0x00000000 0268      LSLS     r0,r5,#9
    ---> 2 Bytes
    0x00000002 1000      ASRS     r0,r0,#0
    0x00000004 0169      LSLS     r1,r5,#5
    0x00000006 0000      MOVS     r0,r0
    0x00000008 0171      LSLS     r1,r6,#5
    0x0000000A 0000      MOVS     r0,r0
    0x0000000C 0173      LSLS     r3,r6,#5
    0x0000000E 0000      MOVS     r0,r0
    

Children