readSiblingText

abstract suspend fun readSiblingText(treeUri: CommonUri, fileName: String): String?(source)

Reads a file sitting alongside the documents in treeUri, or null when it is absent or unreadable.

Used to read INFO_UF2.TXT off a mounted UF2 bootloader volume before writing to it. That file both identifies the board (Board-ID:) and reports the installed SoftDevice, and its mere presence is positive proof the picked volume really is an Adafruit-family UF2 bootloader drive rather than, say, Downloads.

Requires a tree URI (ACTION_OPEN_DOCUMENT_TREE); a single-document URI grants no sibling access.