test public
Dependencies: HttpServer_snapshot_mbed-os
DeepStandby.h
00001 /********************************************************************************************************************** 00002 * DISCLAIMER 00003 * This software is supplied by Renesas Electronics Corporation and is only intended for use with Renesas products. No 00004 * other uses are authorized. This software is owned by Renesas Electronics Corporation and is protected under all 00005 * applicable laws, including copyright laws. 00006 * THIS SOFTWARE IS PROVIDED "AS IS" AND RENESAS MAKES NO WARRANTIES REGARDING 00007 * THIS SOFTWARE, WHETHER EXPRESS, IMPLIED OR STATUTORY, INCLUDING BUT NOT LIMITED TO WARRANTIES OF MERCHANTABILITY, 00008 * FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT. ALL SUCH WARRANTIES ARE EXPRESSLY DISCLAIMED. TO THE MAXIMUM 00009 * EXTENT PERMITTED NOT PROHIBITED BY LAW, NEITHER RENESAS ELECTRONICS CORPORATION NOR ANY OF ITS AFFILIATED COMPANIES 00010 * SHALL BE LIABLE FOR ANY DIRECT, INDIRECT, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES FOR ANY REASON RELATED TO 00011 * THIS SOFTWARE, EVEN IF RENESAS OR ITS AFFILIATES HAVE BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. 00012 * Renesas reserves the right, without notice, to make changes to this software and to discontinue the availability of 00013 * this software. By using this software, you agree to the additional terms and conditions found by accessing the 00014 * following link: 00015 * http://www.renesas.com/disclaimer 00016 * 00017 * Copyright (C) 2019 Renesas Electronics Corporation. All rights reserved. 00018 *********************************************************************************************************************/ 00019 /**************************************************************************//** 00020 * @file DeepStandby.h 00021 * @brief DeepStandby API 00022 ******************************************************************************/ 00023 00024 #ifndef DEEP_STANDBY_H 00025 #define DEEP_STANDBY_H 00026 00027 #include "mbed.h" 00028 00029 /** A class to communicate a DeepStandby 00030 * 00031 */ 00032 class DeepStandby { 00033 public: 00034 00035 typedef struct { 00036 bool button0; /*!< Works with GR_LYCHEE, RZ_A2M_EVB and SEMB1402. */ 00037 bool button1; /*!< Works with GR_LYCHEE, RZ_A2M_EVB and RZ_A2M_SBEV. */ 00038 bool rtc; /*!< Works with RZ_A1, GR_LYCHEE, RZ_A2M_EVB, RZ_A2M_SBEV and SEMB1402. */ 00039 } cancel_src_simple_t; 00040 00041 /** Set deep standby mode 00042 * 00043 * @param src Factors that cancel deep standby. 00044 */ 00045 static void SetDeepStandbySimple(cancel_src_simple_t *src); 00046 00047 /** Get deep standby cancel source 00048 * 00049 * @param src Factor that canceled deep standby. 00050 * @return true : Deep standby canceled. false : Reset start. 00051 */ 00052 static bool GetCancelSourceSimple(cancel_src_simple_t *src); 00053 00054 00055 00056 typedef struct { 00057 uint8_t rramkp; /*!< Value of RRAMKP register */ 00058 uint16_t dsssr; /*!< Value of DSSSR register */ 00059 uint16_t dsesr; /*!< Value of DSESR register */ 00060 uint16_t usbdsssr; /*!< Value of USBDSSSR register (Used only with RZ/A2M) */ 00061 } cancel_src_direct_t; 00062 00063 /** Set deep standby mode 00064 * 00065 * @param src Factors that cancel deep standby. 00066 */ 00067 static void SetDeepStandbyDirect(cancel_src_direct_t *src); 00068 00069 /** Get deep standby cancel source 00070 * 00071 * @param dsfr Value of DSFR register 00072 * @param usbdsfr Value of USBDSFR register 00073 * @return true : Deep standby canceled. false : Reset start. 00074 */ 00075 static bool GetCancelSourceDirect(uint16_t *dsfr, uint8_t *usbdsfr); 00076 00077 }; 00078 #endif
Generated on Wed Jul 13 2022 05:33:36 by 1.7.2