summaryrefslogtreecommitdiff
path: root/board/meep
Commit message (Collapse)AuthorAgeFilesLines
* meep: fix sensor data and accel orientationDevin Lu2018-10-311-5/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch fix the lid and base accel orientation for EVT and change range value to 2g. BUG=none BRANCH=none TEST=When device is laying on a table, lid angle at 180, both sensors report gravity along Z axis: ectool motionsense Motion sensing active Sensor 0: 507 606 16748 Sensor 1: 17 -334 16442 Sensor 2: 0 0 0 Sensor 3: 0 0 0 When on the base bottom edge, report gravity along Y axis: ectool motionsense Motion sensing active Sensor 0: 403 16491 655 Sensor 1: 19 16163 1540 Sensor 2: 0 0 0 Sensor 3: 0 0 0 When on its left side, report gravity along X axis: ectool motionsense Motion sensing active Sensor 0: 16172 -374 1738 Sensor 1: 16315 -184 1280 Sensor 2: 0 0 0 Sensor 3: 0 0 0 and check the screen rotation was normally. Change-Id: Ic594c12fa4b03b594151eed4ffb0f0e5b42cad3d Signed-off-by: Devin Lu <Devin.Lu@quantatw.com> Reviewed-on: https://chromium-review.googlesource.com/1307282 Reviewed-by: Justin TerAvest <teravest@chromium.org>
* meep: enable keyboard factory scanningDevin Lu2018-10-312-0/+25
| | | | | | | | | | | | | This patch add for factory keyboard connector test. BUG=none BRANCH=none TEST=Short keyboard pins and make sure "ectool kbfactorytest" works. Change-Id: Ic343b99343f5f6d7a8967bf1c4bec642638d8568 Signed-off-by: Devin Lu <Devin.Lu@quantatw.com> Reviewed-on: https://chromium-review.googlesource.com/1309572 Reviewed-by: Justin TerAvest <teravest@chromium.org>
* board/meep: Add magnetometer configKarthikeyan Ramasubramanian2018-10-192-1/+31
| | | | | | | | | | | | | | | Enable the required modules to support magnetometer module and add magnetometer configuration. BRANCH=none BUG=b:115587004 TEST=Collect magnetometer readings through ectool motionsense Change-Id: Ibe2b624716b3a9a1ffba93e0b1b7edf3b718b6f9 Signed-off-by: Karthikeyan Ramasubramanian <kramasub@chromium.org> Reviewed-on: https://chromium-review.googlesource.com/1257505 Reviewed-by: Furquan Shaikh <furquan@chromium.org> Reviewed-by: Jett Rink <jettrink@chromium.org>
* Octopus: add reset logic for C0 TCPCDiana Z2018-10-091-0/+3
| | | | | | | | | | | | | | | | | This change adds a call to the C0 TCPC reset for standalone TCPC boards which have that pin hooked up in hardware, and adds the GPIO as unimplemented for boards which do not have this yet. BRANCH=None BUG=b:112756630 TEST=Added a log print and rebooted EC on bobba to verify TCPC C0 reset, then verified that charging on C0 worked. Also imaged yorp proto 2 and rebooted, verifying C0 reset was not attempted. Change-Id: I615861f0d9ce9b5a89692e3982ed2e19c7e0b237 Signed-off-by: Diana Z <dzigterman@chromium.org> Reviewed-on: https://chromium-review.googlesource.com/1257647 Reviewed-by: Jett Rink <jettrink@chromium.org>
* octopus: remove CONFIG_SYSTEM_UNLOCKED optionJett Rink2018-10-041-3/+0
| | | | | | | | | | | | | | | | | | | | For all NPCX boards, remove the CONFIG_SYSTEM_UNLOCKED option. The main affect of this will be to prevent PD communication in RO. We are starting to get into factory test that want to verify this behavior. As a developer, one must remember to jump to RW before PD will negotiate. BRANCH=none BUG=b:117109816 TEST=flash on fleex and RO did not negotiate (when WP was asserted) but RW did. Change-Id: I2df575baad95a334a4a57a9f81600fc039157fd5 Signed-off-by: Jett Rink <jettrink@chromium.org> Reviewed-on: https://chromium-review.googlesource.com/1258568 Commit-Ready: ChromeOS CL Exonerator Bot <chromiumos-cl-exonerator@appspot.gserviceaccount.com> Reviewed-by: Aaron Durbin <adurbin@chromium.org> Reviewed-by: Furquan Shaikh <furquan@chromium.org> Reviewed-by: Scott Collyer <scollyer@chromium.org>
* bc12: rename bq24392 driver to max14637Scott Collyer2018-10-021-1/+0
| | | | | | | | | | | | | | | | | | | | The MAX14637 BC 1.2 USB charger detection chip is functionally similar to the bq24392 and can use the same driver. Rather than have 2 copies of the same driver, or a generic named driver than can be used for both chips, rename the existing bq24392 driver to max14637 as that's the BC 1.2 chip that our current designs are using. BUG=b:113267982 BRANCH=none TEST=make -j buildall Change-Id: I03cfb4918513d756c2a41341001a8162652a29b6 Signed-off-by: Scott Collyer <scollyer@google.com> Reviewed-on: https://chromium-review.googlesource.com/1250031 Commit-Ready: Scott Collyer <scollyer@chromium.org> Tested-by: Scott Collyer <scollyer@chromium.org> Reviewed-by: Edward Hill <ecgh@chromium.org> Reviewed-by: Jett Rink <jettrink@chromium.org>
* meep: Add clamshell Suspend LED BehaviorZick Wei2018-09-203-3/+22
| | | | | | | | | | | | | | | | | | | | Meep and Mimrock use same mother board, Mimrock is clamshell sku only have Charge LED. To meet LED spec: System without Power LED, Suspend/S0ix without charge blink White on Charge LED(1 sec on, 1 sec off). BUG=none BRANCH=none TEST=manual Set cbi sku id to clamshell sku, Check Charge LED will blink(1 sec on, 1 sec off), when system is Suspend/S0ix without charge. Change-Id: Ib443d6176d929aad4b65c1cb0d4b40c102e6f67e Signed-off-by: Zick Wei <zick.wei@quanta.corp-partner.google.com> Reviewed-on: https://chromium-review.googlesource.com/1226830 Reviewed-by: Jett Rink <jettrink@chromium.org>
* octopus: enable PSL for all NPCX variantsJett Rink2018-09-171-3/+0
| | | | | | | | | | | | | | | | | All NPCX variants support PSL mode in hardware now; enable this at the baseboard level. This is adding support for Bobba; other boards are unaffected BRANCH=none BUG=b:115677776 TEST=bobba goes into PSL Change-Id: I38974371b101c42841e4f11ba72b466415c754d9 Signed-off-by: Jett Rink <jettrink@chromium.org> Reviewed-on: https://chromium-review.googlesource.com/1227050 Commit-Ready: ChromeOS CL Exonerator Bot <chromiumos-cl-exonerator@appspot.gserviceaccount.com> Reviewed-by: Justin TerAvest <teravest@chromium.org>
* octopus: correct base sensor lifetimeJett Rink2018-09-171-1/+1
| | | | | | | | | | | | | | | | | All base sensor are off during S5 and turn on in S4. Update the active mask to reflect this which also ensure that the sensor is getting initialized at the correct time. BRANCH=none BUG=b:115278651 TEST=fleex base sensor now works. Change-Id: Id4b30fbab02dadf55ed0809fefef3938474fe818 Signed-off-by: Jett Rink <jettrink@chromium.org> Reviewed-on: https://chromium-review.googlesource.com/1222091 Commit-Ready: Matt Wang <matt_wang@compal.corp-partner.google.com> Tested-by: Matt Wang <matt_wang@compal.corp-partner.google.com> Reviewed-by: Justin TerAvest <teravest@chromium.org>
* type: Rename matrix_3x3_t to mat33_fp_tYilun Lin2018-09-131-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Naming of many vector types and matrix types are not clear enough. For example, we have: vector_3_t, which is a vector of three int. vec3_t, which is a vector of three float. size4_t, which is a vector of four size_t. mat33_t, which is a 3x3 matrix of float. matrix_3x3_t, which is a 3x3 matrix of fixed point. Besides, we have types like int8_t, uint16_t types. To clearly distinguished types, the CL propose to, For vector types, naming should be `$type + 'v' + $num + '_t'`: vector_3_t becomes intv3_t vec3_t becomes floatv3_t vector 4 of uint16_t becomes uint16v4_t (which doesn't exist yet) For matrix types, naming should be `mat$N$N_` + $type + '_t', where $N is the matrix size: matrix_3x3_t becomes mat33_fp_t # fp: fixed point mat33_t becomes mat33_float_t TEST=make buildall -j BUG=b:114662791 Change-Id: I51d88d44252184e4b7b3564236833b0b892edc39 Signed-off-by: Yilun Lin <yllin@google.com> Reviewed-on: https://chromium-review.googlesource.com/1215449 Commit-Ready: Yilun Lin <yllin@chromium.org> Tested-by: Yilun Lin <yllin@chromium.org> Reviewed-by: Nicolas Boichat <drinkcat@chromium.org>
* meep: Disable accel, gyro sensors and tablet mode switch for clamshellsstabilize-jetstream-11056.BDevin Lu2018-09-112-3/+38
| | | | | | | | | | | | | | | | | | | | meep and mimrock both share with the same board, but mimrock is unstuff accel, gyro sensors and using hall sensor instead of GMR, so we don't need to initial those sensors and disable tablet mode. BUG=b:111823716,b:113962628 BRANCH=none TEST=make buildall -j. make sure no initial event occurs with mimrock. make sure tablet mode was disabled with mimrock. Change-Id: I8141ad8160807288d7a886488b98e93ed9a257b9 Signed-off-by: Devin Lu <Devin.Lu@quantatw.com> Reviewed-on: https://chromium-review.googlesource.com/1193103 Commit-Ready: Zick Wei <zick.wei@quanta.corp-partner.google.com> Tested-by: Zick Wei <zick.wei@quanta.corp-partner.google.com> Reviewed-by: Aaron Durbin <adurbin@chromium.org> Reviewed-by: Jett Rink <jettrink@chromium.org>
* octopus: use higher priority TCPC interrupt tasksJett Rink2018-09-072-13/+3
| | | | | | | | | | | | | | See go/usb-pd-slow-response-time for more information BRANCH=none BUG=b:112088135 TEST=CL stack on fleex and bobba consistently meet PD timing spec Change-Id: I9eabf8de8d866f5a0af7d1daba5ab585b418d26c Signed-off-by: Jett Rink <jettrink@chromium.org> Reviewed-on: https://chromium-review.googlesource.com/1185729 Reviewed-by: Jonathan Brandmeyer <jbrandmeyer@chromium.org> Reviewed-by: Diana Z <dzigterman@chromium.org>
* octopus: consolidate identical definesJett Rink2018-09-041-4/+0
| | | | | | | | | | | | | | All of the octopus board define the table mode option the same, so move them into baseboard. BRANCH=none BUG=none TEST=fleex still works Change-Id: Ibed874a609a2e5947d7aee39f915dc3046a0cc19 Signed-off-by: Jett Rink <jettrink@chromium.org> Reviewed-on: https://chromium-review.googlesource.com/1204700 Reviewed-by: Furquan Shaikh <furquan@chromium.org>
* octopus: enabled DPTF device orientationJett Rink2018-09-041-3/+0
| | | | | | | | | | | | | | | | | | | | | | | All octopus boards should have this enabled by now. We are consolidating this option in octopus baseboard. This turns on DPTF on: - Fleex This turns on DPTP_DEVICE_ORIENTATION on: - Bip - Bobba - Fleex BRANCH=none BUG=b:113348027 TEST=fleex has tablet mode icon Change-Id: I0d25895785c6a8fcce25b3b6bf587b6030119045 Signed-off-by: Jett Rink <jettrink@chromium.org> Reviewed-on: https://chromium-review.googlesource.com/1204699 Reviewed-by: Furquan Shaikh <furquan@chromium.org> Reviewed-by: Justin TerAvest <teravest@chromium.org>
* meep: Add Power LED behaviorZick Wei2018-09-023-10/+44
| | | | | | | | | | | | | | | | | | | | | | Add Power LED behavior to meet spec: System is ON(S0):LED solid ON White. System is Suspend/S0ix: LED blink White(1 sec on, 1 sec off). System is OFF: LED OFF. BUG=none BRANCH=none TEST=manual Check Power LED solid on White when system is ON(S0). Check Power LED blink White(1 sec on, 1 sec off) when system is Suspend/S0ix. Check Power LED off when system is OFF. Change-Id: I0e53a51446735dee0296e9f2c5eb3ceb84313720 Signed-off-by: Zick Wei <zick.wei@quanta.corp-partner.google.com> Reviewed-on: https://chromium-review.googlesource.com/1196642 Commit-Ready: Devin Lu <Devin.Lu@quantatw.com> Tested-by: Devin Lu <Devin.Lu@quantatw.com> Reviewed-by: Diana Z <dzigterman@chromium.org>
* meep: add VBUS voltage adc sensingDevin Lu2018-08-313-0/+29
| | | | | | | | | | | | | | This patch add to detect VBUS voltage, we are using 10x voltage divider. BUG=b:113193009 BRANCH=none TEST=make sure "ectool usbpdpower" can detect VBUS voltage. Change-Id: Ie96465ce1a28dde3381a2105afff14b1d41c89dd Signed-off-by: Devin Lu <Devin.Lu@quantatw.com> Reviewed-on: https://chromium-review.googlesource.com/1184587 Reviewed-by: Jett Rink <jettrink@chromium.org>
* meep: Add charge LED behaviorZick Wei2018-08-292-6/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add charge LED behavior to meet spec: AC attached: solid on White. Charging: solid on Amber. Discharging(S0/S3/S5): Both(White/Amber) Off. Battery Error: Blinking White (0.5 sec on, 0.5 sec off) Fuel <10%: Blinking White (1 sec on, 1 sec off) Force idle for factory: Blinking Amber (1 sec on, 1 sec off) BUG=b:112825269 BRANCH=None TEST=manual Check charge Led off when battery is discharging. Check charge Amber Led on when battery is charging. Check charge White Led on when battery is full and AC is attached. Check charge White led blink(0.5 sec on, 0.5 sec off) when battery error. Check charge White led blink(1 sec on, 1 sec off) when battery fuel less than 10%. Check charge Amber led blink(1 sec on, 1 sec off) when factory test. Signed-off-by: Zick Wei <zick.wei@quanta.corp-partner.google.com> Change-Id: I2cc2f9d710a6b94fa48f6d2fb78ac7996a7615f5 Reviewed-on: https://chromium-review.googlesource.com/1184941 Commit-Ready: Devin Lu <Devin.Lu@quantatw.com> Reviewed-by: Diana Z <dzigterman@chromium.org>
* meep: Add batteries configurationDevin Lu2018-08-172-3/+180
| | | | | | | | | | | | | | meep plan to use batteries the same as careena. BUG=b:111838980 BRANCH=none TEST=make buildall -j Change-Id: I29955dfaecefd16a48b6b14a48c3f06de97e11c0 Signed-off-by: Devin Lu <Devin.Lu@quantatw.com> Reviewed-on: https://chromium-review.googlesource.com/1177096 Commit-Ready: ChromeOS CL Exonerator Bot <chromiumos-cl-exonerator@appspot.gserviceaccount.com> Reviewed-by: Jett Rink <jettrink@chromium.org>
* ppc: nx20p3483: Rename driver to nx20p348x to support NX20P3481Scott Collyer2018-08-161-3/+3
| | | | | | | | | | | | | | | | | | | | | | This CL doesn't change any functionality, but renames the driver from 3483 to 348x. The motivation for this is that we need to support the NX20P3481 PPC as well. Those chips use the same registers, but the 3481 adds FRS support and sink/source control is done via I2C writes instead of gpio controls. Because the chips are slighlty different the config option CONFIG_USBC_PPC_NX20P3483 needs to remain. BUG=b:111281797 BRANCH=none TEST=make -j buildall Change-Id: Ie1085140eb2ef23c0b6e1a79a6f2d7f823326c6d Signed-off-by: Scott Collyer <scollyer@google.com> Reviewed-on: https://chromium-review.googlesource.com/1176382 Commit-Ready: Scott Collyer <scollyer@chromium.org> Tested-by: Scott Collyer <scollyer@chromium.org> Reviewed-by: Jett Rink <jettrink@chromium.org>
* octopus: increase USB charger stack sizesDiana Z2018-08-081-2/+2
| | | | | | | | | | | | | | | | | | The bip board has had issues with running out of task space in the USB_CHG_P[0,1] tasks when it runs into I2C errors and needs to run resets. Performing a full stack analysis should happen when the firmware branches for octopus, but for now this change increases the stack sizes for all of the USB_CHG_P[0,1] tasks. BRANCH=None BUG=b:111840286 TEST=builds, bip no longer hit stack overflows with the larger space during i2c resets Change-Id: Ib10e052bb89202cbedfe23345c8335f1e0a8e16b Signed-off-by: Diana Z <dzigterman@chromium.org> Reviewed-on: https://chromium-review.googlesource.com/1167653 Reviewed-by: Jett Rink <jettrink@chromium.org>
* meep: confirm thermistor partsDiana Z2018-08-061-1/+0
| | | | | | | | | | | | | | Confirmed that meep is using thermistors with the same b-constants as yorp, so removing the TODO to overwrite the yorp values BRANCH=None BUG=b:111920102 TEST=builds Change-Id: Iccf7ba59b0c137b33d7544807d82d6e814a2e259 Signed-off-by: Diana Z <dzigterman@chromium.org> Reviewed-on: https://chromium-review.googlesource.com/1160867 Reviewed-by: Jett Rink <jettrink@chromium.org>
* meep: create initial EC imageDiana Z2018-07-277-0/+693
This image is based on yorp proto 2 from ToT and the most recent meep schematics BRANCH=none BUG=b:111543000 TEST=builds Change-Id: I42df536b26266da377efbda0db98af1ef269380b Signed-off-by: Diana Z <dzigterman@chromium.org> Reviewed-on: https://chromium-review.googlesource.com/1151545 Reviewed-by: Jett Rink <jettrink@chromium.org> Reviewed-by: Justin TerAvest <teravest@chromium.org>