File over Bluetooth

Hi,

My project is based on reading the file from a SD card and sending the data over bluetooth to an Android device paired with it. I am using an ESP32 DEV module which has an inbuilt bluetooth. The problem is , I am able to transfer the file only character by character which is consuming more time and some time i receive junk values in the android device. Is their any way to transfer the whole file via bluetooth from esp32 to android device , like usual file transfer between android device to android device via bluetooth.
thank you....

Post your program so we can see what you have been trying.

...R

Is their any way to transfer the whole file via bluetooth from esp32 to android device

Certainly. You are doing it now. The ONLY way to send a file, no matter what the communication medium is, is byte-by-byte. Unless the communication medium is snail mail where you send the physical device containing the file...

I'm going to guess that you are literally reading one byte and writing one byte, over and over, until the complete file has been sent.

You CAN read multiple bytes from a file using a single call to read() and you CAN send multiple bytes at once using write(). But, are you? That MIGHT speed things up.

The DumpFile example included in the IDE has all you need. Almost any bluetooth terminal programme can log a file. You can have several files in the one log as the name sent serves to identify them.

is there any protocol for sending whole file via bluetooth like it does in the case of android device to android device ... ?

hi
i am using an ESP32 dev module and im trying to read a text file from the SD card connected to it via SPI and send the data through Bluetooth to an android device. I am able to read SD card and also able to send it through bluetooth. but the problem is the bluetooth is send the file character by character and it takes much time. Is there any possible way to transfer the whole file via bluetooth as normally done in android device to device...?

but the problem is the bluetooth is send the file character by character and it takes much time.

Bluetooth can only ever send one character at a time, like any other serial link.

How big is the file and how long is it taking?

kamalesh:
protocol

You are just using buzzwords. You clearly have not looked at the DumpFile example. Now might be a good time to do so.

Grumpy_Mike:
Bluetooth can only ever send one character at a time, like any other serial link.

How big is the file and how long is it taking?

Beware. OP is cross-posting.

.

@kamalesh. Don´t cross post. Threads merged.