Sending data from the phone to thin client devices using Alljoyn CPS Framework

asked 2015-08-13 09:02:43 -0700

AllJoyner gravatar image


Is it possible to send data from the phone to alljoyn thin client applications using Control Panel Service framework?

So I have a few AJTC apps running Alljoyn.js and implementing Control Panel and an Android App which renders the UI of each device.

I am wondering how to send data TO each device, I can see that I am able to receive data from the devices, such as data when the value has changed and/or to control each device using actions widgets. What about if I wanna pass data to a device, lets say every time a button is pressed or every time i click on the device and its UI gets rendered on the phone.

I have been going through the source code of control panel framework for android, I have tried modifying it such as adding parameters inside the Exec() bus method inside the ActionControl interface to try sending data that way but then I got a pop massage "Action failed", every time i would click on a button to turn on the device.

Please let me what is the simplest way to do this or what would i need to modify in the source code.

Thank you

edit retag flag offensive close merge delete


you might try on the core mailing list. https://lists.allseenalliance.org/mailman/listinfo/allseen-core

ry.jones ( 2015-08-13 12:30:16 -0700 )edit

1 answer

Sort by ยป oldest newest most voted

answered 2015-10-01 13:05:52 -0700

bspencer gravatar image

The Control Panel Service (CPS) for the arguments do not support bidirectional communication where the phone is pushing arbitrary data. The CPS can provide data for setting properties and values of sliders, textboxes, or other types of user input widgets.

If you require sending arbitrary data then create your own AllJoyn interface and directly interact with the BusObject on the Thin Client Library application to send the data.

The reason that Exec fails when modified is that all instances of the application that you are interacting with need to have the same definition for the AllJoyn interfaces used. As such the action interface doesn't contain the same signature for Exec which is why it will fail. Further it is not recommended to change any AllJoyn Interfaces defined in the CPS service as this will break compatibility with other applications that make user of the service.

edit flag offensive delete publish link more
Login/Signup to Answer

Question Tools

1 follower


Asked: 2015-08-13 09:02:43 -0700

Seen: 152 times

Last updated: Oct 01 '15