title: Read from STDIN in ARMSim#
body: <p>I am doing ARM ASM in ARMSim#. I wanted to take a integer as input from STDIN and process. I was able to do it for a file, but from STDIN it isn't working.
  The Reading Snippet</p>
  
  <pre><code>myFile: .asciz "sss.txt"
  InFileError: .asciz "Unable to open input file\n"
  InputFileHandle:.word 0
  
   @ ========= Open file for reading =============================
  ldr R0,=myFile        
  mov R1,#0       
  swi SWI_Open          @ open file
  bcs InFileError       @ if cannot open file branch to InFileError 
  ldr R1,=InputFileHandle
  str R0,[R1]
  ldr R0,=InputFileHandle
  ldr R0,[R0]
  swi SWI_ReadInt
  </code></pre>
  
  <p>The code doesn't work if I load R0 with #0 instead of Input File, which is supposed to be the file descriptor for STDIN. Please Help</p>