# node-poweredup Class: PoweredUP

# Class: PoweredUP

## PoweredUP

#### new PoweredUP()

  Source:
    - poweredup-node.js, line 32

### Extends

- EventEmitter

### Methods

#### getHubByPrimaryMACAddress(address)

  Retrieve a Powered UP Hub by primary MAC address.

  ##### Parameters:

  Name | Type | Description
  --- | --- | ---
  `address` | string |

  Source:
    - poweredup-node.js, line 87

  ##### Returns:

  Type
    BaseHub

#### getHubByUUID(uuid)

  Retrieve a Powered UP Hub by UUID.

  ##### Parameters:

  Name | Type | Description
  --- | --- | ---
  `uuid` | string |

  Source:
    - poweredup-node.js, line 78

  ##### Returns:

  Type
    BaseHub | null

#### getHubs()

  Retrieve a list of Powered UP Hubs.

  Source:
    - poweredup-node.js, line 70

  ##### Returns:

  Type
    Array.<BaseHub>

#### getHubsByName(name)

  Retrieve a list of Powered UP Hub by name.

  ##### Parameters:

  Name | Type | Description
  --- | --- | ---
  `name` | string |

  Source:
    - poweredup-node.js, line 96

  ##### Returns:

  Type
    Array.<BaseHub>

#### getHubsByType(name)

  Retrieve a list of Powered UP Hub by type.

  ##### Parameters:

  Name | Type | Description
  --- | --- | ---
  `name` | string |

  Source:
    - poweredup-node.js, line 105

  ##### Returns:

  Type
    Array.<BaseHub>

#### scan()

  Begin scanning for Powered UP Hub devices.

  Source:
    - poweredup-node.js, line 42

#### stop()

  Stop scanning for Powered UP Hub devices.

  Source:
    - poweredup-node.js, line 58

### Events

#### discover

  Emits when a Powered UP Hub device is found.

  ##### Parameters:

  Name | Type | Description
  --- | --- | ---
  `hub` | WeDo2SmartHub | MoveHub | TechnicMediumHub | Hub | RemoteControl | DuploTrainBase |

  Source:
    - poweredup-node.js, line 152

#### Search results