---
title: GCDeviceBattery
framework: gamecontroller
role: symbol
role_heading: Class
path: gamecontroller/gcdevicebattery
---

# GCDeviceBattery

The charge level and state of a device’s battery.

## Declaration

```swift
class GCDeviceBattery
```

## Overview

Overview Use this class to display the state of a device’s battery to a player.

## Topics

### Getting the battery level and state

- [batteryLevel](gamecontroller/gcdevicebattery/batterylevel.md)
- [batteryState](gamecontroller/gcdevicebattery/batterystate.md)
- [GCDeviceBattery.State](gamecontroller/gcdevicebattery/state.md)

## Relationships

### Inherits From

- [NSObject](objectivec/nsobject-swift.class.md)

### Conforms To

- [CVarArg](swift/cvararg.md)
- [CustomDebugStringConvertible](swift/customdebugstringconvertible.md)
- [CustomStringConvertible](swift/customstringconvertible.md)
- [Equatable](swift/equatable.md)
- [Hashable](swift/hashable.md)
- [NSObjectProtocol](objectivec/nsobjectprotocol.md)

## See Also

### Game controller profiles

- [Input](gamecontroller/input.md)
- [GCMotion](gamecontroller/gcmotion.md)
- [GCDeviceHaptics](gamecontroller/gcdevicehaptics.md)
- [GCDeviceLight](gamecontroller/gcdevicelight.md)
