openbci-archive / OpenBCI_NodeJS

Node.js SDK for the all OpenBCI Biosensor Boards
https://www.npmjs.com/package/openbci
137 stars 52 forks source link

ENH: Add Mac/Windows large serialport as option to simulator #63

Closed andrewjaykeller closed 7 years ago

andrewjaykeller commented 8 years ago

The Mac and Windows FTDI virtual comm port drivers have big buffers of 4096 which create a fragmented data pulse, there must also be a time component, like every 500 ms it get's cleared, this should be looked into and mimicked in the simulator to provide a better testing environment for graphics developers.

baffo32 commented 7 years ago

Do you have any more information about how these packets appear? Do you mean that data is buffered for ~500ms and then drained in one huge go, with many packets in one buffer?

Alternatively, could you throw a console.log('_processBytes: ' + JSON.stringify('' + data)); into _processBytes and paste some sample output here?

andrewjaykeller commented 7 years ago

It is entirely based on your virtual comm port driver. You have linux, from what i remember so check out your FTDI input buffer size and latency timer. These both work together to determine how often your serial port is dumped.

andrewjaykeller commented 7 years ago

Closed with version 1.4.0