Skip to content

Commit d2c8d52

Browse files
committed
grove: lcd: move grove lcd driver to drivers/display
Move to display drivers where it belongs. Signed-off-by: Anas Nashif <[email protected]>
1 parent 7e3a6e8 commit d2c8d52

File tree

10 files changed

+23
-28
lines changed

10 files changed

+23
-28
lines changed

drivers/display/CMakeLists.txt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
2+
zephyr_sources_ifdef(CONFIG_GROVE_LCD_RGB grove_lcd_rgb.c)
13
zephyr_sources_ifdef(CONFIG_MICROBIT_DISPLAY
24
mb_display.c
35
mb_font.c

drivers/display/Kconfig

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,8 @@ module = DISPLAY
1717
module-str = display
1818
source "subsys/logging/Kconfig.template.log_config"
1919

20+
source "drivers/display/Kconfig.grove"
21+
2022
source "drivers/display/Kconfig.microbit"
2123

2224
source "drivers/display/Kconfig.ili9340"

drivers/display/Kconfig.grove

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
2+
config GROVE_LCD_RGB
3+
bool "Enable the Seeed Grove LCD RGB Backlight"
4+
help
5+
Setting this value will enable driver support for the Groove-LCD RGB
6+
Backlight.
7+
8+
config GROVE_LCD_RGB_I2C_MASTER_DEV_NAME
9+
string "I2C Master where Grove LCD is connected"
10+
depends on GROVE_LCD_RGB
11+
default "I2C_0"
12+
help
13+
Specify the device name of the I2C master device to which the
14+
Grove LCD is connected.

drivers/grove/lcd_rgb.c renamed to drivers/display/grove_lcd_rgb.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
#include <display/grove_lcd.h>
1414
#include <misc/util.h>
1515

16-
#define LOG_LEVEL CONFIG_GROVE_LOG_LEVEL
16+
#define LOG_LEVEL CONFIG_DISPLAY_LOG_LEVEL
1717
#include <logging/log.h>
1818
LOG_MODULE_REGISTER(grove_lcd);
1919

drivers/grove/CMakeLists.txt

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,2 @@
1-
zephyr_sources_ifdef(CONFIG_GROVE_LCD_RGB lcd_rgb.c)
21
zephyr_sources_ifdef(CONFIG_GROVE_LIGHT_SENSOR light_sensor.c)
32
zephyr_sources_ifdef(CONFIG_GROVE_TEMPERATURE_SENSOR temperature_sensor.c)

drivers/grove/Kconfig

Lines changed: 0 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -7,30 +7,6 @@
77
#
88

99

10-
menuconfig GROVE
11-
bool "Grove Device Drivers"
12-
help
13-
Check this box to enable the Seeed Grove device drivers
14-
15-
16-
module = GROVE
17-
module-str = grove
18-
source "subsys/logging/Kconfig.template.log_config"
19-
20-
config GROVE_LCD_RGB
21-
bool "Enable the Seeed Grove LCD RGB Backlight"
22-
depends on GROVE
23-
help
24-
Setting this value will enable driver support for the Groove-LCD RGB
25-
Backlight.
26-
27-
config GROVE_LCD_RGB_I2C_MASTER_DEV_NAME
28-
string "I2C Master where Grove LCD is connected"
29-
depends on GROVE_LCD_RGB
30-
default "I2C_0"
31-
help
32-
Specify the device name of the I2C master device to which the
33-
Grove LCD is connected.
3410

3511
config GROVE_LIGHT_SENSOR
3612
bool "Enable the Seeed Grove Light Sensor"

samples/boards/arduino_101/environmental_sensing/sensor/prj.conf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ CONFIG_GPIO=y
1010
CONFIG_SENSOR=y
1111

1212
# remove Grove configs you don't want to use the LCD
13-
CONFIG_GROVE=y
13+
CONFIG_DISPLAY=y
1414
CONFIG_GROVE_LCD_RGB=y
1515

1616
# change these configs if you want to use different sensors

samples/display/grove_display/prj.conf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,5 +3,5 @@ CONFIG_PRINTK=y
33

44
CONFIG_I2C=y
55

6-
CONFIG_GROVE=y
6+
CONFIG_DISPLAY=y
77
CONFIG_GROVE_LCD_RGB=y

samples/sensor/grove_temperature/prj.conf

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ CONFIG_SENSOR=y
33
CONFIG_I2C=y
44
CONFIG_ADC=y
55
CONFIG_NEWLIB_LIBC=y
6+
CONFIG_DISPLAY=y
67
CONFIG_GROVE=y
78
CONFIG_GROVE_TEMPERATURE_SENSOR_ADC_CHANNEL=10
89
CONFIG_GROVE_TEMPERATURE_SENSOR=y

samples/sensor/th02/prj.conf

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,3 +6,4 @@ CONFIG_LOG=n
66
CONFIG_SENSOR_LOG_LEVEL_DBG=y
77
CONFIG_GROVE=y
88
CONFIG_GROVE_LCD_RGB=y
9+
CONFIG_DISPLAY=y

0 commit comments

Comments
 (0)