add comments to acknowledge Alexandre and adapt for python 3
Esse commit está contido em:
@@ -1,11 +1,16 @@
|
||||
## code by Alexandre Barachant
|
||||
## adapted by Pierre Karashchuk for compatibility with Python3
|
||||
|
||||
from pylsl import StreamInfo, StreamOutlet
|
||||
import numpy as np
|
||||
from builtins import input
|
||||
|
||||
info = StreamInfo('Ganglion_EEG', 'EEG', 4, 200, 'float32',
|
||||
'Ganglion_123456789')
|
||||
outlet = StreamOutlet(info)
|
||||
while True:
|
||||
strSample = raw_input().split(': ', 1)
|
||||
sample = 1e6*np.array(map(float, strSample[1].split(' ')))
|
||||
strSample = input().split(': ', 1)
|
||||
sample = 1e6*np.array(list(map(float, strSample[1].split(' '))))
|
||||
stamp = float(strSample[0])*1e-3
|
||||
outlet.push_sample(sample, stamp)
|
||||
# print('Pushed Sample At: ' + strSample[0])
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
// code by Alexandre Barachant
|
||||
|
||||
const Ganglion = require('openbci-ganglion').Ganglion;
|
||||
const ganglion = new Ganglion();
|
||||
// Construct LSL Handoff Python Shell
|
||||
|
||||
Referência em uma Nova Issue
Bloquear um usuário