| 177 | } |
| 178 | |
| 179 | std::vector<String> split_string(String str, char c) { |
| 180 | std::vector<String> cols{}; |
| 181 | size_t start = 0; |
| 182 | |
| 183 | while (start < str.length()) { |
| 184 | auto it = str.indexOf(c, start); |
| 185 | |
| 186 | if (it == -1) break; |
| 187 | |
| 188 | cols.emplace_back(&str[start], it - start); |
| 189 | start = it + 1; |
| 190 | } |
| 191 | |
| 192 | if (start <= str.length() && !str.isEmpty()) cols.emplace_back(&str[start], str.length() - start); |
| 193 | |
| 194 | return cols; |
| 195 | } |
| 196 | |
| 197 | KeeloqKeystore::KeeloqKeystore(FS *fs) { |
| 198 | File keystore = fs->open("/mfcodes"); |