Diff of /README.md [000000] .. [a32498]

Switch to unified view

a b/README.md
1
Emokit
2
======
3
4
Reverse engineering and original code written by
5
6
* Cody Brocious (http://github.com/daeken)
7
* Kyle Machulis (http://github.com/qdot)
8
9
Contributions by
10
11
* Severin Lemaignan - Base C Library and mcrypt functionality
12
* Sharif Olorin  (http://github.com/fractalcat) - hidapi support
13
* Bill Schumacher (http://github.com/bschumacher) - Fixed the Python library
14
15
Headset Support
16
===============
17
18
Supported: Epoc, Epoc+(Pre-2016, limited gyro sensors)
19
Unsupported: Epoc+(2016+), other models.
20
21
Description
22
===========
23
24
Emokit is a set of language for user space access to the raw stream
25
data from the Emotiv EPOC headset. Note that this will not give you
26
processed data (i.e. anything available in the Emo Suites in the
27
software), just the raw sensor data.
28
29
C Library
30
=========
31
32
Please note that the python and C libraries are now in different
33
repos. If you would like to use the C version of emokit, the repo
34
is at
35
36
http://www.github.com/openyou/emokit-c
37
38
Information
39
===========
40
41
FAQ (READ BEFORE FILING ISSUES): https://github.com/openyou/emokit/blob/master/FAQ.md
42
43
If you have a problem not covered in the FAQ, file it as an
44
issue on the github project.
45
46
PLEASE DO NOT EMAIL OR OTHERWISE CONTACT THE DEVELOPERS DIRECTLY.
47
Seriously. I'm sick of email and random facebook friendings asking for
48
help. What happens on the project stays on the project.
49
50
Issues: http://github.com/openyou/emokit/issues
51
52
If you are using the Python library and a research headset you may have
53
to change the is_research variable in emotiv.py's setup_crypto function.
54
55
Required Libraries
56
==================
57
58
Python
59
------
60
61
* pycrypto - https://www.dlitz.net/software/pycrypto/
62
63
2.x
64
* future - pip install future
65
  
66
Windows
67
* pywinusb - https://pypi.python.org/pypi/pywinusb/
68
69
Linux / OS X
70
* hidapi - http://www.signal11.us/oss/hidapi/
71
* pyhidapi - https://github.com/NF6X/pyhidapi
72
73
Running tests
74
* pytest - http://doc.pytest.org/en/latest/
75
76
You should be able to install emokit and the required python libraries using:  
77
78
pip install emokit
79
80
OR
81
82
python setup.py install
83
84
hidapi will still need to be installed manually on Linux and OS X.
85
86
87
Usage
88
=====
89
90
Python library
91
--------------
92
93
  Code:
94
95
    # -*- coding: utf-8 -*-
96
    # This is an example of popping a packet from the Emotiv class's packet queue
97
98
99
    import time
100
101
    from emokit.emotiv import Emotiv
102
103
    if __name__ == "__main__":
104
        with Emotiv(display_output=True, verbose=True) as headset:
105
            while True:
106
                packet = headset.dequeue()
107
                if packet is not None:
108
                   pass
109
                time.sleep(0.001)
110
111
112
Bindings
113
========
114
115
Go: https://github.com/fractalcat/emogo
116
117
118
Running Unit Tests
119
==================
120
121
From the python directory in your terminal type:
122
123
  Code:  
124
125
    python -m pytest tests/
126
      
127
128
Platform Specifics Issues
129
=========================
130
131
Linux
132
-----
133
134
Due to the way hidapi works, the linux version of emokit can run using
135
either hidraw calls or libusb. These will require different udev rules
136
for each. We've tried to cover both (as based on hidapi's example udev
137
file), but your mileage may vary. If you have problems, please post
138
them to the github issues page (http://github.com/openyou/emokit/issues).
139
140
Your kernel may not support /dev/hidraw devices by default, such as an RPi.
141
To fix that re-comiple your kernel with /dev/hidraw support
142
143
OS X
144
----
145
146
The render.py file uses pygame, visit http://pygame.org/wiki/MacCompile
147
Do not export the architecture compiler flags for recent 64bit versions of OS X.
148
149
Credits - Cody
150
==============
151
152
Huge thanks to everyone who donated to the fund drive that got the
153
hardware into my hands to build this.
154
155
Thanks to Bryan Bishop and the other guys in #hplusroadmap on Freenode
156
for your help and support.
157
158
And as always, thanks to my friends and family for supporting me and
159
suffering through my obsession of the week.
160
161
Credits - Kyle
162
==============
163
164
Kyle would like to thank Cody for doing the hard part. 
165
166
He would also like to thank emotiv for putting emo on the front of
167
everything because it's god damn hilarious. I mean, really, Emo
168
Suites? Saddest hotel EVER.
169
170
# Frequently asked questions
171
172
 - *What unit is the data I'm getting back in? How do I get volts out of
173
 it?*
174
175
 One least-significant-bit of the fourteen-bit value you get back is
176
 0.51 microvolts. See the
177
 [specification](http://emotiv.com/upload/manual/EPOCSpecifications.pdf)
178
 for more details. (Broken Link)
179
 
180
 - *What should my output look like?*
181
 
182
 Idling, not on someone's head it should look something like this:  
183
184
Emokit - v0.0.8 SN: ActualSerialNumberHere  Old Model: False
185
+========================================================+
186
| Sensor |   Value  | Quality  | Quality L1 | Quality L2 |
187
+--------+----------+----------+------------+------------+
188
|   F3   |   292    |    24    |  Nothing   |  Nothing   |
189
|   FC5  |   1069   |    0     |  Nothing   |  Nothing   |
190
|   AF3  |   110    |    8     |  Nothing   |  Nothing   |
191
|   F7   |    63    |    24    |  Nothing   |  Nothing   |
192
|   T7   |   322    |    8     |  Nothing   |  Nothing   |
193
|   P7   |   166    |    0     |  Nothing   |  Nothing   |
194
|   O1   |   -62    |    24    |  Nothing   |  Nothing   |
195
|   O2   |   235    |    24    |  Nothing   |  Nothing   |
196
|   P8   |   -63    |    24    |  Nothing   |  Nothing   |
197
|   T8   |   626    |    16    |  Nothing   |  Nothing   |
198
|   F8   |   1045   |    16    |  Nothing   |  Nothing   |
199
|   AF4  |   578    |    8     |  Nothing   |  Nothing   |
200
|   FC6  |   973    |    16    |  Nothing   |  Nothing   |
201
|   F4   |   780    |    8     |  Nothing   |  Nothing   |
202
|   X    |    2     |   N/A    |    N/A     |    N/A     |
203
|   Y    |    1     |   N/A    |    N/A     |    N/A     |
204
|   Z    |    ?     |   N/A    |    N/A     |    N/A     |
205
|  Batt  |    46    |   N/A    |    N/A     |    N/A     |
206
+--------+----------+----------+------------+------------+
207
|Packets Received:   452    |  Packets Processed:   447  |
208
|   Sampling Rate:    2     |        Crypto Rate:    0   |
209
+========================================================+