Skip to content

Commit

Permalink
Merge pull request #23 from robotics-in-concert/req_interaction_patch
Browse files Browse the repository at this point in the history
Upgrade web remocon for supporting pairing mode and applying stop app
  • Loading branch information
jihoonl committed Jun 26, 2015
2 parents e0e2837 + 76d083a commit c652358
Show file tree
Hide file tree
Showing 3 changed files with 221 additions and 46 deletions.
20 changes: 10 additions & 10 deletions rocon_web_common/www/example/listener.html
Original file line number Diff line number Diff line change
Expand Up @@ -8,18 +8,18 @@
<!--
<script type="text/javascript" src="http://chimek.yujinrobot.com/rosjs/interactions.js"></script>
-->
<script type="text/javascript" src="/rocon_web_common/js/interactions.js"></script>
<script type="text/javascript" src="/rocon_web_common/js/rocon/interactions.js"></script>
<script type="text/javascript" type="text/javascript">

$.ready() {
function init() {

var log_div = $("#log_div");
var info_div = $("#info_div");
var log_div = document.getElementById("log_div");
var info_div = document.getElementById("info_div");

info_div.append("Display Name : " + rocon_interactions.display_name + "<br/>");
info_div.append("Rosbridge URI: " + rocon_interactions.rosbridge_uri + "<br/>");
info_div.append("Parameters : " + JSON.stringify(rocon_interactions.parameters) + "<br/>");
info_div.append("Remappings : " + JSON.stringify(rocon_interactions.remappings) + "<br/>");
info_div.innerHTML = "Display Name : " + rocon_interactions.display_name + "<br/>";
info_div.innerHTML += "Rosbridge URI: " + rocon_interactions.rosbridge_uri + "<br/>";
info_div.innerHTML += "Parameters : " + JSON.stringify(rocon_interactions.parameters) + "<br/>";
info_div.innerHTML += "Remappings : " + JSON.stringify(rocon_interactions.remappings) + "<br/>";

// Connecting to ROS
// -----------------
Expand All @@ -42,13 +42,13 @@
listener.subscribe(function(message) {
//console.log('Received message on ' + listener.name + ': ' + message.data);
//listener.unsubscribe();
log_div.append(message + "</br>");
log_div.innerHTML += message.data + "</br>";
});
}
</script>
</head>

<body>
<body onload="init()">
<h1>Rocon Interactions Listener Demo</h1>
<p>Check your Web Console for Information(hit F12 in google chrome).</p>
<h1>Info</h1>
Expand Down
10 changes: 8 additions & 2 deletions rocon_web_remocon/www/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -125,8 +125,14 @@ <h3 class="text-center"><span class="label label-primary">Description</span></h3
<div class="panel-body" id="descriptionpanel">
</div>
</div>

<button type="button" class="btn btn-info center-block" style="width:150px; height:40px; font-size:20px" id="startappBtn">Start App</button>
<div class="row">
<button type="button" class="btn btn-info col-md-4 col-md-offset-1" style="font-size:18px" id="startInteractionBtn">Start Interaction</button>
<button type="button" class="btn btn-info col-md-4 col-md-offset-2" style="font-size:18px" id="stopInteractionBtn">Stop Interaction</button>
</div>
<p/>
<div class="row">
<button type="button" class="btn btn-info col-md-10 col-md-offset-1" style="font-size:18px" id="stopAllInteractionsBtn">Stop All Interactions</button>
</div>
</div>
</div>
</div>
Expand Down
Loading

0 comments on commit c652358

Please sign in to comment.