summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2018-05-23Merge "bmi160: fix step counter flush when spi command cannot be issued ↵pie-devTreeHugger Robot
immediately" into pi-dev
2018-05-22bmi160: fix step counter flush when spi command cannot be issued immediatelyBen Fennema
Switch the order of the two operands in the && statement to avoid short circuit evaluation from preventing stepCntFlushGetData from being called when mTask.sensors[STEPCNT].flush > 0. Bug: 80143800 Test: turn all sensors on with SensorLogger and issue a flush and verify step counter flush increments Signed-off-by: Ben Fennema <fennema@google.com> Change-Id: I7019d5b9fd9908834efd7d4a41f7c919f19c9135
2018-05-22[IMU_Cal] Fixes Runtime Calibration Data StorageDavid Jacobs
- Corrects NanoSensorCal calibration parameter storage to cal.bin/txt. - Syncs minor code improvements from Google3. Tip of G3 CL: 197510514 Bug: 79481105 Test: ./load_app.sh and verified calibrations on device. Change-Id: I8688f88a62aebdbdd92fc37e07108a627167219b
2018-05-19[Bosch BMI160 Driver] Provides immediate accel calibration updates.David Jacobs
Removes the logic that limited accelerometer calibration updates to the only when the sensor was off. Bug: 77295575 Test: Built firmware and tested on a device. Change-Id: Ib731fbe896522f17f605437a86a9d9df6660c609
2018-05-17sensorhal: allow accel bias updates while accel enabledBen Fennema
Set mAccelEnabledBias to mAccelBias when the first accel sample is received after calibrated accel is enabled. It is set based on the first accel sample received so that if there is a bias update after enabling but prior to outputing any accel samples, it is used instead of the old bias value. Update calibrated accel samples by adding mAccelBias and subtracting mAccelEnabledBias. As long as there is an active accel client, use mAccelEnabledBias for uncalibrated accel bias as well. Bug: 77729211 Test: verify updating accel bias doesn't cause jumps in accel values Change-Id: I7ead05a1dfef48659538543322e984174bc8dde0 Signed-off-by: Ben Fennema <fennema@google.com>
2018-05-15[IMU_Cal] Runtime sensor calibration code update.David Jacobs
Removes unused functionality from the calibration base class. Tip of G3 CL: 196582845 Bug: 75333210 (refactor updates) Test: ./load_app.sh and verified calibrations on device. Change-Id: I689e60b72fbbb7b7ab59f96c7d9d18dbea83ab14
2018-05-03Merge "nanohub: fix chre syscalls for 1.2 and 1.1 on 1.0 nanohub" into pi-devBen Fennema
2018-05-02Merge "[IMU_Cal] Runtime sensor calibration code update." into pi-devDavid Jacobs
2018-05-02nanohub: fix chre syscalls for 1.2 and 1.1 on 1.0 nanohubBen Fennema
Bug: 78887346 Test: Run pi CHQTS on oc-mr1 Change-Id: I01de28f13c581c72458c9935449f4b80a25733cc Signed-off-by: Ben Fennema <fennema@google.com>
2018-05-02[IMU_Cal] Runtime sensor calibration code update.David Jacobs
This code updates all of the refactored changes developed and tested in Google3. This update includes setting calibration accuracy level. Tip of G3 CL: 195047378 Bug: 75333210 (refactor updates) Bug: 75335561 (calibration accuracy) Test: ./load_app.sh and verified calibrations on device. Change-Id: I48bd61b6610a7cc7ce9a88bfdde51552c509d763
2018-05-02[Bosch BMI160 Driver] Runtime sensor calibration updates.David Jacobs
Adds accel calibration debug printouts for logging. Updates gyro get/set bias function arguments. Uses parameter structures to initialize the runtime algorithms. Diversity checker is used by default. Build flag checks are removed. Bug: 75333210 Test: Built firmware and tested on a device. Change-Id: I70a84fa82e053cf7c4ee8418650e7dd5f8e13f37
2018-04-26[M/S][Barometer]Fix IIR register in BMP28x drivermasonwang
Bug: 77659366 Test: 1. install Barometer Graph.apk from app store. Test: 2. Turn on barometer, observe the output to see it stable Test: 3. Turn off barometer, either take device to a place with a significantly different pressure (e.g. move up/down multiple floors in a tall building, or use pressure chamber, etc) Test: 4. Turn on barometer, the good behavior is for the first readings to be accurate to the new pressure and the graph to therefore be relatively flat. Change-Id: I13533ee2186e9d244a431bc1f145658f7781b12a
2018-04-19contexthubhal: update to handle chre messaging interfaceBen Fennema
use new chre messaging interface start apps that were loaded via hal on reset cache apps loaded via the hal when receiving an app, if the app is already present on nanohub verify if the app is the same and just start the present app if it is. (compare new app to one on disk and compare stored crc to crc of app on nanohub) Handle upload error due to out of space by doing a commanded erase and then re-uploading the app Add debug commands to load/unload/enable/disable apps via lshal debug Bug: 69980445 Test: run CHQTS Change-Id: Ief60123353b503c44c5b19570c50492b380c2c04 Signed-off-by: Ben Fennema <fennema@google.com>
2018-04-17nanohub: new contexthub interface using chre messagingBen Fennema
range check messages do not auto erase flash when writing an nanoapp that doesn't fit enable crc calculation/checking for nanoapps do not auto start chre 1.1+ nanoapps Bug: 69980445 Test: check out new commands and make sure they work Change-Id: I98af1f3d5c848be19a1d3687d1d51a58145ff956 Signed-off-by: Ben Fennema <fennema@google.com>
2018-04-09Removes unused code from calibration directory.David Jacobs
Bug: 77578070 Test: Built imu_cal nanoapp using ./load_app.sh Change-Id: I58c690c4de27a83b37023600c051be357a8daa5d
2018-03-30[Bosch BMI160 Driver] Runtime sensor calibration updates.David Jacobs
Adds accel calibration debug printouts for logging. Updates gyro get/set bias function arguments. Uses parameter structures to initialize the runtime algorithms. Bug: 75333210 Test: Built firmware and tested on a device. Change-Id: I2d0e1e2247927430e34ae86ea1ca470d726d2d93
2018-03-29[IMU_Cal] Runtime sensor calibration code update.David Jacobs
This code transfers all of the refactored changes developed and tested in Google3. Tip of G3 CL: 191014272 Bug: 75333210 Test: ./load_app.sh and verified calibrations on device. Change-Id: Ieb414468296ce620ecf7fe275595c561c33779c1
2018-02-08nanohub: fix chre v1.2 gnss function name changeBen Fennema
Test: build nanoapp Change-Id: Iffcef43f00410652f8fc9affd536ef20fa2ccdec Signed-off-by: Ben Fennema <fennema@google.com>
2018-02-08Fix nullptr dereference.Steven Moreland
This is causing an error in vts_ibase_test. Bug: N/A Test: vts_ibase_test on marlin [ PASSED ] 6 tests. Change-Id: I5cfac8e3643ff5855c6d5ef69b64ba2786bc7d59
2018-01-25Make contexthub build with the VNDK.Steven Moreland
When the vndk is enabled (BOARD_VNDK_VERSION=current), vendor libraries must only link against vendor variants in the build system. This also means that they receive restricted sets of headers and that automatic global headers are restricted. A static library moved to being vendor is a build time only change for libhubutilscommon. Test: mma with BOARD_VNDK_VERSION=current Bug: 69526027 Change-Id: I99573506afb3f91b846302be78a2bdcdb838d12c
2018-01-09contexthubhal: add nanohub contexthub impl and serviceBen Fennema
For now, maintain legacy context_hub.default.so support. Bug: 70933028 Test: verify messages still successfully passed back to contexthub service Change-Id: I9a36b4f6d581243b9de3a5e6d742d17c1aa49f88 Signed-off-by: Ben Fennema <fennema@google.com>
2018-01-08nanohub: properly handling messaging for v1.2 chre nanoappsBen Fennema
Change version check to be >= 1.1 instead of == 1.1 Test: build Change-Id: If4506c8301419f6aaac66ed98d14143f1e12876a Signed-off-by: Ben Fennema <fennema@google.com>
2018-01-05Re-add libutils_headers as it is still a dependency.Martijn Coenen
Test: fixes build. Change-Id: I00af4d54c8e64bcf43547a58f2537aaecbf3d752
2018-01-03nanohub: add endpoint supportBen Fennema
Pass endpoint from nanohub to the hal. (hal currently has no way to pass the endpoint any further) Bug: 70933028 Test: verify messages still successfully passed back to contexthub service Change-Id: I8731de32c9d77a0d67d8ee8440e35a4c9853a97c Signed-off-by: Ben Fennema <fennema@google.com>
2017-12-21nanohub: i2c: detect and clock through stuck low sda am: 44b122a273 am: ↵Ben Fennema
aad7f8db68 am: d6104b39af Change-Id: I8f98984ece95247ade6bfa37e2ca67f5c791f15e
2017-12-21nanohub: i2c: detect and clock through stuck low sda am: 44b122a273Ben Fennema
am: aad7f8db68 Change-Id: If81bc9be8fb01dc47e193878e60d49e119beef95
2017-12-21nanohub: i2c: detect and clock through stuck low sdaBen Fennema
am: 44b122a273 Change-Id: Id30b55747c2881a2cdcb30e2cab83e3c251e9237
2017-12-20nanohub: i2c: detect and clock through stuck low sdaandroid-wear-8.0.0_r1android-p-preview-1android-o-mr1-iot-preview-8android-o-mr1-iot-preview-7android-n-iot-release-lg-thinq-wk7o-mr1-iot-preview-8o-mr1-iot-preview-7Ben Fennema
If the chip is reset in the middle of an i2c read, the slave will still be waiting for additional pulses of sdc. This prevents all chips on the stuck i2c bus from being detected until a power cycle. Detect that sda is stuck low and attempt to clock through the issue. Bug: 65966547 Test: run accel at a high rate over i2c and reset the stm32. Confirm all chips on i2c are detected after reset. Change-Id: I3a7ec24556a693b5506ba65f4eefa6e9f36e5818 Signed-off-by: Ben Fennema <fennema@google.com>
2017-12-19nanohub: fix build, add v1.2 stubsBen Fennema
Bug: 70716840 Test: build Change-Id: Id28865376b9f9d7cdbc796d2bd62ab4308e5c84d Signed-off-by: Ben Fennema <fennema@google.com>
2017-12-07nanohub: add back chre directory to firmware FLAGS am: 3564225503 am: 93715c4bf5Ben Fennema
am: d70ba6fe31 -s ours Change-Id: Icc6f732578a0e723a33b62c6d07c504226981b3f
2017-12-07nanohub: fix chre 1.0 compat message format am: 1653fbb460 am: f0311abe39Ben Fennema
am: 5011e5b7fb -s ours Change-Id: I37e007b6bf52fcf7d4aa21da8f8ff461f1623cc9
2017-12-07nanohub: add CHRE 1.1 support to fix CHQTS build errors am: 04b158e56d am: ↵Ben Fennema
ff7be507e3 am: 51c5e728d5 -s ours Change-Id: If3b907066a4d5334fd80979be7035871baa7be32
2017-12-07Updates to allow building in a desktop environment. am: dadb17161e am: ↵destradaa
3d00a28753 am: 94af5b1baf -s ours Change-Id: I05d6e2afc3114dbcecd5c5c49bdc25eecfc2f5c3
2017-12-07nanohub: add back chre directory to firmware FLAGS am: 3564225503Ben Fennema
am: 93715c4bf5 Change-Id: I5e91916d8f78b1afdbe79798664edd2ec85af6e4
2017-12-07nanohub: fix chre 1.0 compat message format am: 1653fbb460Ben Fennema
am: f0311abe39 Change-Id: I99c9be07765753240c02353f1586f9da4360c3b9
2017-12-07nanohub: add CHRE 1.1 support to fix CHQTS build errors am: 04b158e56dBen Fennema
am: ff7be507e3 Change-Id: Ia4089ca8cb15ea7b9cb70402547c2b6996067e77
2017-12-07Updates to allow building in a desktop environment. am: dadb17161edestradaa
am: 3d00a28753 Change-Id: I083cb0630df890122f7275a36c9f6dbdfc69e02c
2017-12-07nanohub: add back chre directory to firmware FLAGSBen Fennema
am: 3564225503 Change-Id: I2fdc86259ed50e64a5a25b3ec4f2528a01d4fa16
2017-12-07nanohub: fix chre 1.0 compat message formatBen Fennema
am: 1653fbb460 Change-Id: I4350f4f388fb630596b878251262cf478b760d78
2017-12-07nanohub: add CHRE 1.1 support to fix CHQTS build errorsBen Fennema
am: 04b158e56d Change-Id: I038e7cf500bfb247ad258c4d91b720d686634f05
2017-12-07Updates to allow building in a desktop environment.destradaa
am: dadb17161e Change-Id: I409a5570cd7e80dbbf99648479913a604b599dac
2017-12-07nanohub: add back chre directory to firmware FLAGSBen Fennema
Test: successful make from vendor directory Merged-In: I0a42669615313f268d117f2d53ee616538892b41 Change-Id: I0a42669615313f268d117f2d53ee616538892b41 Signed-off-by: Ben Fennema <fennema@google.com>
2017-12-07nanohub: fix chre 1.0 compat message formatBen Fennema
For 1.0 nanoapps, EVT_APP_FROM_HOST_CHRE messages come in NanohubMsgChreHdrV10 struct (not NanohubMsgChreHdr) Bug: 63626848 Test: build activity_chre and make sure it is not generating fragment_size errors Merged-In: I5551e20acb253bc679d287688967ac199c39154c Change-Id: I5551e20acb253bc679d287688967ac199c39154c Signed-off-by: Ben Fennema <fennema@google.com>
2017-12-07nanohub: add CHRE 1.1 support to fix CHQTS build errorsBen Fennema
Pull in chre headers from system/chre Bug: 63626848 Test: Build CHQTS nanohub test apps and verify they pass Merged-In: Ibc6861b21ab3f1d0cde6f774b5c38c20c01a720d Change-Id: Ibc6861b21ab3f1d0cde6f774b5c38c20c01a720d Signed-off-by: Ben Fennema <fennema@google.com>
2017-12-07Updates to allow building in a desktop environment.destradaa
The changes allow ContextHub codebase to be built outside of the Android build environment. Useful for testing. Test: manual Merged-In: I51eb236823b4483a439ab26d58970ec9568161b6 Change-Id: I51eb236823b4483a439ab26d58970ec9568161b6
2017-12-05Merge "nanohub: drivers/st_acc44: Add support for STMicroelectronics ACC44 ↵Armando Visconti
sensor driver" am: 2677c52945 am: 04b934efb6 am: 6667ab3b4b Change-Id: Ieb6a58cb23e9439105d14abe8ae4a52ca80dbbad
2017-12-05Merge "nanohub: drivers/st_acc44: Add support for STMicroelectronics ACC44 ↵Armando Visconti
sensor driver" am: 2677c52945 am: 04b934efb6 Change-Id: I436430b1e60c6162ab357254b3dbea24648bf60c
2017-12-05Merge "nanohub: drivers/st_acc44: Add support for STMicroelectronics ACC44 ↵Armando Visconti
sensor driver" am: 2677c52945 Change-Id: Ice386681da1f2ddaecb352b0eec736bf540ee102
2017-12-05Merge "nanohub: drivers/st_acc44: Add support for STMicroelectronics ACC44 ↵Treehugger Robot
sensor driver"
2017-11-29nanohub: isl29034: fix build error when DEBUG not defined am: 3fac23e689 am: ↵Ben Fennema
9025e99c6b am: 333fbf8655 Change-Id: Id59264fdb0c927621ef53fe08520e59b1dd6076a