roboot/boot/roboot.h File Reference


Detailed Description

Declaration of the ROBOOT interface.

License:
ROBOOT ver. 0.1.0 - Copyright (C) 2010 AGH UST
This file is part of the ROBOOT (RObus BOOTloader) project. ROBOOT is developed at the Department of Electronics, AGH University of Science and Technology in Krakow, Poland.

The ROBOOT project uses dual-licensing. You can use it for free for non-commercial, open source projects. See license.txt for details or visit project home page at http://www.wsn.agh.edu.pl/?q=roboot

THIS SOFTWARE IS PROVIDED 'AS IS'. NO WARRANTIES, WHETHER EXPRESS, IMPLIED OR STATUTORY, INCLUDING, BUT NOT LIMITED TO, IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE APPLY TO THIS SOFTWARE. AGH UST SHALL NOT, IN ANY CIRCUMSTANCES, BE LIABLE FOR SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, FOR ANY REASON WHATSOEVER.

Author:
Artur Lipowski, Ɓukasz Krzak
Purpose:
ROBOOT
Compiler:
GCC
Hardware:
independent
Documented in:
doxygen
Comments:

Definition in file roboot.h.

#include <stdint.h>
#include <stdbool.h>
#include "roboot_config.h"
#include "roboot_if_flash.h"
#include "roboot_if_device.h"

Go to the source code of this file.

Defines

#define ROBOOT_VER_HI   2
 ROBOOT version (high number).
#define ROBOOT_VER_LO   0
 ROBOOT version (low number).
#define ROBOOT_INTERNAL_ERROR   -1
 Error code: Internal error.
#define ROBOOT_FLS_UNLOCK_ERROR   -2
 Error code: Unable to unlock FLASH memory.
#define ROBOOT_FLS_ERASE_ERROR   -3
 Error code: Unable to erase FLASH memory sector.
#define ROBOOT_FLS_WRITE_ERROR   -4
 Error code: Unable to write into FLASH memory.
#define ROBOOT_IMG_VERSION_ERROR   -5
 Error code: Bad image version.
#define ROBOOT_IMG_HASH_MATCH_ERROR   -6
 Error code: Hash mismatch.
#define ROBOOT_IMG_CIPHER_MATCH_ERROR   -7
 Error code: Cipher key mismatch.
#define ROBOOT_IMG_ACIPHER_MATCH_ERROR   -8
 Error code: Asymetric Cipher key mismatch.
#define ROBOOT_IMG_DEVKEY_LEN_ERROR   -9
 Error code: Device Key length mismatch.
#define ROBOOT_IMG_CHECK_TYPE_ERROR   -10
 Error code: Check type mismatch.
#define ROBOOT_IMG_DEV_VERSION_ERROR   -11
 Error code: Device version mismatch.
#define ROBOOT_IMG_APP_VERSION_ERROR   -12
 Error code: Application version mismatch.
#define ROBOOT_IMG_DEV_ID_ERROR   -13
 Error code: Device ID mismatch.
#define ROBOOT_IMG_CHECK_FM_ERROR   -14
 Error code: File magic mismatch.
#define ROBOOT_IMG_CHECK_DM_ERROR   -15
 Error code: Device magic mismatch.
#define ROBOOT_IMG_SM_ERROR   -16
 Error code: Section magic mismatch.
#define ROBOOT_IMG_SECTION_CRC_ERROR   -17
 Error code: Section CRC mismatch.

Enumerations

enum  ROBOOT_ProcesingStage_T {
  ROBOOT_PS_FILE_END, ROBOOT_PS_FILE_MAGIC, ROBOOT_PS_DEV_MAGIC, ROBOOT_PS_CRYPTO_KEY,
  ROBOOT_PS_CHECK_AREA, ROBOOT_PS_SECTION_HEADER, ROBOOT_PS_SECTION_DATA
}

Functions

uint8_t * ROBOOT_InitProcessing (const ROBOOT_FLASH_Operations_T *flash_oper)
int8_t ROBOOT_ProcessPacket (uint32_t size, uint8_t **new_buf)
const uint8_t * ROBOOT_GetFileMagic (void)
const uint8_t * ROBOOT_GetDeviceMagic (void)
const uint8_t * ROBOOT_GetUserData (void)
uint8_t ROBOOT_GetHashType (void)
uint8_t ROBOOT_GetCipherType (void)
bool ROBOOT_IsAsymetricKeyCipherUsed (void)
uint32_t ROBOOT_GetNumberOfSections (void)


Generated on Tue Mar 9 07:57:32 2010 for 'ROBOOT' by  doxygen 1.5.8