forked from xuos/xiuos
				
			comment debug print of i2c transfer errors.
This commit is contained in:
		
							parent
							
								
									6c6ef02455
								
							
						
					
					
						commit
						587ab693c1
					
				|  | @ -1,4 +1,4 @@ | ||||||
| SRC_FILES := lv_init.c lv_demo.c lv_demo_calendar.c  | SRC_FILES := lv_init.c lv_demo.c lv_demo_calendar.c  | ||||||
| SRC_FILES += lv_sensor_info.c lv_sensor_update_info.c | SRC_FILES += lv_sensor_info.c lv_sensor_update_info.c lv_sensor_info_update_demo.c | ||||||
| 
 | 
 | ||||||
| include $(KERNEL_ROOT)/compiler.mk | include $(KERNEL_ROOT)/compiler.mk | ||||||
|  |  | ||||||
|  | @ -67,6 +67,7 @@ void lv_sensor_info(void) { | ||||||
|     } |     } | ||||||
|     lv_obj_set_style_text_font(lv_ssr_tb, &lvgl_font_chinese, 0); |     lv_obj_set_style_text_font(lv_ssr_tb, &lvgl_font_chinese, 0); | ||||||
| 
 | 
 | ||||||
|  |     // set width of cells in table
 | ||||||
|     for (uint32_t i = 0; i < 2 * NR_VAL_PERLINE; ++i) { |     for (uint32_t i = 0; i < 2 * NR_VAL_PERLINE; ++i) { | ||||||
|         if (i % 2 == 0) { |         if (i % 2 == 0) { | ||||||
|             lv_table_set_col_width(lv_ssr_tb, i, 75); |             lv_table_set_col_width(lv_ssr_tb, i, 75); | ||||||
|  |  | ||||||
|  | @ -8,6 +8,7 @@ | ||||||
| extern lv_obj_t* lv_ssr_tb; | extern lv_obj_t* lv_ssr_tb; | ||||||
| pthread_mutex_t ssr_val_lock; | pthread_mutex_t ssr_val_lock; | ||||||
| 
 | 
 | ||||||
|  | // number of sensor values showed in one line
 | ||||||
| #define NR_VAL_PERLINE 3 | #define NR_VAL_PERLINE 3 | ||||||
| 
 | 
 | ||||||
| static char* sensor_names[nr_sensors] = { | static char* sensor_names[nr_sensors] = { | ||||||
|  | @ -20,7 +21,8 @@ static char* sensor_names[nr_sensors] = { | ||||||
| static char* seneor_denominations[nr_sensors] = { | static char* seneor_denominations[nr_sensors] = { | ||||||
|     "ppb", "ppm", "ppb", "ppb", "ppm", |     "ppb", "ppm", "ppb", "ppb", "ppm", | ||||||
|     "ppm", "ppm", "ppm", "%VOL", "%VOL", "ug/m³", "ug/m³", |     "ppm", "ppm", "ppm", "%VOL", "%VOL", "ug/m³", "ug/m³", | ||||||
|     "°C", "%RH", "m/s", "m/s", "mbar", "dB(A)" |     "°C", "%RH", | ||||||
|  |     "m/s", "m/s", "mbar", "dB(A)" | ||||||
| }; | }; | ||||||
| 
 | 
 | ||||||
| static double lv_sensor_vals[nr_sensors]; | static double lv_sensor_vals[nr_sensors]; | ||||||
|  |  | ||||||
|  | @ -26,11 +26,6 @@ int main(void) | ||||||
| #ifdef APPLICATION_OTA | #ifdef APPLICATION_OTA | ||||||
| 	ApplicationOtaTaskInit(); | 	ApplicationOtaTaskInit(); | ||||||
| #endif | #endif | ||||||
|     // while (1) {
 |  | ||||||
|     //     ShowTask();
 |  | ||||||
|     //     ShowMemory();
 |  | ||||||
|     //     PrivTaskDelay(1500);
 |  | ||||||
|     // }
 |  | ||||||
|     return 0; |     return 0; | ||||||
| } | } | ||||||
| // int cppmain(void);
 | // int cppmain(void);
 | ||||||
|  |  | ||||||
|  | @ -230,7 +230,7 @@ static void touchpad_init(void) | ||||||
| { | { | ||||||
|     touch_fd = PrivOpen(PRIV_TOUCH_DEV,O_RDWR); |     touch_fd = PrivOpen(PRIV_TOUCH_DEV,O_RDWR); | ||||||
|     if(touch_fd >= 0) { |     if(touch_fd >= 0) { | ||||||
|         printf("touch fd = %d\n",touch_fd); |         // printf("touch fd = %d\n",touch_fd);
 | ||||||
|     } else { |     } else { | ||||||
|         printf("open %s touch fd = %d failed.\n",PRIV_TOUCH_DEV,touch_fd); |         printf("open %s touch fd = %d failed.\n",PRIV_TOUCH_DEV,touch_fd); | ||||||
|     } |     } | ||||||
|  |  | ||||||
		Loading…
	
		Reference in New Issue