F´ Flight Software - C/C++ Documentation NASA-v1.6.0
A framework for building embedded system applications to NASA flight quality standards.
Loading...
Searching...
No Matches
CRCChecker.hpp
Go to the documentation of this file.
1// ======================================================================
2// \title CRCChecker.hpp
3// \author ortega
4// \brief hpp file for a crc32 checker
5//
6// \copyright
7// Copyright 2009-2020, by the California Institute of Technology.
8// ALL RIGHTS RESERVED. United States Government Sponsorship
9// acknowledged.
10// ======================================================================
11
12#ifndef CRC_CHECKER_HPP
13#define CRC_CHECKER_HPP
14
15#include <FpConfig.hpp>
16
17namespace Utils {
18
20 static const U32 CRC_MAX_FILENAME_SIZE = 128; // TODO use a config variable
21
22 typedef enum
23 {
35
36 crc_stat_t create_checksum_file(const char* const filename);
37 crc_stat_t read_crc32_from_file(const char* const fname, U32 &checksum_from_file);
38 crc_stat_t verify_checksum(const char* const filename, U32 &expected, U32 &actual);
39
40}
41
42#endif
PlatformIntType NATIVE_INT_TYPE
Definition BasicTypes.h:51
C++-compatible configuration header for fprime configuration.
crc_stat_t read_crc32_from_file(const char *const fname, U32 &checksum_from_file)
crc_stat_t create_checksum_file(const char *const fname)
static const U32 CRC_MAX_FILENAME_SIZE
crc_stat_t verify_checksum(const char *const fname, U32 &expected, U32 &actual)
@ FAILED_FILE_READ
@ FAILED_FILE_CRC_WRITE
@ PASSED_FILE_CRC_WRITE
@ FAILED_FILE_CRC_CHECK
@ FAILED_FILE_CRC_READ
@ PASSED_FILE_CRC_CHECK
@ FAILED_FILE_CRC_OPEN
@ FAILED_FILE_SIZE_CAST
@ FAILED_FILE_SIZE
@ FAILED_FILE_OPEN
static const NATIVE_INT_TYPE CRC_FILE_READ_BLOCK