Streaming LSL from Raspberry via WIFi

nejemianejemia argentina
edited June 2020 in Software

Dear all:
I have installed the python OpenCBI_LSL client in my Raspberry and after getting the right liblsl.so working, I was able to execute the client with the RFDuino Dongle on /dev/ttyUSB0 (Python 2.7.16). However I need assistance on how to stream the data using the WiFi on my local network, so I can get the data in OpenBCI_GUI (modified to receive lsl) and/or OpenVibe or similar.
Any help will be appreciated.
All the best.
Nelson

Comments

  • wjcroftwjcroft Mount Shasta, CA

    Nelson, hi.

    If I understand your post above, you have a Raspberry receiving the Cyton data stream, then converting to LSL, then sending via Wifi to a laptop. The laptop will then receive the LSL stream and do processing there.

    What is the advantage to this setup, instead of just plugging the Cyton dongle directly into the laptop? That scheme immediately lets you run the GUI with no modifications. Or OpenViBE if you wish.

    Regards, William

  • nejemianejemia argentina

    Dear William.
    There are several aspects that makes this idea interesting to be explored.
    I can have my computer running OpenBCI_GUI connected to my home AP as well as the Raspberry in a different place, not limited by the BLE range.
    Other interesting application could be Telemedicine, once I have this configuration working, I would try to run OpenBCI_GUI in a remote location creating and configuring a VPN over the Internet.
    In the mean time I have detected the problem is escencially incompatibility between the LSL lib version running in Raspberry and LSL running in my Windows or Mac...
    LSL libraries may have compatibility issues...
    If you have some experience with this, please, assistance will be very appreciated.
    Nelson

  • wjcroftwjcroft Mount Shasta, CA
    edited June 2020

    Curious, how is this related to your other thread posts regarding DIY Cyton's using ESP8266 chips? Do you have RFduino based Cytons?

    https://openbci.com/forum/index.php?p=/discussion/2507/wifi-connection-with-different-esp8266-resolved

    Why not go direct from the Cyton to the laptop over wifi?

  • nejemianejemia argentina

    Dear William:
    I am testing and experimenting different options.
    So far, WiFi Shield works but it is quite erratic. The hardware involved, ESP8266 is sensible to its manufacturing origin. Some of them works better, some of them are horrible. In summary: not reliable.
    My whole project has 2 stages: 1) Getting Medical Approval from Argentinian Health Office. 2) Telemedicine.
    Both goals requires extremely reliable configurations.
    If I can have a Raspberry or any similar Linux embedded system talking to the Cyton at very short distance using the RFDuino dongle and then having the Linux running the LSL streamer to the Inter/Intra network (I assume LSL uses broadcast UDP sockets), I will be able to have either the OpenBCI_GUI or any other LSL compatible Display software at a remote location.
    Hope this clarifies the issue.
    In the mean time, I still did not make the Raspberry stream the data from Cyton to a remote Windows OpenBCI_GUI.
    It seems to be some sort of incompatibility between the streamer and the receiver albeit I am using the SAME version of pylsl in both Raspberry and Windows (now version 1.12.2). PD: Locally the streamer and receiver works perfect in the Raspberry or in the Windows, but they do not recognize the streams while talking to each other.

  • wjcroftwjcroft Mount Shasta, CA
    edited June 2020

    Nelson, thanks.

    Just for your information, the OpenBCI-manufactured Wifi Shield works with EXCELLENT reliability with the Ganglion. When used with Cyton, there are sometimes issues with packet lossage. Some speculation on the why this is the case, from an engineering point of view (such as power supply regulation issues), are discussed in other threads here.

    So this fact of solid Gangion + Shield operation, may influence your directions.

    Regards,

  • nejemianejemia argentina

    Great! Unfortunately I do not have a Ganglion board with me. But there are some other issues involved in my investigation. Number of channels, sampling speed (overriding the USB RFDuino dongle), and other considerations makes the Ganglion+WiFi shield a last resource. Will keep exploring... I have asked support to StreamingLab guys. Let's wait and see.
    All the best folks.

  • wjcroftwjcroft Mount Shasta, CA

    The point I am making with the Ganglion, is that Cyton+Shield can probably work just as reliably provided: (1) you have the correct Chinese manufacturer for your ESP8266 or adapt another ESP model. (2) you resolve what is causing packet lossage / power supply regulation issues for Cyton only (not Ganglion).

    I assume with your Cyton+Shield tests, you were powering with TWO batteries, one each for Cyton and Shield. And that others have found that 6V AA packs work better than the 3.7V lithium cells because it gives the power supply regulator higher margin. Note that 7.4V '2S' lithium cells also exist, that would have similar effect.

  • nejemianejemia argentina

    The testing with the Cyton and the WiFi shield are still going ON! It worked fine, and yes, I used separate set of batteries and I am using the Ultimate Lithium batteries for the 6V pack and a separate set for the WiFi nodeMCU. Will keep testing ! This is the whole spirit of a real investigator. TAKE CARE and big hug.

  • wjcroftwjcroft Mount Shasta, CA

    It's even possible that with the 7.4V '2S' batteries, that the slightly higher voltage may further improve power supply regulation. These 2S cells require a special charger, typically seen in remote control cars / model airplanes / drones.

  • nejemianejemia argentina

    I am also testing with a 5 volt 20.000 mAh battery pack (used for cell phones). This provides a fantastic regulation and very long time of continuous use. Will see...

  • wjcroftwjcroft Mount Shasta, CA
    edited June 2020

    Typical 5V 'power bank' units, use internal lithium cells, but with a boost converter / switching power supply to get up to 5V. Such switching supplies can introduce noise. The 2S cells I mentioned are just two 3.7 lithium cells in series, so no added electronics.

    The ESP8266 regulation issue, has to do with peak power demands it creates when doing certain radio transmissions / packet sending. Other thread on the forum has links showing how this impact packet loss.

Sign In or Register to comment.