File Transfer using AllJoyN from Android to Windows - alljoyn

This question is regarding file transfer using AllJoyN
I am using the basic_client & basic_service files for Windows 64 Bit desktop machine and I was able to build and run it successfully to transfer files from Client to Service.
Also I am able to transfer files between two phones in Android using the Android sdk with the FIle Transfer sample provided which in turn uses the FileTransferComponent.
Now I am trying to make the discovery part work for the Android devices and the Desktop. THe desktop discovers the Android device but the Android device wont discover the desktop client. Could you please let me know what I am doing wrong here?
Also the file transfer modules(Like OfferFile,RequestOffer) are handled by the bus in Android whereas in Windows client, there is a FileTransfer interface implemented for the same to transfer data using input-output stream. Could you please help me understand how I can achieve the same filetransfer between the two clients when their implementation is different? Or should I use a different mechanism for this purpose?
Awaiting your reply

Related

Could not find Biometric system that could send data directly to web server

I need a biometric (RFID or FINGER PRINT or face recognition) system which could consume web api directly - being independent of third party. I got some CAMS biometric unit and ZKTECO K20 pro model these could send data to server but we must go through their data server and need to expose the API. I want biometric system that could send activity data to my server.
This is required to develop a system to control attendance of branches from cooperate office. Here I need some suggestion of biometric system. I got
You can install a biometric device with its default software on your computer. The software stores the attendance data in your local database. You can develop a software to read the data from the local database and update your server on a schedule.
Online SDK is restricted from the manufacturers as it may lead to the security issues. As it is online based, anyone can access the anyone's biometric device if the online SDK has been exposed. So it is kept as confidential by the manufacturers CAMS and ZKTeco.
You can make your CAMS devices to communicate with your server directly, Below is the text snippet taken from their API documentation link: http://camsunit.com/application/biometric-web-api.html
Want to receive data without coming through CAMS Dataserver?
Yes. We provide the windows lite version protocol engine which should be
installed at your windows server. Once its installed, You web api
endpoints will start getting triggered whenever attendance is
registered at the device

Windows 10 GattService and SmartGattLib on Android

I am trying to have Android running the example on
https://github.com/movisens/SmartGattLib
and write a Win10 client to act as a device to be discovered by SmartGattLib.
However, it's either my Win10 or the GattService API has a problem... My Win10 paired with the Android device, but the SmartGattLib sample program discovered on Win10 once (which I think it's impossible).
And with my Win10 + Dell M3800, I haven't figured out how to use the GattService API to write a client to publish advertisement or something to get my SmartGattLib noticed.
What have I done wrong? Is GattService API supposed to be able to advertise? Is it I am wrong conceptually, that Windows 10 cannot be a Gatt client?
Thanks

Is it possible to push data from the server to the client (phone, computer) without OS integration

is there a way for a server to push some data to a client, wirelessly and seamlessly, which may be Windows(Phone), iPhone, Mac, or Android device, without any OS integration?
If so, what's the best design pattern to do this, and what are the best technologies to go about this?
Push technology is simply a methodology of the server initiating the transfer of data, rather than the client asking the server for it.
Apple makes push technology relatively easy to use by providing such functionality built-in on the OS. As well as Android through the Google Cloud Messaging for Android. Windows, however, does not.
Apple push notifications and Google's messaging for Android is seemingly magical and/or functionality that the OS needs to handle; however, this isn't necessarily the case. The advantage of having it "integrated" in the OS, is the same as having a framework handle the functionality for you.
Speaking in technical terms, push technology is a long-lived connection from the client to the server that accepts messages. These messages would be considered pushed messages, since the client did not make an individual request for them.
The main thing to keep in mind when implementing push technology yourself, is that the client is in charge of keeping that long-lived connection alive as much as possible. Because client IP addresses can change between disconnects, servers are not guaranteed that a client's address will be persistent across disconnects. Moreover, clients can be connected from behind a firewall, making it impossible for a server to reach the client.
For comparison, pull technology is the more traditional process of a client connecting to a server and requesting data.
Your best bet for Apple iOS will be using their push notification service.
For Android devices you should use the Google Cloud Messaging for Android. Alternatively, you can create your own background service to handle the messaging; here's a guide.
For Windows (desktop at least), you will have to create your own service to perform such duty. Here's an MSDN guide explaining how to create a Windows Service using Visual Studio (VB and C#). There might be frameworks already built that handle such messaging on Windows, however, I don't know of any.
Use WebSocket (with or without socket.io).
In the future, you could use WebRTC.
With Websockets, the setup is really simple. The client (a user agent, like a browser or a WebView) connects to the Websocket server, over http(s) (less problems with firewalls) and that's it. There's a bidirectional socket with an event-based API.
If by "OS integration" you mean "write special code for each platform" then the answer is no.
As you mentioned, you would like file system access, and background processing. That combination is not available in a cross-platform way at this moment.
If by "OS integration" you meant "without having to wait for apple/google/ms to provide the ability" then the answer is yes/maybe.
All the popular platforms have Push notifications and background processing support, as long as you code it the way each particular platform expects it.
But file system access will be limited to what restrictions the platform places on you. For instance in ios and win8(phone) there is no wy to write or read a file outside of your own apps private file structure. For security reasons, you cannot access the file system of other apps.
UPDATE:
The general pattern here is to release an app for every platform you want to support.
The app will register itself with its respective platform's push notification service.
You will write generic server side code to accept the data you want to push to all your client devices. Then you will invoke the respective push API's for each platform you support, causing the client devices to wake up and trigger the app that you provided to respond.
When the app opens, you get the app to contact your server and download the full data "the push notification being just the wakeup call for your app"
This way you can easily tell how which of your devices have received the data.
Each platform specific app must save the data to its own local storage and provide a way for the data to be shared via the methods supported by its respective platform.
On IOS it can be as simple as supporting the "Open In.." paradigm.
On W8Phone, you'll have to publish the data via one of the available "sharing contracts"
And so forth for every platform you want to support.
This is the general pattern at the moment. There are some caveats. On IOS, the app will nt automatically start when a push notification is received. This means your app will only download the whole of the data when the app is opened by the user.
A mobile app also cannot generally run indefinitely in the background. This means that once the app is started, you have a limited window for push notifications to be automatically processed by your app. After the allowed "background time". The app will close and any push notifications beep on the device, but wont open the app until the user taps on one of the notifications or opens the app directly.
Technically you could use XMPP Libraries, it is meant for implementing chat system (msn, gtalk, facebook chat, etc...) but this could work well as a push message system because it is opensource and well built to handle all the cases you never thought of. Also you could host your own server and send push message that way...
Why not use a webservice? In my previous project I used webservice to deliver data from mysql database. The webservice I used was nusoap. On the client side I used kSoap library for Android. Hope this helps.
if you want to receive and send real time communication between a server and client (irrespective of the device or OS), i would highly recommend you use XMPP technology because it is designed for the sort of things you're asking for.
The Extensible Messaging and Presence Protocol (XMPP) is an application profile of the Extensible Markup Language [XML] that enables the near-real-time exchange of structured yet extensible data between any two or more network entities. The core features of XMPP defined in [XMPP‑CORE] provide the building blocks for many types of near-real-time applications, which can be layered on top of the core by sending application-specific data qualified by particular XML namespaces.
http://xmpp.org/rfcs/rfc6121.html#intro - that is the latest RFC which will give you a good starting point.

how to run ipad phone gap app on device and send it to others

I have a ipad phone gap app i want that app should also run on my clients device how may do this as we do normal by adhoc distribution and send ipa file but this is an phonegap app so how may send this and run on any device.
You may use Test flight (http://testflightapp.com) to distribute enterprise ad-hocs, or you can use phonegap build (http://build.phonegap.com) and then send the generated qr codes to your clients, so they can install the builds.

Flex / AIR - Can it receive SYSLOG notices?

Is there a way for Flex / AIR to receive syslog notices from devices such as cisco switches etc? Does anyone know of any information I can read or sites to look at?
If you are talking about calling native methods, flex/air cannot do that. But there is an opensource AIR-Java bridge namely merapi that lets you connect your AIR app with java code. I guess java should be able to do what you are looking for.
AIR apps can read local files. In the case of receiving syslog notices from cisco switches or other devices, I used to set them up on the receiving machine to be added to the local syslog there to have everything in one place (we're not talking windows here :-)). Using mtail and grep I had a few consoles open that showed me what was coming in.
If you write an Actionscript parser to read your local syslog - using bytearray like described here - then it should be possible to read through the whole file and note the interesting bits (I haven't done this myself, so no guarantees!)
If it more a question of getting real time data from devices, I would look into snmp (but you will probably need to write additional stuff in php or python to query the devices for you).

Resources