How do I access local C variables in Keil using ARM inline Assembly?
Have you read the section on their site about this - Inline assembler support in the compiler
There is a big difference from gcc in that you put the name of the C variable into the instruction directly rather than something like %2 for the variable associated with the third output or input asm operand and the compiler will figure out what the constraints are itself.