Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Low Energy Bluetooth Problem #21

Open
andira14 opened this issue May 13, 2017 · 5 comments
Open

Low Energy Bluetooth Problem #21

andira14 opened this issue May 13, 2017 · 5 comments

Comments

@andira14
Copy link

andira14 commented May 13, 2017

I have a problem connecting raspberry pi bluetooth to Muse EEG headband. it won't detect the headband bluetooth using hcitool scan But I can scan using the low energy scanning hcitool lescan. I've obtained the mac address of the headband and insert it to the <remote addr> tag in the file data_config.xml, I started the program but it only showed

freq:0 freq:750 freq:0 freq:750 freq:0 freq:750 freq:0 freq:750 freq:0 freq:750 freq:0 freq:750 Data interface->Searching for hardware...

and so on nonstop.

I can connect to muse eeg using bluetoothctl command and tried to run the program when connected to the headband but the same thing happened.

Thank you in advance.

@andira14 andira14 changed the title Low Energy Bluetooth Raspberry Pi Low Energy Bluetooth Problem May 13, 2017
@Fred-Simard
Copy link

Hi Andira,

Muse is not using BLE. To find it, use bluetoothctl->scan on. (My muse date back to a few years, I don't know if it changed since)

To pair with the device, install and start blueman (bluetooth manager). This program will handle the authentication step required to pair with the Muse. When blueman pop-up a dialog window, simply click on confirm.

Configs I had to change:

  • in data-interface/config put in your MAC address.

  • While you're in there, make sure that the output format is SHM. If you wish to record eeg samples to a file, you could write CSV in there. This option routes the signal between processes.

  • in data-preprocessing/config/preprocess_config.xml, feature_dest needs to be SHM. This will route the data to the braintone app.

As you guessed, to start the BrainTone example run ./launch_braintone_x86 start

This sequence:
freq:0 freq:750 freq:0 freq:750 freq:0 freq:750 freq:0 freq:750 freq:0 freq:750 freq:0 freq:750 Data interface->Searching for hardware...

Tells you that IntelliPi is in pairing mode and looking for hardware. Now braintone is designed to run with a piezobuzzer hooked to a GPIO. It display the frequency because if you don't have a Piezo connected, then nothing would happen. (circuit schematics: Braintone Tutorial )

With the fixes in the config file and blueman running, IntelliPi should find your muse connect to it and begin the training as part of the braintone program. You can look into the source code for Braintone, main.c and feature_processing.c will show you how it's done.

Let me know how that goes

@andira14
Copy link
Author

@Fred-Simard thank you for your reply. I read the new Muse 2016 is BLE from this data

http://developer.choosemuse.com/hardware-firmware/bluetooth-connectivity

I just bought muse for a week and I think I got the 2016 version. I'll try your tips. thank you

@Fred-Simard
Copy link

This guy developed a python API for the Muse 2016, I suggest you check it out:
https://github.com/alexandrebarachant?tab=repositories
http://alexandre.barachant.org/blog/2017/02/05/P300-with-muse.html

@andira14
Copy link
Author

@Fred-Simard
i've connected it through blueman but still the same result happen. I'll try the link you gave me. Thank you

@Fred-Simard
Copy link

If the Muse 2016 is using BLE, then the IntelliPi won't work. Before 2016, the muse was connecting of RFCOMM. I think the 2016 connects over GATT (SPP over gatt, maybe), and I'm not sure this is compatible with how we did it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants