MCPcopy Create free account
hub / github.com/brainflow-dev/brainflow / runExample

Function runExample

nodejs_package/tests/serialization.ts:8–24  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

6}
7
8async function runExample (): Promise<void>
9{
10 const board = new BoardShim (BoardIds.SYNTHETIC_BOARD, {});
11 board.prepareSession();
12 board.startStream();
13 await sleep (3000);
14 board.stopStream();
15 const data = board.getCurrentBoardData(10);
16 board.releaseSession()
17 console.info('Data');
18 console.info(data);
19 DataFilter.writeFile(data, 'test.csv', 'w');
20 const dataRestored = DataFilter.readFile('test.csv');
21 console.info('Data restored');
22 console.info(dataRestored);
23 DataFilter.writeFile(dataRestored, 'test2.csv', 'w');
24}
25
26runExample ();

Callers 1

serialization.tsFile · 0.70

Calls 8

prepareSessionMethod · 0.95
startStreamMethod · 0.95
stopStreamMethod · 0.95
getCurrentBoardDataMethod · 0.95
releaseSessionMethod · 0.95
writeFileMethod · 0.80
readFileMethod · 0.80
sleepFunction · 0.70

Tested by

no test coverage detected