diff --git a/src/Targets/Microchip/AVR/AVR8/Avr8.cpp b/src/Targets/Microchip/AVR/AVR8/Avr8.cpp index 9d0de5b6..db810b1f 100644 --- a/src/Targets/Microchip/AVR/AVR8/Avr8.cpp +++ b/src/Targets/Microchip/AVR/AVR8/Avr8.cpp @@ -69,7 +69,6 @@ namespace Bloom::Targets::Microchip::Avr::Avr8Bit void Avr8::postActivationConfigure() { if (!this->targetDescriptionFile.has_value()) { - this->loadTargetDescriptionFile(); this->initFromTargetDescriptionFile(); } @@ -572,15 +571,12 @@ namespace Bloom::Targets::Microchip::Avr::Avr8Bit return this->programmingSession.has_value(); } - void Avr8::loadTargetDescriptionFile() { + void Avr8::initFromTargetDescriptionFile() { this->targetDescriptionFile = TargetDescription::TargetDescriptionFile( this->getId(), (!this->name.empty()) ? std::optional(this->name) : std::nullopt ); - } - void Avr8::initFromTargetDescriptionFile() { - assert(this->targetDescriptionFile.has_value()); this->name = this->targetDescriptionFile->getTargetName(); this->family = this->targetDescriptionFile->getFamily(); @@ -590,13 +586,13 @@ namespace Bloom::Targets::Microchip::Avr::Avr8Bit if (!this->targetParameters->stackPointerRegisterLowAddress.has_value()) { throw Exception( - "Failed to load sufficient AVR8 target paramters - missting stack pointer start address" + "Failed to load sufficient AVR8 target parameters - missing stack pointer start address" ); } if (!this->targetParameters->statusRegisterStartAddress.has_value()) { throw Exception( - "Failed to load sufficient AVR8 target parameters - missting status register start address" + "Failed to load sufficient AVR8 target parameters - missing status register start address" ); } diff --git a/src/Targets/Microchip/AVR/AVR8/Avr8.hpp b/src/Targets/Microchip/AVR/AVR8/Avr8.hpp index e818cc93..75782abe 100644 --- a/src/Targets/Microchip/AVR/AVR8/Avr8.hpp +++ b/src/Targets/Microchip/AVR/AVR8/Avr8.hpp @@ -29,7 +29,6 @@ namespace Bloom::Targets::Microchip::Avr::Avr8Bit explicit Avr8() = default; Avr8(std::string name, const TargetSignature& signature): name(std::move(name)) { this->id = signature; - this->loadTargetDescriptionFile(); this->initFromTargetDescriptionFile(); }; @@ -149,11 +148,6 @@ namespace Bloom::Targets::Microchip::Avr::Avr8Bit std::optional programmingSession; - /** - * Resolves the appropriate TDF for the AVR8 target and populates this->targetDescriptionFile. - */ - void loadTargetDescriptionFile(); - /** * Initiates the AVR8 instance from data extracted from the TDF. */