Skip to content

Commit

Permalink
Merge pull request #51 from Mentalab-hub/update-docs
Browse files Browse the repository at this point in the history
Update docs
  • Loading branch information
salman2135 committed Aug 12, 2022
2 parents 5eebe8c + 7ff92f9 commit 7910666
Show file tree
Hide file tree
Showing 108 changed files with 1,040 additions and 19,103 deletions.
2 changes: 2 additions & 0 deletions .idea/misc.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

35 changes: 5 additions & 30 deletions README.md
Expand Up @@ -12,6 +12,8 @@ Explore Android API is Mentalab's open-source biosignal acquisition API for use
* Record data in csv format
* Push data to Lab Streaming Layer(LSL)
* Change device settings
* Measure impedance
* Filter and stream raw data

Requirements
==================
Expand All @@ -34,7 +36,7 @@ maven { url ‘https://jitpack.io’ }

* Add the following dependency in your app level build.gradle file
```
implementation 'com.github.Mentalab-hub:explore-android:V_0.2'
implementation 'com.github.Mentalab-hub:explore-android:V_1.0'
```

* Add the following permisions in your android manifest:
Expand All @@ -44,47 +46,20 @@ implementation 'com.github.Mentalab-hub:explore-android:V_0.2'
```
* Sync gradle and Mentlab API is ready to use!

The following example shows how to set up the your project for explore-android. Please always follow the instructions in this page to integrate latest features in your app.


[![SC2 Video](https://img.youtube.com/vi/nP57MqztEUI/0.jpg)](https://youtu.be/nP57MqztEUI)

A demo Android application which used explore-java library is available [here](https://github.com/Mentalab-hub/explore-demo-app).
Please check troubleshooting section of this document in case of issues.

Usage Example
=============

The following code snippet shows how to scan, connect and get data stream from Explore device:

```java
Set<String> deviceList = MentalabCommands.scan();
/* Connect to Explore device */
MentalabCommands.connect("Explore_XXXX");

InputStream inputStream = MentalabCommands.getRawData();
/* Get data map with decoded data points */
Map<String, Queue<Float>> map = MentalabCodec.decode(inputStream);

/* Push data to LSL */
MentalabCommands.pushToLsl();

/* Set specific channels */
Map<String, Boolean> configMap = Map.of(DeviceConfigSwitches.Channels[7], false,
MentalabConstants.DeviceConfigSwitches.Channels[6], false);
MentalabCommands.setEnabled(configMap);
```


Documentation
=============

For the full documentation of the API, please visit our [Javadoc page](https://github.com/Mentalab-hub/explore-android/tree/master/javadoc)
For the full documentation of the API, please refer to javadoc folder in code repository.

Troubleshooting
===============

* If your phone is not recognized by Android Studio, make sure that USB debugging is turned on on your Android device.
* Make sure to pair the Explore device with your phone at first.

You can also create a new issue in the GitHub repository.

Expand Down
130 changes: 10 additions & 120 deletions javadoc/allclasses-index.html
Expand Up @@ -2,10 +2,10 @@
<!-- NewPage -->
<html lang="en">
<head>
<!-- Generated by javadoc (11.0.8) on Tue Nov 30 14:52:17 CET 2021 -->
<!-- Generated by javadoc (11.0.8) on Fri Aug 12 19:34:00 BDT 2022 -->
<title>All Classes</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="dc.created" content="2021-11-30">
<meta name="dc.created" content="2022-08-12">
<link rel="stylesheet" type="text/css" href="stylesheet.css" title="Style">
<link rel="stylesheet" type="text/css" href="jquery/jquery-ui.css" title="Style">
<script type="text/javascript" src="script.js"></script>
Expand All @@ -28,12 +28,6 @@
catch(err) {
}
//-->
var data = {"i0":2,"i1":8,"i2":2,"i3":2,"i4":2,"i5":2,"i6":8,"i7":8,"i8":2,"i9":1,"i10":2,"i11":2,"i12":2,"i13":2,"i14":2,"i15":2,"i16":2,"i17":4,"i18":1,"i19":4,"i20":8,"i21":2,"i22":2,"i23":8,"i24":8,"i25":2,"i26":2,"i27":2,"i28":2};
var tabs = {65535:["t0","All Classes"],1:["t1","Interface Summary"],2:["t2","Class Summary"],4:["t3","Enum Summary"],8:["t4","Exception Summary"]};
var altColor = "altColor";
var rowColor = "rowColor";
var tableTab = "tableTab";
var activeTableTab = "activeTableTab";
var pathtoroot = "./";
var useModuleDirectories = true;
loadScripts(document, 'script');</script>
Expand All @@ -52,8 +46,7 @@
<!-- -->
</a>
<ul class="navList" title="Navigation">
<li><a href="index.html">Overview</a></li>
<li>Package</li>
<li><a href="com/mentalab/package-summary.html">Package</a></li>
<li>Class</li>
<li>Use</li>
<li><a href="overview-tree.html">Tree</a></li>
Expand Down Expand Up @@ -107,127 +100,25 @@ <h1 title="All&amp;nbsp;Classes" class="title">All&nbsp;Classes</h1>
<ul class="blockList">
<li class="blockList">
<table class="typeSummary">
<caption><span id="t0" class="activeTableTab"><span>All Classes</span><span class="tabEnd">&nbsp;</span></span><span id="t1" class="tableTab"><span><a href="javascript:show(1);">Interface Summary</a></span><span class="tabEnd">&nbsp;</span></span><span id="t2" class="tableTab"><span><a href="javascript:show(2);">Class Summary</a></span><span class="tabEnd">&nbsp;</span></span><span id="t3" class="tableTab"><span><a href="javascript:show(4);">Enum Summary</a></span><span class="tabEnd">&nbsp;</span></span><span id="t4" class="tableTab"><span><a href="javascript:show(8);">Exception Summary</a></span><span class="tabEnd">&nbsp;</span></span></caption>
<caption><span>Class Summary</span><span class="tabEnd">&nbsp;</span></caption>
<tr>
<th class="colFirst" scope="col">Class</th>
<th class="colLast" scope="col">Description</th>
</tr>
<tr id="i0" class="altColor">
<td class="colFirst"><a href="com/mentalab/CommandTranslators/ChannelMaskTranslator.html" title="class in com.mentalab.CommandTranslators">ChannelMaskTranslator</a></td>
<th class="colLast" scope="row">&nbsp;</th>
<td class="colFirst"><a href="com/mentalab/ExploreDevice.html" title="class in com.mentalab">ExploreDevice</a></td>
<th class="colLast" scope="row">
<div class="block">A wrapper around BluetoothDevice</div>
</th>
</tr>
<tr id="i1" class="rowColor">
<td class="colFirst"><a href="com/mentalab/exception/CommandFailedException.html" title="class in com.mentalab.exception">CommandFailedException</a></td>
<th class="colLast" scope="row">&nbsp;</th>
</tr>
<tr id="i2" class="altColor">
<td class="colFirst"><a href="com/mentalab/CommandTranslators/CommandTranslator.html" title="class in com.mentalab.CommandTranslators">CommandTranslator</a></td>
<th class="colLast" scope="row">&nbsp;</th>
</tr>
<tr id="i3" class="rowColor">
<td class="colFirst"><a href="com/mentalab/DeviceConfigurationTask.html" title="class in com.mentalab">DeviceConfigurationTask</a></td>
<th class="colLast" scope="row">&nbsp;</th>
</tr>
<tr id="i4" class="altColor">
<td class="colFirst"><a href="com/mentalab/FileGenerator.html" title="class in com.mentalab">FileGenerator</a></td>
<th class="colLast" scope="row">&nbsp;</th>
</tr>
<tr id="i5" class="rowColor">
<td class="colFirst"><a href="com/mentalab/CommandTranslators/FormatMemoryCommandTranslator.html" title="class in com.mentalab.CommandTranslators">FormatMemoryCommandTranslator</a></td>
<th class="colLast" scope="row">&nbsp;</th>
</tr>
<tr id="i6" class="altColor">
<td class="colFirst"><a href="com/mentalab/exception/InvalidCommandException.html" title="class in com.mentalab.exception">InvalidCommandException</a></td>
<th class="colLast" scope="row">&nbsp;</th>
</tr>
<tr id="i7" class="rowColor">
<td class="colFirst"><a href="com/mentalab/exception/InvalidDataException.html" title="class in com.mentalab.exception">InvalidDataException</a></td>
<th class="colLast" scope="row">&nbsp;</th>
</tr>
<tr id="i8" class="altColor">
<td class="colFirst"><a href="com/mentalab/LslLoader.html" title="class in com.mentalab">LslLoader</a></td>
<th class="colLast" scope="row">&nbsp;</th>
</tr>
<tr id="i9" class="rowColor">
<td class="colFirst"><a href="com/mentalab/LslLoader.lslLibLoader.html" title="interface in com.mentalab">LslLoader.lslLibLoader</a></td>
<th class="colLast" scope="row">&nbsp;</th>
</tr>
<tr id="i10" class="altColor">
<td class="colFirst"><a href="com/mentalab/LslLoader.StreamInfo.html" title="class in com.mentalab">LslLoader.StreamInfo</a></td>
<th class="colLast" scope="row">&nbsp;</th>
</tr>
<tr id="i11" class="rowColor">
<td class="colFirst"><a href="com/mentalab/LslLoader.StreamOutlet.html" title="class in com.mentalab">LslLoader.StreamOutlet</a></td>
<th class="colLast" scope="row">&nbsp;</th>
</tr>
<tr id="i12" class="altColor">
<td class="colFirst"><a href="com/mentalab/LslPacketSubscriber.html" title="class in com.mentalab">LslPacketSubscriber</a></td>
<th class="colLast" scope="row">&nbsp;</th>
</tr>
<tr id="i13" class="rowColor">
<td class="colFirst"><a href="com/mentalab/MainActivity.html" title="class in com.mentalab">MainActivity</a></td>
<th class="colLast" scope="row">&nbsp;</th>
</tr>
<tr id="i14" class="altColor">
<td class="colFirst"><a href="com/mentalab/MentalabCodec.html" title="class in com.mentalab">MentalabCodec</a></td>
<th class="colLast" scope="row">&nbsp;</th>
</tr>
<tr id="i15" class="rowColor">
<tr id="i2" class="altColor">
<td class="colFirst"><a href="com/mentalab/MentalabCommands.html" title="class in com.mentalab">MentalabCommands</a></td>
<th class="colLast" scope="row">&nbsp;</th>
</tr>
<tr id="i16" class="altColor">
<td class="colFirst"><a href="com/mentalab/MentalabConstants.html" title="class in com.mentalab">MentalabConstants</a></td>
<th class="colLast" scope="row">&nbsp;</th>
</tr>
<tr id="i17" class="rowColor">
<td class="colFirst"><a href="com/mentalab/MentalabConstants.Command.html" title="enum in com.mentalab">MentalabConstants.Command</a></td>
<th class="colLast" scope="row">&nbsp;</th>
</tr>
<tr id="i18" class="altColor">
<td class="colFirst"><a href="com/mentalab/MentalabConstants.DeviceConfigSwitches.html" title="interface in com.mentalab">MentalabConstants.DeviceConfigSwitches</a></td>
<th class="colLast" scope="row">&nbsp;</th>
</tr>
<tr id="i19" class="rowColor">
<td class="colFirst"><a href="com/mentalab/MentalabConstants.SamplingRate.html" title="enum in com.mentalab">MentalabConstants.SamplingRate</a></td>
<th class="colLast" scope="row">&nbsp;</th>
</tr>
<tr id="i20" class="altColor">
<td class="colFirst"><a href="com/mentalab/exception/MentalabException.html" title="class in com.mentalab.exception">MentalabException</a></td>
<th class="colLast" scope="row">&nbsp;</th>
</tr>
<tr id="i21" class="rowColor">
<td class="colFirst"><a href="com/mentalab/CommandTranslators/ModuleDisableTranslator.html" title="class in com.mentalab.CommandTranslators">ModuleDisableTranslator</a></td>
<th class="colLast" scope="row">&nbsp;</th>
</tr>
<tr id="i22" class="altColor">
<td class="colFirst"><a href="com/mentalab/CommandTranslators/ModuleEnableTranslator.html" title="class in com.mentalab.CommandTranslators">ModuleEnableTranslator</a></td>
<th class="colLast" scope="row">&nbsp;</th>
</tr>
<tr id="i23" class="rowColor">
<td class="colFirst"><a href="com/mentalab/exception/NoBluetoothException.html" title="class in com.mentalab.exception">NoBluetoothException</a></td>
<th class="colLast" scope="row">&nbsp;</th>
</tr>
<tr id="i24" class="altColor">
<td class="colFirst"><a href="com/mentalab/exception/NoConnectionException.html" title="class in com.mentalab.exception">NoConnectionException</a></td>
<th class="colLast" scope="row">&nbsp;</th>
</tr>
<tr id="i25" class="rowColor">
<td class="colFirst"><a href="com/mentalab/RecordSubscriber.html" title="class in com.mentalab">RecordSubscriber</a></td>
<th class="colLast" scope="row">&nbsp;</th>
</tr>
<tr id="i26" class="altColor">
<td class="colFirst"><a href="com/mentalab/RecordSubscriber.Builder.html" title="class in com.mentalab">RecordSubscriber.Builder</a></td>
<th class="colLast" scope="row">&nbsp;</th>
</tr>
<tr id="i27" class="rowColor">
<td class="colFirst"><a href="com/mentalab/CommandTranslators/SamplingRateCommandTranslator.html" title="class in com.mentalab.CommandTranslators">SamplingRateCommandTranslator</a></td>
<th class="colLast" scope="row">&nbsp;</th>
</tr>
<tr id="i28" class="altColor">
<td class="colFirst"><a href="com/mentalab/CommandTranslators/SoftResetCommandTranslator.html" title="class in com.mentalab.CommandTranslators">SoftResetCommandTranslator</a></td>
<th class="colLast" scope="row">&nbsp;</th>
</tr>
</table>
</li>
</ul>
Expand All @@ -244,8 +135,7 @@ <h1 title="All&amp;nbsp;Classes" class="title">All&nbsp;Classes</h1>
<!-- -->
</a>
<ul class="navList" title="Navigation">
<li><a href="index.html">Overview</a></li>
<li>Package</li>
<li><a href="com/mentalab/package-summary.html">Package</a></li>
<li>Class</li>
<li>Use</li>
<li><a href="overview-tree.html">Tree</a></li>
Expand Down
32 changes: 3 additions & 29 deletions javadoc/allclasses.html
Expand Up @@ -2,10 +2,10 @@
<!-- NewPage -->
<html lang="en">
<head>
<!-- Generated by javadoc (11.0.8) on Tue Nov 30 14:52:17 CET 2021 -->
<!-- Generated by javadoc (11.0.8) on Fri Aug 12 19:34:00 BDT 2022 -->
<title>All Classes</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="dc.created" content="2021-11-30">
<meta name="dc.created" content="2022-08-12">
<link rel="stylesheet" type="text/css" href="stylesheet.css" title="Style">
<link rel="stylesheet" type="text/css" href="jquery/jquery-ui.css" title="Style">
<script type="text/javascript" src="script.js"></script>
Expand All @@ -22,35 +22,9 @@
<h1 class="bar">All&nbsp;Classes</h1>
<main role="main" class="indexContainer">
<ul>
<li><a href="com/mentalab/CommandTranslators/ChannelMaskTranslator.html" title="class in com.mentalab.CommandTranslators">ChannelMaskTranslator</a></li>
<li><a href="com/mentalab/exception/CommandFailedException.html" title="class in com.mentalab.exception">CommandFailedException</a></li>
<li><a href="com/mentalab/CommandTranslators/CommandTranslator.html" title="class in com.mentalab.CommandTranslators">CommandTranslator</a></li>
<li><a href="com/mentalab/DeviceConfigurationTask.html" title="class in com.mentalab">DeviceConfigurationTask</a></li>
<li><a href="com/mentalab/FileGenerator.html" title="class in com.mentalab">FileGenerator</a></li>
<li><a href="com/mentalab/CommandTranslators/FormatMemoryCommandTranslator.html" title="class in com.mentalab.CommandTranslators">FormatMemoryCommandTranslator</a></li>
<li><a href="com/mentalab/exception/InvalidCommandException.html" title="class in com.mentalab.exception">InvalidCommandException</a></li>
<li><a href="com/mentalab/exception/InvalidDataException.html" title="class in com.mentalab.exception">InvalidDataException</a></li>
<li><a href="com/mentalab/LslLoader.html" title="class in com.mentalab">LslLoader</a></li>
<li><a href="com/mentalab/LslLoader.lslLibLoader.html" title="interface in com.mentalab"><span class="interfaceName">LslLoader.lslLibLoader</span></a></li>
<li><a href="com/mentalab/LslLoader.StreamInfo.html" title="class in com.mentalab">LslLoader.StreamInfo</a></li>
<li><a href="com/mentalab/LslLoader.StreamOutlet.html" title="class in com.mentalab">LslLoader.StreamOutlet</a></li>
<li><a href="com/mentalab/LslPacketSubscriber.html" title="class in com.mentalab">LslPacketSubscriber</a></li>
<li><a href="com/mentalab/MainActivity.html" title="class in com.mentalab">MainActivity</a></li>
<li><a href="com/mentalab/ExploreDevice.html" title="class in com.mentalab">ExploreDevice</a></li>
<li><a href="com/mentalab/MentalabCodec.html" title="class in com.mentalab">MentalabCodec</a></li>
<li><a href="com/mentalab/MentalabCommands.html" title="class in com.mentalab">MentalabCommands</a></li>
<li><a href="com/mentalab/MentalabConstants.html" title="class in com.mentalab">MentalabConstants</a></li>
<li><a href="com/mentalab/MentalabConstants.Command.html" title="enum in com.mentalab">MentalabConstants.Command</a></li>
<li><a href="com/mentalab/MentalabConstants.DeviceConfigSwitches.html" title="interface in com.mentalab"><span class="interfaceName">MentalabConstants.DeviceConfigSwitches</span></a></li>
<li><a href="com/mentalab/MentalabConstants.SamplingRate.html" title="enum in com.mentalab">MentalabConstants.SamplingRate</a></li>
<li><a href="com/mentalab/exception/MentalabException.html" title="class in com.mentalab.exception">MentalabException</a></li>
<li><a href="com/mentalab/CommandTranslators/ModuleDisableTranslator.html" title="class in com.mentalab.CommandTranslators">ModuleDisableTranslator</a></li>
<li><a href="com/mentalab/CommandTranslators/ModuleEnableTranslator.html" title="class in com.mentalab.CommandTranslators">ModuleEnableTranslator</a></li>
<li><a href="com/mentalab/exception/NoBluetoothException.html" title="class in com.mentalab.exception">NoBluetoothException</a></li>
<li><a href="com/mentalab/exception/NoConnectionException.html" title="class in com.mentalab.exception">NoConnectionException</a></li>
<li><a href="com/mentalab/RecordSubscriber.html" title="class in com.mentalab">RecordSubscriber</a></li>
<li><a href="com/mentalab/RecordSubscriber.Builder.html" title="class in com.mentalab">RecordSubscriber.Builder</a></li>
<li><a href="com/mentalab/CommandTranslators/SamplingRateCommandTranslator.html" title="class in com.mentalab.CommandTranslators">SamplingRateCommandTranslator</a></li>
<li><a href="com/mentalab/CommandTranslators/SoftResetCommandTranslator.html" title="class in com.mentalab.CommandTranslators">SoftResetCommandTranslator</a></li>
</ul>
</main>
</body>
Expand Down
18 changes: 4 additions & 14 deletions javadoc/allpackages-index.html
Expand Up @@ -2,10 +2,10 @@
<!-- NewPage -->
<html lang="en">
<head>
<!-- Generated by javadoc (11.0.8) on Tue Nov 30 14:52:17 CET 2021 -->
<!-- Generated by javadoc (11.0.8) on Fri Aug 12 19:34:00 BDT 2022 -->
<title>All Packages</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="dc.created" content="2021-11-30">
<meta name="dc.created" content="2022-08-12">
<link rel="stylesheet" type="text/css" href="stylesheet.css" title="Style">
<link rel="stylesheet" type="text/css" href="jquery/jquery-ui.css" title="Style">
<script type="text/javascript" src="script.js"></script>
Expand Down Expand Up @@ -46,8 +46,7 @@
<!-- -->
</a>
<ul class="navList" title="Navigation">
<li><a href="index.html">Overview</a></li>
<li>Package</li>
<li><a href="com/mentalab/package-summary.html">Package</a></li>
<li>Class</li>
<li>Use</li>
<li><a href="overview-tree.html">Tree</a></li>
Expand Down Expand Up @@ -111,14 +110,6 @@ <h1 title="All&amp;nbsp;Packages" class="title">All&nbsp;Packages</h1>
<th class="colFirst" scope="row"><a href="com/mentalab/package-summary.html">com.mentalab</a></th>
<td class="colLast">&nbsp;</td>
</tr>
<tr class="rowColor">
<th class="colFirst" scope="row"><a href="com/mentalab/CommandTranslators/package-summary.html">com.mentalab.CommandTranslators</a></th>
<td class="colLast">&nbsp;</td>
</tr>
<tr class="altColor">
<th class="colFirst" scope="row"><a href="com/mentalab/exception/package-summary.html">com.mentalab.exception</a></th>
<td class="colLast">&nbsp;</td>
</tr>
</tbody>
</table>
</li>
Expand All @@ -136,8 +127,7 @@ <h1 title="All&amp;nbsp;Packages" class="title">All&nbsp;Packages</h1>
<!-- -->
</a>
<ul class="navList" title="Navigation">
<li><a href="index.html">Overview</a></li>
<li>Package</li>
<li><a href="com/mentalab/package-summary.html">Package</a></li>
<li>Class</li>
<li>Use</li>
<li><a href="overview-tree.html">Tree</a></li>
Expand Down

0 comments on commit 7910666

Please sign in to comment.