little_sophia_brain_ros2/ros_docker/index.html

25 lines
541 B
HTML

<head>
</head>
<body>
<script src="https://cdn.jsdelivr.net/npm/roslib/build/roslib.min.js"></script>
<script>
const ros = new ROSLIB.Ros({
url: 'ws://localhost:9090'
});
ros.on('connection', () => {
console.log('✅ Connected to rosbridge');
});
ros.on('error', (error) => {
console.error('❌ Connection error:', error);
});
ros.on('close', () => {
console.log('🔌 Connection closed');
});
</script>
</body>