From 86668d2be24abb4af71cf8af74438cc66472b25a Mon Sep 17 00:00:00 2001
From: Daniel Friesel <derf@finalrewind.org>
Date: Wed, 24 Feb 2021 20:09:20 +0100
Subject: [PATCH] i2cdetect: ccs811: more concise output, use low-power
 measuring mode

---
 src/app/i2cdetect/main.cc | 8 +++-----
 1 file changed, 3 insertions(+), 5 deletions(-)

diff --git a/src/app/i2cdetect/main.cc b/src/app/i2cdetect/main.cc
index 92c812c..27e35bf 100644
--- a/src/app/i2cdetect/main.cc
+++ b/src/app/i2cdetect/main.cc
@@ -126,12 +126,10 @@ void loop(void)
 #endif
 #ifdef DRIVER_CCS811
 	ccs811.read();
-	kout << "CCS811 eCOâ‚‚ : " << ccs811.eco2 << " ppm" << endl;
-	kout << "CCS811 tVOC : " << ccs811.tvoc << " ppb" << endl;
 	kout << bin;
-	kout << "CCS811 status: " << ccs811.status << endl;
-	kout << "CCS811 error: " << ccs811.error_id << endl;
+	kout << "CCS811 status / error: " << ccs811.status << " / " << ccs811.error_id << endl;
 	kout << dec;
+	kout << "CCS811 tVOC / eCOâ‚‚ : " << ccs811.tvoc << " ppb / " << ccs811.eco2 << " ppm" << endl;
 #endif
 #ifdef DRIVER_HDC1080
 	/*
@@ -201,7 +199,7 @@ int main(void)
 	arch.delay_ms(65);
 	kout << "CCS811 status: " << ccs811.getStatus() << endl;
 	kout << dec;
-	ccs811.setMode(1);
+	ccs811.setMode(2);
 	//arch.delay_ms(50);
 #endif
 #ifdef DRIVER_HDC1080
-- 
GitLab