mirror of
https://git.intern.spaceteamaachen.de/ALPAKA/driver-w25qxxx.git
synced 2025-09-29 00:37:33 +00:00
A couple of bugfixes
This commit is contained in:
@@ -81,10 +81,10 @@ namespace sta
|
||||
uint32_t address_;
|
||||
|
||||
uint8_t buffer_[W25QXX_PAGE_SIZE];
|
||||
uint8_t ptr_;
|
||||
uint32_t ptr_;
|
||||
};
|
||||
} // namespace sta
|
||||
|
||||
#include <sta/utils/logger.tpp>
|
||||
|
||||
#endif // STA_UTILS_LOGGER_HPP
|
||||
#endif // STA_UTILS_LOGGER_HPP
|
||||
|
@@ -49,7 +49,7 @@ namespace sta
|
||||
|
||||
// Convert the data to a byte array.
|
||||
uint8_t * bytes = reinterpret_cast<uint8_t*>(&data);
|
||||
uint8_t length = sizeof(T);
|
||||
uint32_t length = sizeof(T);
|
||||
|
||||
// Bytes remaining until the page is full.
|
||||
uint8_t remaining = W25QXX_PAGE_SIZE - ptr_;
|
||||
@@ -89,14 +89,6 @@ namespace sta
|
||||
ptr_ = 0;
|
||||
|
||||
flash_->sectorErase(address_);
|
||||
|
||||
/*
|
||||
for (uint32_t i = start_; i < end_; i++)
|
||||
{
|
||||
flash_->sectorErase(i * W25QXX_SECTOR_SIZE);
|
||||
}
|
||||
|
||||
*/
|
||||
}
|
||||
|
||||
template <typename T>
|
||||
|
Reference in New Issue
Block a user