get list of ecg channels in resulting data table for a board :param board_id: Board Id :type board_id: int :param preset: preset :type preset: int :return: list of ecg channels in returned numpy array :rtype: List[int] :raises BrainFlowError:
(cls, board_id: int, preset: int = BrainFlowPresets.DEFAULT_PRESET)
| 960 | |
| 961 | @classmethod |
| 962 | def get_ecg_channels(cls, board_id: int, preset: int = BrainFlowPresets.DEFAULT_PRESET) -> List[int]: |
| 963 | """get list of ecg channels in resulting data table for a board |
| 964 | |
| 965 | :param board_id: Board Id |
| 966 | :type board_id: int |
| 967 | :param preset: preset |
| 968 | :type preset: int |
| 969 | :return: list of ecg channels in returned numpy array |
| 970 | :rtype: List[int] |
| 971 | :raises BrainFlowError: If this board has no such data exit code is UNSUPPORTED_BOARD_ERROR |
| 972 | """ |
| 973 | |
| 974 | num_channels = numpy.zeros(1).astype(numpy.int32) |
| 975 | ecg_channels = numpy.zeros(512).astype(numpy.int32) |
| 976 | |
| 977 | res = BoardControllerDLL.get_instance().get_ecg_channels(board_id, preset, ecg_channels, num_channels) |
| 978 | if res != BrainFlowExitCodes.STATUS_OK.value: |
| 979 | raise BrainFlowError('unable to request info about this board', res) |
| 980 | result = ecg_channels.tolist()[0:num_channels[0]] |
| 981 | return result |
| 982 | |
| 983 | @classmethod |
| 984 | def get_eog_channels(cls, board_id: int, preset: int = BrainFlowPresets.DEFAULT_PRESET) -> List[int]: |
nothing calls this directly
no test coverage detected