[mce] Add charger type D-Bus constants. JB#38667

Constants related to exposing charger type on D-Bus.

Signed-off-by: Simo Piiroinen <simo.piiroinen@jollamobile.com>
This commit is contained in:
Simo Piiroinen
2019-08-20 13:41:07 +03:00
parent 03a4de12e5
commit 5ee3ef6125
2 changed files with 85 additions and 2 deletions

View File

@@ -5,7 +5,8 @@
* This file is part of mce-dev
* <p>
* Copyright © 2004-2011 Nokia Corporation and/or its subsidiary(-ies).
* Copyright (C) 2013-2017 Jolla Ltd.
* Copyright (C) 2013-2019 Jolla Ltd.
* Copyright (c) 2019 Open Mobile Platform LLC.
* <p>
* @author David Weinehall <david.weinehall@nokia.com>
* @author Santtu Lakkala <ext-santtu.1.lakkala@nokia.com>
@@ -862,6 +863,36 @@
*/
# define MCE_BATTERY_LEVEL_SIG "battery_level_ind"
/** Query current charger type
*
* @since mce 1.102.0
*
* @return string: current charger type, one of:
* - #MCE_CHARGER_TYPE_NONE
* - #MCE_CHARGER_TYPE_USB
* - #MCE_CHARGER_TYPE_DCP
* - #MCE_CHARGER_TYPE_HVDCP
* - #MCE_CHARGER_TYPE_CDP
* - #MCE_CHARGER_TYPE_WIRELESS
* - #MCE_CHARGER_TYPE_OTHER
*/
# define MCE_CHARGER_TYPE_GET "get_charger_type"
/** Signal that indicates that charger type has changed
*
* @since mce 1.102.0
*
* @param charger_type string: current charger type, one of:
* - #MCE_CHARGER_TYPE_NONE
* - #MCE_CHARGER_TYPE_USB
* - #MCE_CHARGER_TYPE_DCP
* - #MCE_CHARGER_TYPE_HVDCP
* - #MCE_CHARGER_TYPE_CDP
* - #MCE_CHARGER_TYPE_WIRELESS
* - #MCE_CHARGER_TYPE_OTHER
*/
# define MCE_CHARGER_TYPE_SIG "charger_type_ind"
/*@}*/
/////////////////////////////////////////////////////////////////////////////

View File

@@ -5,7 +5,8 @@
* This file is part of mce-dev
* <p>
* Copyright © 2004-2011 Nokia Corporation and/or its subsidiary(-ies).
* Copyright (C) 2012-2017 Jolla Ltd.
* Copyright (C) 2012-2019 Jolla Ltd.
* Copyright (c) 2019 Open Mobile Platform LLC.
* <p>
* @author David Weinehall <david.weinehall@nokia.com>
* @author Tapio Rantala <ext-tapio.rantala@nokia.com>
@@ -430,6 +431,57 @@
/*@}*/
/////////////////////////////////////////////////////////////////////////////
/////////////////////////////////////////////////////////////////////////////
/** @name Charger Type Constants
*
*@{
*/
/** No charger is active
*
* @since mce 1.102.0
*/
# define MCE_CHARGER_TYPE_NONE "none"
/** Standard down port (pc/hub) charger is active
*
* @since mce 1.102.0
*/
# define MCE_CHARGER_TYPE_USB "usb"
/** Dedicated charging port (wall) charger is active
*
* @since mce 1.102.0
*/
# define MCE_CHARGER_TYPE_DCP "dcp"
/** High voltage DCP charger is active
*
* @since mce 1.102.0
*/
# define MCE_CHARGER_TYPE_HVDCP "hvdcp"
/** Charging Downstream Port charger is active
*
* @since mce 1.102.0
*/
# define MCE_CHARGER_TYPE_CDP "cdp"
/** Wireless charger is active
*
* @since mce 1.102.0
*/
# define MCE_CHARGER_TYPE_WIRELESS "wireless"
/** Other kind of charger is active
*
* @since mce 1.102.0
*/
# define MCE_CHARGER_TYPE_OTHER "other"
/*@}*/
/////////////////////////////////////////////////////////////////////////////
/////////////////////////////////////////////////////////////////////////////
/** @name Battery Status Constants