diff --git a/lib/include/prjxray/xilinx/bitstream_reader.h b/lib/include/prjxray/xilinx/bitstream_reader.h index 094371ad..35224bb9 100644 --- a/lib/include/prjxray/xilinx/bitstream_reader.h +++ b/lib/include/prjxray/xilinx/bitstream_reader.h @@ -84,9 +84,9 @@ class BitstreamReader { iterator end(); private: - static std::array kSyncWord; - const std::vector kWcfgCmd = {0x30008001, 0x1}; - const std::vector kNullCmd = {0x30008001, 0x0}; + static const std::array kSyncWord; + static const std::array kWcfgCmd; + static const std::array kNullCmd; std::vector words_; }; @@ -170,9 +170,19 @@ BitstreamReader::InitWithBytes(T bitstream) { // Sync word as specified in UG470 page 81 template -std::array BitstreamReader::kSyncWord{0xAA, 0x99, 0x55, +const std::array BitstreamReader::kSyncWord{0xAA, 0x99, 0x55, 0x66}; +// Writing the WCFG(0x1) command in type 1 packet with 1 word to the CMD register (0x30008001) +// Refer to UG470 page 110 +template +const std::array BitstreamReader::kWcfgCmd = {0x30008001, 0x1}; + +// Writing the NULL(0x0) command in type 1 packet with 1 word to the CMD register (0x30008001) +// Refer to UG470 page 110 +template +const std::array BitstreamReader::kNullCmd = {0x30008001, 0x0}; + template typename BitstreamReader::iterator BitstreamReader::begin() {