diff options
author | TreeHugger Robot <treehugger-gerrit@google.com> | 2020-05-13 00:14:01 +0000 |
---|---|---|
committer | Android (Google) Code Review <android-gerrit@google.com> | 2020-05-13 00:14:01 +0000 |
commit | 65b5b59408c9bacf3b5583850cf53913c8206d06 (patch) | |
tree | 2752b489ecce79f0527d576c71383bb63bbbcdf4 /apps | |
parent | f93beba8f8b7e3a364e9e36d63bd7abcd3ea2ab9 (diff) | |
parent | e21d09cdde5592897ff3c353e636fd310595dbd5 (diff) | |
download | chre-65b5b59408c9bacf3b5583850cf53913c8206d06.tar.gz |
Merge "Add skeleton nanoapp for audio concurrency test" into rvc-dev
Diffstat (limited to 'apps')
-rw-r--r-- | apps/test/common/chre_audio_concurrency_test/Makefile | 39 | ||||
-rw-r--r-- | apps/test/common/chre_audio_concurrency_test/src/chre_audio_concurrency_test.cc | 31 |
2 files changed, 70 insertions, 0 deletions
diff --git a/apps/test/common/chre_audio_concurrency_test/Makefile b/apps/test/common/chre_audio_concurrency_test/Makefile new file mode 100644 index 00000000..a6cfdd2c --- /dev/null +++ b/apps/test/common/chre_audio_concurrency_test/Makefile @@ -0,0 +1,39 @@ +# +# CHRE Audio Concurrency Test Nanoapp Makefile +# + +# Environment Checks ########################################################### +ifeq ($(CHRE_PREFIX),) + ifneq ($(ANDROID_BUILD_TOP),) + CHRE_PREFIX = $(ANDROID_BUILD_TOP)/system/chre + else + $(error "You must run 'lunch' to setup ANDROID_BUILD_TOP, or explicitly \ + define the CHRE_PREFIX environment variable to point to the CHRE root \ + directory.") + endif +endif + +# Nanoapp Configuration ######################################################## + +NANOAPP_NAME = chre_audio_concurrency_test +NANOAPP_ID = 0x476f6f6754000004 +NANOAPP_NAME_STRING = \"Chre\ Audio\ Concurrency\ Test\" +NANOAPP_VERSION = 0x00000001 + +NANOAPP_PATH = $(CHRE_PREFIX)/apps/test/common/chre_audio_concurrency_test + +# Source Code ################################################################## + +COMMON_SRCS += $(NANOAPP_PATH)/src/chre_audio_concurrency_test.cc + +# Compiler Flags ############################################################### + +# Defines +COMMON_CFLAGS += -DNANOAPP_MINIMUM_LOG_LEVEL=CHRE_LOG_LEVEL_INFO + +# Includes +COMMON_CFLAGS += -I$(NANOAPP_PATH)/inc + +# Makefile Includes ############################################################ + +include $(CHRE_PREFIX)/build/nanoapp/app.mk diff --git a/apps/test/common/chre_audio_concurrency_test/src/chre_audio_concurrency_test.cc b/apps/test/common/chre_audio_concurrency_test/src/chre_audio_concurrency_test.cc new file mode 100644 index 00000000..9edb7213 --- /dev/null +++ b/apps/test/common/chre_audio_concurrency_test/src/chre_audio_concurrency_test.cc @@ -0,0 +1,31 @@ +/* + * Copyright (C) 2020 The Android Open Source Project + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include <chre.h> +#include <cinttypes> + +namespace chre { + +extern "C" void nanoappHandleEvent(uint32_t senderInstanceId, + uint16_t eventType, const void *eventData) {} + +extern "C" bool nanoappStart(void) { + return true; +} + +extern "C" void nanoappEnd(void) {} + +} // namespace chre |