This commit is contained in:
Nav
2024-07-07 17:50:43 +01:00
parent 1514e89889
commit 3d6e86244b
3 changed files with 4 additions and 9 deletions

View File

@@ -13,9 +13,10 @@ class Signature
throw new \Exception("Cannot generate hex string of incomplete AVR8 target signature."); throw new \Exception("Cannot generate hex string of incomplete AVR8 target signature.");
} }
return '0x' . substr('0' . dechex($this->byteZero), -2) return '0x' . strtoupper(
substr('0' . dechex($this->byteZero), -2)
. substr('0' . dechex($this->byteOne), -2) . substr('0' . dechex($this->byteOne), -2)
. substr('0' . dechex($this->byteTwo), -2) . substr('0' . dechex($this->byteTwo), -2)
; );
} }
} }

View File

@@ -63,13 +63,6 @@ class ValidationService
if (empty($tdf->addressSpaces)) { if (empty($tdf->addressSpaces)) {
$failures[] = 'Missing address spaces'; $failures[] = 'Missing address spaces';
} elseif (count($tdf->addressSpaces) > 256) {
/*
* We store address space IDs in an std::uint8_t - which should be more than enough (I don't think we'll
* ever support a target with more than 256 address spaces).
*/
$failures[] = 'Too many address spaces (' . count($tdf->addressSpaces) . ')';
} }
$processedAddressSpaceKeys = []; $processedAddressSpaceKeys = [];

View File

@@ -11,6 +11,7 @@ use Targets\TargetDescriptionFiles\TargetFamily;
require_once __DIR__ . '/FromXmlService.php'; require_once __DIR__ . '/FromXmlService.php';
require_once __DIR__ . '/ToXmlService.php'; require_once __DIR__ . '/ToXmlService.php';
require_once __DIR__ . '/../../TargetDescriptionFile.php'; require_once __DIR__ . '/../../TargetDescriptionFile.php';
require_once __DIR__ . '/../../AVR8/Avr8TargetDescriptionFile.php';
require_once __DIR__ . '/Exceptions/XmlParsingException.php'; require_once __DIR__ . '/Exceptions/XmlParsingException.php';