Hello All, i'm working on a project which requires a mobile device to be connected to an usb serial cable and which receives text strings from a gps device, the mobile re-sends the data received to a TCP server.
All of this works just the way it should with the exception that i now need to implement a feature where if the mobile's mobile connection or wifi connection drops, the data being received should be saved to a temporary file, and when the mobile device re-gains connection it should start re-sending the saved data saved in the temp file.
The issue i'm having is that while trying to save the information received, it doesn't save all the information, for example i'm using a program called Tera Term which is a serial terminal which can send and receive information via a serial port to and from a pc or mobile device.
The text file i'm using to send the data to the mobile via the USB library contains 52,946 bytes, i send line by line to the device.
I'm using Erel's AsyncStreamText class which makes it easier to handle this kind of data since is pure text data.
I know for a fact that the information from the file is being received on the device since i can log every single line being received, the problem is when i try to save every single line received on a text file.
When i open the text file where the data should be saved, everytime only 40,960 bytes are saved, i can't figure out why this is, if anyone here please could maybe point me in the right direction i will really appreciate it, to me it sounds by the amounts of bytes written on the file (40,960) as if there's a limitation or a buffer that can maybe be expanded somehow.
Maybe Erel can comment on this, i really need to able to saved any amount of data coming through the usb port on the device.
Thanks All!
Walter
All of this works just the way it should with the exception that i now need to implement a feature where if the mobile's mobile connection or wifi connection drops, the data being received should be saved to a temporary file, and when the mobile device re-gains connection it should start re-sending the saved data saved in the temp file.
The issue i'm having is that while trying to save the information received, it doesn't save all the information, for example i'm using a program called Tera Term which is a serial terminal which can send and receive information via a serial port to and from a pc or mobile device.
The text file i'm using to send the data to the mobile via the USB library contains 52,946 bytes, i send line by line to the device.
I'm using Erel's AsyncStreamText class which makes it easier to handle this kind of data since is pure text data.
I know for a fact that the information from the file is being received on the device since i can log every single line being received, the problem is when i try to save every single line received on a text file.
When i open the text file where the data should be saved, everytime only 40,960 bytes are saved, i can't figure out why this is, if anyone here please could maybe point me in the right direction i will really appreciate it, to me it sounds by the amounts of bytes written on the file (40,960) as if there's a limitation or a buffer that can maybe be expanded somehow.
Maybe Erel can comment on this, i really need to able to saved any amount of data coming through the usb port on the device.
Thanks All!
Walter