diff --git a/spinnman/extended/extended_transceiver.py b/spinnman/extended/extended_transceiver.py index 6c7d68fc1..560b20fa4 100644 --- a/spinnman/extended/extended_transceiver.py +++ b/spinnman/extended/extended_transceiver.py @@ -57,7 +57,6 @@ def create_transceiver_from_hostname( hostname: Optional[str], version: int, *, bmp_connection_data: Optional[List[BMPConnectionData]] = None, - number_of_boards: Optional[int] = None, auto_detect_bmp: bool = False) -> 'ExtendedTransceiver': """ Create a Transceiver by creating a :py:class:`~.UDPConnection` to the @@ -70,9 +69,6 @@ def create_transceiver_from_hostname( :param hostname: The hostname or IP address of the board or `None` if only the BMP connections are of interest :type hostname: str or None - :param number_of_boards: a number of boards expected to be supported, or - ``None``, which defaults to a single board - :type number_of_boards: int or None :param int version: the type of SpiNNaker board used within the SpiNNaker machine being used. If a Spinn-5 board, then the version will be 5, Spinn-3 would equal 3 and so on. @@ -108,7 +104,7 @@ def create_transceiver_from_hostname( assert number_of_boards is not None, \ "number_of_boards must be supplied to work out BMP connections" bmp_connection_data = [ - work_out_bmp_from_machine_details(hostname, number_of_boards)] + work_out_bmp_from_machine_details(hostname)] # handle BMP connections if bmp_connection_data is not None: diff --git a/spinnman/transceiver.py b/spinnman/transceiver.py index 0da8fa57f..215e15078 100644 --- a/spinnman/transceiver.py +++ b/spinnman/transceiver.py @@ -133,7 +133,6 @@ def create_transceiver_from_hostname( hostname: Optional[str], version: int, *, bmp_connection_data: Optional[BMPConnectionData] = None, - number_of_boards: Optional[int] = None, auto_detect_bmp: bool = False, power_cycle: bool =False) -> 'Transceiver': """ @@ -147,9 +146,6 @@ def create_transceiver_from_hostname( :param hostname: The hostname or IP address of the board or `None` if only the BMP connections are of interest :type hostname: str or None - :param number_of_boards: a number of boards expected to be supported, or - ``None``, which defaults to a single board - :type number_of_boards: int or None :param int version: the type of SpiNNaker board used within the SpiNNaker machine being used. If a Spinn-5 board, then the version will be 5, Spinn-3 would equal 3 and so on. @@ -183,11 +179,8 @@ def create_transceiver_from_hostname( (bmp_connection_data is None or not bmp_connection_data)): if hostname is None: raise ValueError("hostname is required if deriving BMP details") - if number_of_boards is None or number_of_boards < 1: - raise ValueError( - "number_of_boards is required if deriving BMP details") bmp_connection_data = work_out_bmp_from_machine_details( - hostname, number_of_boards) + hostname) # handle BMP connections if bmp_connection_data is not None: diff --git a/spinnman/utilities/utility_functions.py b/spinnman/utilities/utility_functions.py index af0d85f87..901b4cf9e 100644 --- a/spinnman/utilities/utility_functions.py +++ b/spinnman/utilities/utility_functions.py @@ -23,7 +23,7 @@ def work_out_bmp_from_machine_details( - hostname: str, number_of_boards: int) -> BMPConnectionData: + hostname: str) -> BMPConnectionData: """ Work out the BMP connection IP address given the machine details. This is assumed to be the IP address of the machine, with 1 subtracted @@ -31,7 +31,6 @@ def work_out_bmp_from_machine_details( BMP IP address is assumed to be 192.168.0.4 :param str hostname: the SpiNNaker machine main hostname or IP address - :param int number_of_boards: the number of boards in the machine :return: The BMP connection data :rtype: BMPConnectionData """ @@ -43,7 +42,7 @@ def work_out_bmp_from_machine_details( # add board scope for each split # if None, the end user didn't enter anything, so assume one board # starting at position 0 - board_range = range(number_of_boards) if number_of_boards else [0] + board_range = [0] # Assume a single board with no cabinet or frame specified return BMPConnectionData(ip_address=bmp_ip_address,