rom_iap: Clean up comments and realign with spaces.

This commit is contained in:
Martin Ling
2022-06-27 12:29:55 +01:00
parent 1acc71bebf
commit a66492b8b7

View File

@ -24,51 +24,50 @@
#include <stdint.h> #include <stdint.h>
typedef enum typedef enum {
{
/* TODO define other commands */ /* TODO define other commands */
IAP_CMD_INIT_IAP = 49, IAP_CMD_INIT_IAP = 49,
/* Command Init IAP /* Command Init IAP
Input Command code: 49 (decimal) Input: Command code: 49 (decimal)
Return Code CMD_SUCCESS Return Code: CMD_SUCCESS
Result None Result: None
Description Initializes and prepares the flash for erase and write operations. Description Initializes and prepares the flash for erase and write operations.
Stack usage 88 B */ Stack usage 88 B */
IAP_CMD_READ_PART_ID_NO = 54, IAP_CMD_READ_PART_ID_NO = 54,
/* Read part identification number /* Read part identification number
Command Read part identification number Input: Command code: 54 (decimal)
Input Command code: 54 (decimal)
Parameters:None Parameters:None
Return Code CMD_SUCCESS | Return Code: CMD_SUCCESS
Result Result0:Part Identification Number. Result Result0:Part Identification Number.
Result1:Part Identification Number. Result1:Part Identification Number.
Description This command is used to read the part identification number. See Table 1082 Description: This command is used to read the part identification number. See Table 1082
LPC43xx part identification numbers. 'LPC43xx part identification numbers'. The command returns two words: word0
The command returns two words: word0 followed by word1. Word 0 corresponds followed by word1. Word 0 corresponds to the part id and word1 indicates the flash
to the part id and word1 indicates the flash configuration or contains 0x0 for configuration or contains 0x0 for flashless parts.
flashless parts. Stack usage: 8 B */
Stack usage 8 B */
IAP_CMD_READ_SERIAL_NO = 58 IAP_CMD_READ_SERIAL_NO = 58
/* Read device serial number /* Read device serial number
Input Command code: 58 (decimal) Input: Command code: 58 (decimal)
Parameters: None Parameters: None
Return Code CMD_SUCCESS Return Code: CMD_SUCCESS
Result Result0:First 32-bit word of Device Identification Number (at the lowest address) Result: Result0: First 32-bit word of Device Identification Number (at the lowest address)
Result1:Second 32-bit word of Device Identification Number Result1: Second 32-bit word of Device Identification Number
Result2:Third 32-bit word of Device Identification Number Result2: Third 32-bit word of Device Identification Number
Result3:Fourth 32-bit word of Device Identification Number Result3: Fourth 32-bit word of Device Identification Number
Description This command is used to read the device identification number. The serial number Description: This command is used to read the device identification number. The serial number
may be used to uniquely identify a single unit among all LPC43xx devices. may be used to uniquely identify a single unit among all LPC43xx devices.
Stack usage 8 B */ Stack usage: 8 B */
} iap_cmd_code_t; } iap_cmd_code_t;
/* ISP/IAP Return Code */ /* ISP/IAP Return Code */
typedef enum typedef enum
{ {
CMD_SUCCESS = 0x00000000, /* CMD_SUCCESS Command is executed successfully. Sent by ISP handler only when command given by the host has been completely and successfully executed. */ CMD_SUCCESS = 0x00000000, /* CMD_SUCCESS Command is executed successfully.
Sent by ISP handler only when command given by the host has been completely and successfully executed. */
INVALID_COMMAND = 0x00000001, /* Invalid command. */ INVALID_COMMAND = 0x00000001, /* Invalid command. */
SRC_ADDR_ERROR = 0x00000002, /* Source address is not on word boundary. */ SRC_ADDR_ERROR = 0x00000002, /* Source address is not on word boundary. */
DST_ADDR_ERROR = 0x00000003, /* Destination address not on word or 256 byte boundary. */ DST_ADDR_ERROR = 0x00000003, /* Destination address not on word or 256 byte boundary. */