Android Tutorial .Net FileTransfer - Implement AsyncStreams Prefix mode

The attached C# project, implements the new stream protocol of AsyncStreams.
Relevant tutorials:
AsyncStreams Tutorial
FileTransfer - Send and receive files with AsyncStreams

This project allows you to connect the desktop to the FileTransfer app:



Note that the desktop doesn't open a server. So it can only connect to the device.

The SharpZipLib library, which is included in the zip file, is required for the checksum calculation.

There is a single change that needs to be done in device FileTransfer app:
AsyncStreams should use little endian instead of big endian. This is done by setting the second parameter of astream.InitializePrefix to False (Sub StartAStream).

The C# source code and executable are attached.


    81.2 KB · Views: 4,500


Licensed User
Longtime User
Thnx for your answer, really helpful stuff. Just for the sake of it, i was able to to run the C# desktop server without problem using mono on a Linux machine (without B4J). Having said that, B4J is the way to go from now onwards. Again, if someone has transfered the server code to python and would like to share it, i'd be grateful.