50 likes | 174 Views
T-Cards for Vanguards. Research Notebook Entry 1 Greg Ash, Roger Casco, Aaron Herstein , Brett Overesch , Kevin Winget. Conceptual Issues. Not sure what data is important on T-cards Not sure exactly how they are used Expectations of users vary widely. ???. Interaction and Design Issues.
E N D
T-Cards for Vanguards Research Notebook Entry 1 Greg Ash, Roger Casco, Aaron Herstein, Brett Overesch, Kevin Winget
Conceptual Issues • Not sure what data is important on T-cards • Not sure exactly how they are used • Expectations of users vary widely ???
Interaction and Design Issues • Bluetooth communication • Finding a use for trans-surface in this project • Assumption that emergency response personnel will have required equipment ???
Solutions • Acquire a real T-Card from Disaster City • Utilize Bluecove Bluetooth library • “Black hole” concept for resource reallocation • Command Interface facilitates trans-surface communication
Bluetooth Code Snippet • private void bluetoothServer() {StreamConnectionNotifiernotifier;StreamConnection connection = null;LocalDevice local = null; try { // Get reference to an actual Bluetooth device local = LocalDevice.getLocalDevice();local.setDiscoverable(DiscoveryAgent.GIAC);javax.bluetooth.UUIDuuid = new javax.bluetooth.UUID(80087355); // "04c6093b-0000-1000-8000-00805f9b34fb" String url = "btspp://localhost:" + uuid.toString() + ";name=RemoteBluetooth";notifier = (StreamConnectionNotifier)Connector.open(url); } catch (Exception e) {System.err.println("Could not connect to bluetooth device, cannot start server. Bailing.");e.printStackTrace(); return; } // Here's the main loop - wait for connections and spin off threads: while(true) { try { connection = notifier.acceptAndOpen();System.out.println("Android client connected!");RemoteClient client = new RemoteClient(_commandQueue, connection); _clients.add(client); Thread remoteClientThread = new Thread(client);remoteClientThread.start(); } catch (Exception e) {System.err.println("Error encountered while accepting new Bluetooth connection:");e.printStackTrace(); return; } } }