Skip to content
manaswis edited this page Mar 25, 2013 · 9 revisions

NOTE: Setup your NAT Settings first before using SensorAct.

Understanding SensorAct's Architecture

After setting up the system, you need to configure SensorAct components. Before we start configuring and using them, lets first examine each one.

In SensorAct's architecture, there are two main components:

  1. Virtual Personal Device Servers (VPDS)
  2. Brokers

SensorAct Architecture

Virtual Personal Device Servers (VPDS)

VPDS is responsible for local storage of sensor data, enabling security with help of guard rules and scheduling and execution of lightweight scripts called tasklets which can be used for building control applications using SensorAct.

VDPS_arch

In iiitd-ucla-pc3 github codebase, SensorAct refers to the VPDS codebase.

Broker

Broker is the central coordinator for the VPDSs. It also acts as a mediator between the user and the VPDS.
In iiitd-ucla-pc3 github codebase, SensorActBroker refers to the Broker's codebase.

SensorAct Web Application

The Virtual Machine (VM) contains another component : SensorAct Web Application.
This web application exposes the various features of SensorAct and it can be treated as a third party application which is built on top of SensorAct.
In iiitd-ucla-pc3 github codebase, SensorActApp refers to the WebApp's codebase.

Using SensorAct's Web Application

Follow the below mentioned instructions in the specified order:

  1. Registering to the Broker: In the setup instructions, source configSA was used to setup the VPDS. Details entered were host machine's IP (to interact with the database on it) and user credentials (username, password and email address).

    • To start using the application, go to http://<IP of the VM>:9003.
    • Register using the same credentials used to configure VPDS during setting up SensorAct system.
      You will be automatically logged in.
  2. Register VPDS: After logging in, you will see the screen with options for a regular user. To manage your VPDS (create devices, visualize sensor data etc.), you first need to register your VPDS to the Broker.

    • Click Register VPDS tab.
    • Enter any string of your choice to name your VPDS.
    • For the VPDS key, type source sensoract viewkey on the terminal to get this key. Use it in this field.
    • Enter the VPDS URL - it will be in the form:: http://<IP address of the VM>:9000/
    • Click Register VPDS button.
      You are now promoted to a VPDS Owner (VO) and you will be taken to a VO specific page.
  3. Manage VPDS: To do VPDS specific activities, you first need to select the VPDS you want to manage.

    • Click Manage VPDS tab
    • Select the VPDS and click Manage VPDS button.
      You will be taken to the VPDS management home page for the selected one.
  4. Device Creation: To enable your nodes to send data to the system, you first need to make an entry for each of the nodes.

    • Click Devices tab
    • Click Create New Device/Templates button
    • Fill in the details for a particular node.
    • Click Device Done button.
      You can create more of such entries by selecting the created one and then selecting Save As from the devices list page.
  5. Device Configuration: Follow the instructions specified here

  6. Sharing Access: You can now share access to your devices/nodes with other regular users (currently, sharing with other owners is not enabled). Sharing access would be allowing the user to visualize data from a particular sensor or allowing them to actuate devices.

    • In the VO home, click Share Access tab.
    • Select the user you want to share access with.
    • Select the VPDS where the device is registered.
    • Select the device specific details and permissions to grant.
    • Click Share Access button.
      The selected user can now visualize/actuate based on the permissions granted by you.