Problem
For CYTON_WIFI_BOARD, BrainFlow seems to allow sending Cyton sample-rate commands such as ~5 (500 Hz), but the current sample rate is not synchronized back to the high-level API.
As a result:
config_board("~5") appears to successfully switch the board to 500 Hz
- but
BoardShim.get_sampling_rate(BoardIds.CYTON_WIFI_BOARD) still returns 1000
- and commands that should return text responses, such as
~~ (query current sample rate) and V (firmware version), return an empty string on the WiFi path
This makes it difficult to reliably use the actual runtime sample rate from BrainFlow.
Environment
- Board: OpenBCI Cyton + WiFi Shield
- BrainFlow in OpenBCI GUI: 5.10.0
- OpenBCI GUI: v6.0.0-beta.1
- OS: Windows 10
- Python environment: Anaconda / Python 3.10
- Connection type: WiFi (
CYTON_WIFI_BOARD)
What I observed
1. get_sampling_rate() always returns 1000 for CYTON_WIFI_BOARD
In Python:
he same behavior is visible in OpenBCI GUI Expert Mode:
Sending config string to board: V
[SUCCESS]: [ExpertMode] Success sending command to board: V
ADSSettingsController: Response ==
So the command appears to be sent successfully, but the response is not exposed to the caller.
Why I think this is a BrainFlow API issue From the BrainFlow source:
brainflow_boards.cpp defines a static board description for CYTON_WIFI_BOARD with sampling_rate = 1000
openbci_wifi_shield_board.cpp appears to hardcode ~4 during WiFi initialization
config_board(...) on the WiFi board just forwards the raw command string
So currently BrainFlow seems to support:
sending raw commands like ~5
but does not provide:
a synchronized runtime sampling rate for CYTON_WIFI_BOARD
a reliable way to read back the current sample rate over WiFi
a dedicated API like set_sampling_rate() / get_current_sampling_rate()
Expected behavior
At least one of the following would make the behavior consistent:
get_sampling_rate() reflects the current runtime sampling rate after config_board("~5")
command responses for ~~ and V are correctly returned on the WiFi path
BrainFlow exposes an explicit runtime API for Cyton WiFi sample rate configuration/query
documentation clearly states that:
get_sampling_rate(board_id) is static metadata only
WiFi command responses may be empty
users must track runtime sampling rate manually after config_board("~X")
Problem
For
CYTON_WIFI_BOARD, BrainFlow seems to allow sending Cyton sample-rate commands such as~5(500 Hz), but the current sample rate is not synchronized back to the high-level API.As a result:
config_board("~5")appears to successfully switch the board to 500 HzBoardShim.get_sampling_rate(BoardIds.CYTON_WIFI_BOARD)still returns1000~~(query current sample rate) andV(firmware version), return an empty string on the WiFi pathThis makes it difficult to reliably use the actual runtime sample rate from BrainFlow.
Environment
CYTON_WIFI_BOARD)What I observed
1.
get_sampling_rate()always returns 1000 forCYTON_WIFI_BOARDIn Python:
he same behavior is visible in OpenBCI GUI Expert Mode:
Sending config string to board: V
[SUCCESS]: [ExpertMode] Success sending command to board: V
ADSSettingsController: Response ==
So the command appears to be sent successfully, but the response is not exposed to the caller.
Why I think this is a BrainFlow API issue From the BrainFlow source:
brainflow_boards.cpp defines a static board description for CYTON_WIFI_BOARD with sampling_rate = 1000
openbci_wifi_shield_board.cpp appears to hardcode ~4 during WiFi initialization
config_board(...) on the WiFi board just forwards the raw command string
So currently BrainFlow seems to support:
sending raw commands like ~5
but does not provide:
a synchronized runtime sampling rate for CYTON_WIFI_BOARD
a reliable way to read back the current sample rate over WiFi
a dedicated API like set_sampling_rate() / get_current_sampling_rate()
Expected behavior
At least one of the following would make the behavior consistent:
get_sampling_rate() reflects the current runtime sampling rate after config_board("~5")
command responses for ~~ and V are correctly returned on the WiFi path
BrainFlow exposes an explicit runtime API for Cyton WiFi sample rate configuration/query
documentation clearly states that:
get_sampling_rate(board_id) is static metadata only
WiFi command responses may be empty
users must track runtime sampling rate manually after config_board("~X")