Skip to content

Commit

Permalink
rename to bmp_selector
Browse files Browse the repository at this point in the history
  • Loading branch information
Christian-B committed Aug 1, 2023
1 parent 04dc054 commit 3c7c53b
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
4 changes: 2 additions & 2 deletions spinnman/extended/extended_transceiver.py
Original file line number Diff line number Diff line change
Expand Up @@ -451,7 +451,7 @@ def set_led(self, led, action, board, cabinet, frame):
warn_once(logger, "The set_led method is deprecated and "
"untested due to no known use.")
process = SendSingleCommandProcess(
self._bmp_connection(cabinet, frame))
self._bmp_selector(cabinet, frame))
process.execute(BMPSetLed(led, action, board))

def read_adc_data(self, board, cabinet, frame):
Expand All @@ -472,7 +472,7 @@ def read_adc_data(self, board, cabinet, frame):
warn_once(logger, "The read_adc_data method is deprecated and "
"untested due to no known use.")
process = SendSingleCommandProcess(
self._bmp_connection(cabinet, frame))
self._bmp_selector(cabinet, frame))
response = process.execute(ReadADC(board))
return response.adc_info # pylint: disable=no-member

Expand Down
10 changes: 5 additions & 5 deletions spinnman/transceiver.py
Original file line number Diff line number Diff line change
Expand Up @@ -1103,7 +1103,7 @@ def power_off(self, boards=0, cabinet=0, frame=0):
"""
self._power(PowerCommand.POWER_OFF, boards, cabinet, frame)

def _bmp_connection(self, cabinet, frame):
def _bmp_selector(self, cabinet, frame):
"""
:param int cabinet:
:param int frame:
Expand All @@ -1128,7 +1128,7 @@ def _power(self, power_command, boards=0, cabinet=0, frame=0):
:param int frame: the ID of the frame in the cabinet containing the
board(s), or 0 if the board is not in a frame
"""
connection_selector = self._bmp_connection(cabinet, frame)
connection_selector = self._bmp_selector(cabinet, frame)
timeout = (
BMP_POWER_ON_TIMEOUT
if power_command == PowerCommand.POWER_ON
Expand Down Expand Up @@ -1158,7 +1158,7 @@ def read_fpga_register(self, fpga_num, register, cabinet, frame, board):
:rtype: int
"""
process = SendSingleCommandProcess(
self._bmp_connection(cabinet, frame), timeout=1.0)
self._bmp_selector(cabinet, frame), timeout=1.0)
response = process.execute(
ReadFPGARegister(fpga_num, register, board))
return response.fpga_register # pylint: disable=no-member
Expand All @@ -1179,7 +1179,7 @@ def write_fpga_register(self, fpga_num, register, value, cabinet, frame,
:param int board: which board to write the FPGA register to
"""
process = SendSingleCommandProcess(
self._bmp_connection(cabinet, frame))
self._bmp_selector(cabinet, frame))
process.execute(
WriteFPGARegister(fpga_num, register, value, board))

Expand All @@ -1193,7 +1193,7 @@ def read_bmp_version(self, board, cabinet, frame):
:return: the sver from the BMP
"""
process = SendSingleCommandProcess(
self._bmp_connection(cabinet, frame))
self._bmp_selector(cabinet, frame))
response = process.execute(BMPGetVersion(board))
return response.version_info # pylint: disable=no-member

Expand Down

0 comments on commit 3c7c53b

Please sign in to comment.