online-doc: fix misusing sensor API
authorHongkuk, Son <hongkuk.son@samsung.com>
Fri, 18 Dec 2015 08:07:25 +0000 (17:07 +0900)
committerHongkuk, Son <hongkuk.son@samsung.com>
Fri, 18 Dec 2015 08:34:21 +0000 (17:34 +0900)
Signed-off-by: Hongkuk, Son <hongkuk.son@samsung.com>
Change-Id: Id10eb3276eae9d35402845b43aa3f87abd0358a1

org.tizen.tutorials/html/native/system/sensor_tutorial_n.htm

index f7b6f0b..7ca5451 100644 (file)
@@ -86,8 +86,9 @@ error = sensor_get_default_sensor(type, &amp;sensor);
 int error;
 sensor_type_e type = SENSOR_ALL;
 sensor_h *list;
+int sensor_count;
 
-error = sensor_get_default_sensor(type, &amp;list);
+error = sensor_get_sensor_list(type, &amp;list, &amp;sensor_count);
 
 // API caller must explicitly free this list after use
 // free(list);
@@ -163,7 +164,7 @@ error = sensor_listener_start(listener);
 
 </li>
 <li>Read sensor data (optional).
-<p>In order to read sensor data, call the <span style="font-family: Courier New,Courier,monospace">sensor_listener_start()</span> function:</p>
+<p>In order to read sensor data, the sensor listener needs to be started in advance using sensor_listener_read_data() function:</p>
 <pre class="prettyprint">
 sensor_event_s event;
 error = sensor_listener_read_data(listener, &amp;event);