A TTL-RS232 level converter that connects via Grove
(using a similar design to the Mini CAN Unit: https://shop.m5stack.com/products/mini-can-unit-tja1051t-3)
S
Best posts made by Sereneto
-
[Product] RS232 in Grove Unit Format
-
[Product Revision] ATOMIC TF-Card Reader (A135) with G39/G38 exposed as Grove
ATOMIC TF-Card Reader A135, but expose pins G39 & G38 as an Grove port.
-
RE: [Product Revision] ATOMIC TF-Card Reader (A135) with G39/G38 exposed as Grove
@ifantus
An I2C SD card reader would be pretty neat and useful, don't think I've ever seen anyone do that. The bus isn't really meant for data like that, but if it were a logging only thing... I might play with that using my reader and a pair of Atoms.It would be important to minimized how much data is getting transmitted over I2C though; maybe limit file name length (8.3?) and character set (base ASCII?) possibly excluding anything in folders too (root only), may have to limit what sort of data can be written as well (or send start/stop bytes to encapsulate strings)
Functions could be something similar to this:
- Standard stuff dealing with card
- bool hasCard() # If a card is present
- type getType() # SD, SDHC, SDXC, etc
- void formatCard(format) # format the card using "format" (fat32)
- format getFormat() # get the current format of the card (fat32)
- uint32_t getCapacity() # get the capacity of the card in bytes
- uint32_t getSpace() # get the free space of the card in bytes
- Timestamps (no need for a battery or RTC, just use the internal clock)
- datetime getDTM() # get current datetime if set
- void setDTM(datetime) # set the datatime
- datetime getCreated(str path) # file/folder created date
- datetime getModified(str path) # file/folder modified date
- File/Folder Operations
- bool fileExists(str path) # if file exists
- bool folderExists(str path) # if folder exists
- bool createFolder(str path) # create new folder(s) from path
- bool createFile(str path) # create new file (& parent folder(s)) from path
- bool move(str path, str path) # move folder/file
- bool rename(str path, str name) # rename folder/file
- bool delete(str path) # delete folder/file
- bool deleteBefore(str path, datetime) # delete any folder/file at path before certain date
- bool deleteWildcard(str path, str pattern) # delete any folder/file at path matching a simple pattern
- Data (two ways, just pushing data, might be problematic due to length, or chunking into columns with smaller data)
- bool append(str path, str/int/float data) # append data to file
- bool newline(str path) # start a new data line in the specified file
- bool column(str path, int column, str/int/float data) # write data to new line (columns must be in order)
- bool return(str path) # end writing to new data line (set modified date)
- bool truncate(str path) # clear file
- Other
- void setAddress(int address) # set I2C address
- uint16_t getFirmware() # get current firmware version
- Standard stuff dealing with card