File transfer process

I can find lots of info on reading data over Bluetooth, but nothing on simple file transfers. What's the simplest process to just move a file from an Arduino's SD card to an app-specific location on an Android device?
(In the short term, the file is likely to be a csv, but I'm interested in the process for other files longer term.)

Hello Idris

Depends on the capability of the Arduino you are using, and where the kit is to be used. For example, if it is going to be used inside a building that has access to the internet, you could use WiFi to upload the file to the Cloud and download from there to an App's ASD folder. Also with WiFi or Bluetooth, you could stream the content of the file to an App, which could in turn stream it to a file in the App's ASD.

Have you consulted these examples?

1 Like

Thanks Chris
I was thinking of xfer via Bluetooth (Classic). Probably somethign like an HC05.
I'm sure I'll find out soon enough when I search for "streaming" what that involves.

Thanks Juan
I'll have a look at those.

via Bluetooth Classic, it means sending the file in chunks of 20 bytes. That can be much better using BLE (244 bytes), but you need hardware that can have the MTU set as required.

ProfessorCad: Tips & Tricks Bluetooth

Looking at Juan's example ...

... I've not had time to go through the code properly, but I can't see anything about 20 bytes vs 244 bytes in it. Am I missing something g obvious, or is it just related to something like xfer speed?

In this example I use a text file pozo_4.txt of 5.2 KB, it is the Base64 encoding of an image file.

Hi Juan
Yeah, I saw that. (Not that I've got my head round what Base64 is yet. :smiley: )
Is that conversion related to the 20 bytes vs 244 bytes of BLE?

No, the conversion to Base64 is due to the fact that an image is going to be sent. If you want to send text you don't need Base64.