1#
2# Copyright (C) 2020 The Android Open Source Project
3#
4# Licensed under the Apache License, Version 2.0 (the "License");
5# you may not use this file except in compliance with the License.
6# You may obtain a copy of the License at
7#
8#      http://www.apache.org/licenses/LICENSE-2.0
9#
10# Unless required by applicable law or agreed to in writing, software
11# distributed under the License is distributed on an "AS IS" BASIS,
12# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13# See the License for the specific language governing permissions and
14# limitations under the License.
15#
16
17#RBC# type_hint string TROUT_KERNEL_IMAGE
18
19TARGET_USES_CF_RILD ?= false
20$(call inherit-product, device/google/cuttlefish/vsoc_arm64_only/auto/aosp_cf.mk)
21
22# Prefer ext4 for the system image
23TARGET_RO_FILE_SYSTEM_TYPE := ext4
24
25# Audio HAL
26# TODO: turn back on goldfish HAL and HFP
27TARGET_USES_CUTTLEFISH_AUDIO ?= false
28AUDIO_FEATURE_HFP_ENABLED ?= true
29
30# Audio Control HAL
31# TODO (chenhaosjtuacm, egranata): move them to kernel command line
32LOCAL_AUDIOCONTROL_PROPERTIES ?= \
33    ro.vendor.audiocontrol.server.cid=1000 \
34    ro.vendor.audiocontrol.server.port=9410 \
35
36# Tracing Server Address
37LOCAL_TRACING_SERVER_PROPERTIES ?= \
38    ro.vendor.tracing.server.cid=1000 \
39    ro.vendor.tracing.server.port=9510 \
40
41include device/google/trout/aosp_trout_common.mk
42
43DEVICE_MANIFEST_FILE += device/google/trout/trout_arm64/manifest.xml
44
45PRODUCT_PROPERTY_OVERRIDES += \
46	vendor.ser.bt-uart?= \
47
48PRODUCT_PACKAGES += \
49	vport_trigger \
50
51# Sensor HAL
52# The implementations use SCMI, which only works on arm architecture
53LOCAL_SENSOR_PRODUCT_PACKAGE ?= \
54    android.hardware.sensors-service.multihal \
55    android.hardware.sensors-service.multihal.rc \
56    android.hardware.sensors@2.1-Google-IIO-Subhal \
57
58LOCAL_SENSOR_FILE_OVERRIDES := true
59
60LOCAL_ENABLE_OEMLOCK ?= false
61
62LOCAL_ENABLE_LIGHT ?= false
63
64UEVENTD_ODM_COPY_FILE ?= device/google/trout/product_files/odm/ueventd.rc
65
66PRODUCT_COPY_FILES += \
67    $(UEVENTD_ODM_COPY_FILE):$(TARGET_COPY_OUT_ODM)/etc/ueventd.rc \
68    device/google/trout/hal/sensors/2.1/config/sensor_hal_configuration.xml:$(TARGET_COPY_OUT_VENDOR)/etc/sensors/sensor_hal_configuration.xml \
69    device/google/trout/product_files/odm/usr/idc/Vendor_0fff_Product_0fff.idc:$(TARGET_COPY_OUT_ODM)/usr/idc/Vendor_0fff_Product_0fff.idc \
70    device/google/trout/product_files/vendor/etc/sensors/hals.conf:$(TARGET_COPY_OUT_VENDOR)/etc/sensors/hals.conf \
71    frameworks/native/data/etc/android.hardware.sensor.gyroscope.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.sensor.gyroscope.xml \
72    frameworks/native/data/etc/android.hardware.sensor.accelerometer.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.sensor.accelerometer.xml \
73
74# WiFi configuration
75PRODUCT_ENFORCE_MAC80211_HWSIM ?= false
76ifndef DEVICE_VIRTWIFI_PORT
77DEVICE_VIRTWIFI_PORT := eth0
78endif
79PRODUCT_PROPERTY_OVERRIDES += ro.vendor.disable_rename_eth0?=true
80PRODUCT_COPY_FILES += device/google/trout/trout_arm64/wifi/virtwifi.sh:$(TARGET_COPY_OUT_VENDOR)/bin/virtwifi.sh
81PRODUCT_COPY_FILES += device/google/trout/trout_arm64/wifi/virtwifi.rc:$(TARGET_COPY_OUT_VENDOR)/etc/init/virtwifi.rc
82
83PRODUCT_NAME := aosp_trout_arm64
84PRODUCT_DEVICE := trout_arm64
85PRODUCT_MODEL := arm64 trout
86