Linus Nielsen Feltzing | 7cafe7a | 2002-07-04 16:09:23 +0000 | [diff] [blame] | 1 | /*************************************************************************** |
| 2 | * __________ __ ___. |
| 3 | * Open \______ \ ____ ____ | | _\_ |__ _______ ___ |
| 4 | * Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ / |
| 5 | * Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < < |
| 6 | * Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \ |
| 7 | * \/ \/ \/ \/ \/ |
| 8 | * $Id$ |
| 9 | * |
| 10 | * Copyright (C) 2002 by Linus Nielsen Feltzing |
| 11 | * |
Daniel Stenberg | 2acc0ac | 2008-06-28 18:10:04 +0000 | [diff] [blame^] | 12 | * This program is free software; you can redistribute it and/or |
| 13 | * modify it under the terms of the GNU General Public License |
| 14 | * as published by the Free Software Foundation; either version 2 |
| 15 | * of the License, or (at your option) any later version. |
Linus Nielsen Feltzing | 7cafe7a | 2002-07-04 16:09:23 +0000 | [diff] [blame] | 16 | * |
| 17 | * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY |
| 18 | * KIND, either express or implied. |
| 19 | * |
| 20 | ****************************************************************************/ |
| 21 | #ifndef _POWER_H_ |
| 22 | #define _POWER_H_ |
| 23 | |
Jens Arnold | 0dd1f8e | 2006-06-06 22:23:52 +0000 | [diff] [blame] | 24 | #if CONFIG_CHARGING == CHARGING_CONTROL |
Heikki Hannikainen | 3f809e7 | 2002-08-06 10:50:50 +0000 | [diff] [blame] | 25 | extern bool charger_enabled; |
Hristo Kovachev | 14cfc65 | 2006-02-07 14:46:03 +0000 | [diff] [blame] | 26 | void charger_enable(bool on); |
Heikki Hannikainen | 3f809e7 | 2002-08-06 10:50:50 +0000 | [diff] [blame] | 27 | #endif |
| 28 | |
Jonathan Gordon | 9a6f419 | 2007-02-18 05:32:06 +0000 | [diff] [blame] | 29 | #if CONFIG_CHARGING |
Linus Nielsen Feltzing | 7cafe7a | 2002-07-04 16:09:23 +0000 | [diff] [blame] | 30 | bool charger_inserted(void); |
Hristo Kovachev | 14cfc65 | 2006-02-07 14:46:03 +0000 | [diff] [blame] | 31 | #endif |
| 32 | |
Linus Nielsen Feltzing | 4edf8ae | 2002-07-05 07:10:22 +0000 | [diff] [blame] | 33 | void power_off(void); |
Hristo Kovachev | 14cfc65 | 2006-02-07 14:46:03 +0000 | [diff] [blame] | 34 | void ide_power_enable(bool on); |
| 35 | |
Jens Arnold | 0dd1f8e | 2006-06-06 22:23:52 +0000 | [diff] [blame] | 36 | # if CONFIG_CHARGING == CHARGING_MONITOR |
Hristo Kovachev | 14cfc65 | 2006-02-07 14:46:03 +0000 | [diff] [blame] | 37 | bool charging_state(void); |
| 38 | # endif |
| 39 | |
Nils Wallménius | f28da1a | 2007-08-12 19:49:03 +0000 | [diff] [blame] | 40 | #ifndef SIMULATOR |
| 41 | |
| 42 | void power_init(void); |
| 43 | |
Hristo Kovachev | 14cfc65 | 2006-02-07 14:46:03 +0000 | [diff] [blame] | 44 | bool ide_powered(void); |
| 45 | #endif |
Linus Nielsen Feltzing | 7cafe7a | 2002-07-04 16:09:23 +0000 | [diff] [blame] | 46 | |
Linus Nielsen Feltzing | e6bc6c4 | 2005-04-11 11:17:31 +0000 | [diff] [blame] | 47 | #ifdef HAVE_SPDIF_POWER |
| 48 | void spdif_power_enable(bool on); |
Michael Sevakis | cc50c14 | 2006-11-13 23:21:54 +0000 | [diff] [blame] | 49 | bool spdif_powered(void); |
Linus Nielsen Feltzing | e6bc6c4 | 2005-04-11 11:17:31 +0000 | [diff] [blame] | 50 | #endif |
| 51 | |
Jens Arnold | c652218 | 2007-02-18 08:46:12 +0000 | [diff] [blame] | 52 | #if CONFIG_TUNER |
Jens Arnold | 8a17734 | 2007-08-14 22:06:23 +0000 | [diff] [blame] | 53 | bool tuner_power(bool status); |
Jörg Hohensohn | 91f9350 | 2004-10-17 08:53:18 +0000 | [diff] [blame] | 54 | #endif |
| 55 | |
Linus Nielsen Feltzing | 7cafe7a | 2002-07-04 16:09:23 +0000 | [diff] [blame] | 56 | #endif |