2.9.1.10.1 Command List

Table 2-29. SAM-BA Monitor Commands
CommandActionArgument(s)Example
NSet Normal modeNo argumentN#
TSet Terminal modeNo argumentT#
OWrite a byteAddress, Value#O200001,CA#
oRead a byteAddress,#o200001,#
HWrite a halfwordAddress, Value#H200002,CAFE#
hRead a halfwordAddress,#h200002,#
WWrite a wordAddress, Value#W200000,CAFEDECA#
wRead a wordAddress,#w200000,#
SSend a fileAddress,NbOfBytes#S200000,1234#
RReceive a fileAddress, NbOfBytes#R200000,1234#
GGoAddress#G200200#
VDisplay versionNo argumentV#
  • Mode commands:
    • Normal mode configures the SAM-BA Monitor to send/receive data in binary format.
    • Terminal mode configures the SAM-BA Monitor to send/receive data in ASCII format.
  • Write commands: Writes a byte (O), a halfword (H) or a word (W) to the target.
    • Address: address in hexadecimal.
    • Value: byte, halfword or word to write in hexadecimal.
    • Output: ‘>’.
  • Read commands: Reads a byte (o), a halfword (h) or a word (w) from the target.
    • Address: address in hexadecimal.
    • Output: the byte, halfword or word read in hexadecimal followed by ‘>’.
  • Send a file (S): The host will send a buffer of data to be stored at a specified address in the device.
    • Address: address in hexadecimal
    • NbOfBytes: number of bytes (in hexadecimal format) to be received from the host.
    • Output: ‘>’.
      Note: A timeout on this command is reached when the prompt ‘>’ appears before the end of the command execution.
  • Receive a file (R): The host requests to read a buffer of data from a specified address in the device.
    • Address: address in hexadecimal.
    • NbOfBytes: number of bytes (in hexadecimal format) to be sent to the host.
    • Output: ‘>’.
  • Go (G): Jumps to a specified address and executes the code.
    • Address: address to jump to in hexadecimal.
    • Output: ‘>’ once returned from the program execution. If the executed program does not manage the link register and does not return, the prompt is not displayed.
  • Get ROM code version (V): Returns the ROM code version.
    • Output: version, date and time of ROM code followed by ‘>’.