rudimentary SD commanding interface
All checks were successful
EIVE/eive-obsw/pipeline/pr-develop This commit looks good

This commit is contained in:
2022-09-27 10:51:07 +02:00
parent 9b6636fe31
commit 90962c9f8e
11 changed files with 226 additions and 248 deletions

View File

@ -543,13 +543,13 @@ ReturnValue_t StrHelper::checkReplyPosition(uint32_t expectedPosition) {
#ifdef XIPHOS_Q7S
ReturnValue_t StrHelper::checkPath(std::string name) {
if (name.substr(0, sizeof(config::SD_0_MOUNT_POINT)) == std::string(config::SD_0_MOUNT_POINT)) {
if (!sdcMan->isSdCardMounted(sd::SLOT_0)) {
if (!sdcMan->isSdCardUsable(sd::SLOT_0)) {
sif::warning << "StrHelper::checkPath: SD card 0 not mounted" << std::endl;
return SD_NOT_MOUNTED;
}
} else if (name.substr(0, sizeof(config::SD_1_MOUNT_POINT)) ==
std::string(config::SD_1_MOUNT_POINT)) {
if (!sdcMan->isSdCardMounted(sd::SLOT_0)) {
if (!sdcMan->isSdCardUsable(sd::SLOT_0)) {
sif::warning << "StrHelper::checkPath: SD card 1 not mounted" << std::endl;
return SD_NOT_MOUNTED;
}