2016-09-19 01:18:11 +00:00
|
|
|
//
|
|
|
|
// File.hpp
|
|
|
|
// Clock Signal
|
|
|
|
//
|
|
|
|
// Created by Thomas Harte on 18/09/2016.
|
|
|
|
// Copyright © 2016 Thomas Harte. All rights reserved.
|
|
|
|
//
|
|
|
|
|
2017-09-23 02:39:23 +00:00
|
|
|
#ifndef StaticAnalyser_Acorn_File_hpp
|
|
|
|
#define StaticAnalyser_Acorn_File_hpp
|
2016-09-19 01:18:11 +00:00
|
|
|
|
|
|
|
#include <memory>
|
|
|
|
#include <string>
|
|
|
|
#include <vector>
|
|
|
|
|
2018-01-25 02:48:44 +00:00
|
|
|
namespace Analyser {
|
|
|
|
namespace Static {
|
2016-09-19 01:18:11 +00:00
|
|
|
namespace Acorn {
|
|
|
|
|
|
|
|
struct File {
|
|
|
|
std::string name;
|
|
|
|
uint32_t load_address;
|
|
|
|
uint32_t execution_address;
|
|
|
|
bool is_protected;
|
|
|
|
std::vector<uint8_t> data;
|
|
|
|
|
|
|
|
struct Chunk {
|
|
|
|
std::string name;
|
|
|
|
uint32_t load_address;
|
|
|
|
uint32_t execution_address;
|
|
|
|
uint16_t block_number;
|
|
|
|
uint16_t block_length;
|
|
|
|
uint8_t block_flag;
|
|
|
|
uint32_t next_address;
|
|
|
|
|
|
|
|
bool header_crc_matched;
|
|
|
|
bool data_crc_matched;
|
|
|
|
std::vector<uint8_t> data;
|
|
|
|
};
|
|
|
|
|
2018-01-24 03:18:16 +00:00
|
|
|
std::vector<Chunk> chunks;
|
2016-09-19 01:18:11 +00:00
|
|
|
};
|
|
|
|
|
2018-01-25 02:48:44 +00:00
|
|
|
}
|
2016-09-19 01:18:11 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
#endif /* File_hpp */
|