Merge "uwb: support per device calibration for F10" into tm-qpr-dev am: 110e50e82c
am: c0ea4c75e3
Original change: https://googleplex-android-review.googlesource.com/c/device/google/felix/+/19357496 Change-Id: I9708b9437467c9272088bc96cb17eb36214991a4 Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
This commit is contained in:
commit
92f980c0e6
3 changed files with 36 additions and 4 deletions
|
@ -32,7 +32,6 @@ $(call soong_config_set,fp_hal_feature,pixel_product, product_a)
|
||||||
include hardware/google/pixel/vibrator/cs40l26/device-stereo.mk
|
include hardware/google/pixel/vibrator/cs40l26/device-stereo.mk
|
||||||
include device/google/gs101/bluetooth/bluetooth.mk
|
include device/google/gs101/bluetooth/bluetooth.mk
|
||||||
ifeq ($(filter factory_felix, $(TARGET_PRODUCT)),)
|
ifeq ($(filter factory_felix, $(TARGET_PRODUCT)),)
|
||||||
include device/google/gs101/uwb/uwb.mk
|
|
||||||
include device/google/felix/uwb/uwb_calibration.mk
|
include device/google/felix/uwb/uwb_calibration.mk
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
|
26
uwb/init.uwb.calib.xtal.sh
Normal file
26
uwb/init.uwb.calib.xtal.sh
Normal file
|
@ -0,0 +1,26 @@
|
||||||
|
#!/vendor/bin/sh
|
||||||
|
# only use xtal_trim from factory calibration
|
||||||
|
if [ -z "$2" ]
|
||||||
|
then
|
||||||
|
echo "usage is $0 input-calibration output_calibration"
|
||||||
|
exit 0
|
||||||
|
fi
|
||||||
|
OUTPUT_CALIB="$2"
|
||||||
|
if [ ! -f "$OUTPUT_CALIB" ]; then
|
||||||
|
touch $OUTPUT_CALIB
|
||||||
|
chmod 0644 $OUTPUT_CALIB
|
||||||
|
file="$1"
|
||||||
|
while IFS=, read -r f1 f2
|
||||||
|
do
|
||||||
|
case $f1 in
|
||||||
|
"UWB_cal_tx_xtal_reg_final_value")
|
||||||
|
if [ $((0x$f2)) -gt 63 ]; then
|
||||||
|
f2=63
|
||||||
|
fi
|
||||||
|
echo 'xtal_trim=0x'$f2 >> $OUTPUT_CALIB
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
done <"$file"
|
||||||
|
exit 0
|
||||||
|
fi
|
||||||
|
|
|
@ -13,9 +13,16 @@
|
||||||
# See the License for the specific language governing permissions and
|
# See the License for the specific language governing permissions and
|
||||||
# limitations under the License.
|
# limitations under the License.
|
||||||
|
|
||||||
|
# UWB - ultra wide band
|
||||||
|
$(call inherit-product-if-exists, vendor/qorvo/uwb/uwb.mk)
|
||||||
|
|
||||||
LOCAL_UWB_CAL_DIR=device/google/felix/uwb
|
LOCAL_UWB_CAL_DIR=device/google/felix/uwb
|
||||||
|
|
||||||
PRODUCT_COPY_FILES += \
|
PRODUCT_COPY_FILES += \
|
||||||
$(LOCAL_UWB_CAL_DIR)/UWB-calibration.conf:$(TARGET_COPY_OUT_VENDOR)/etc/UWB-calibration.conf \
|
$(LOCAL_UWB_CAL_DIR)/UWB-calibration.conf:$(TARGET_COPY_OUT_VENDOR)/etc/uwb/UWB-calibration.conf \
|
||||||
$(LOCAL_UWB_CAL_DIR)/UWB-calibration.conf:$(TARGET_COPY_OUT_VENDOR)/etc/UWB-calibration-unknown.conf \
|
$(LOCAL_UWB_CAL_DIR)/UWB-calibration.conf:$(TARGET_COPY_OUT_VENDOR)/etc/uwb/UWB-calibration-unknown.conf \
|
||||||
$(LOCAL_UWB_CAL_DIR)/UWB-calibration.conf:$(TARGET_COPY_OUT_VENDOR)/etc/UWB-calibration-default.conf \
|
$(LOCAL_UWB_CAL_DIR)/UWB-calibration.conf:$(TARGET_COPY_OUT_VENDOR)/etc/uwb/UWB-calibration-default.conf \
|
||||||
|
$(LOCAL_UWB_CAL_DIR)/init.uwb.calib.xtal.sh:$(TARGET_COPY_OUT_VENDOR)/bin/init.uwb.calib.sh \
|
||||||
|
|
||||||
|
PRODUCT_COPY_FILES += \
|
||||||
|
frameworks/native/data/etc/android.hardware.uwb.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.uwb.xml
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue