Skip to content

Commit 7147f08

Browse files
committed
samples: sensortile_box: use new USB device stack
Use new USB device stack. Signed-off-by: Johann Fischer <johann.fischer@nordicsemi.no>
1 parent db953c9 commit 7147f08

File tree

2 files changed

+5
-8
lines changed

2 files changed

+5
-8
lines changed

samples/boards/st/sensortile_box/prj.conf

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -17,12 +17,10 @@ CONFIG_IIS3DHHC_TRIGGER_OWN_THREAD=y
1717
CONFIG_LIS2MDL_TRIGGER_NONE=y
1818

1919
# config USB and USB console
20-
CONFIG_USB_DEVICE_VID=0x0483
21-
CONFIG_USB_DEVICE_PID=0x1234
22-
CONFIG_USB_DEVICE_STACK=y
23-
CONFIG_USB_DEVICE_PRODUCT="Zephyr CDC SensorTile.box"
24-
CONFIG_USB_CDC_ACM_LOG_LEVEL_OFF=y
25-
CONFIG_USB_DEVICE_INITIALIZE_AT_BOOT=n
20+
CONFIG_USB_DEVICE_STACK_NEXT=y
21+
CONFIG_CDC_ACM_SERIAL_INITIALIZE_AT_BOOT=y
22+
CONFIG_CDC_ACM_SERIAL_PRODUCT_STRING="Zephyr CDC SensorTile.box"
23+
CONFIG_USBD_CDC_ACM_LOG_LEVEL_OFF=y
2624

2725
CONFIG_UART_INTERRUPT_DRIVEN=y
2826
CONFIG_UART_LINE_CTRL=y

samples/boards/st/sensortile_box/src/main.c

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -256,8 +256,7 @@ int main(void)
256256
int cnt = 1;
257257
uint32_t dtr = 0;
258258

259-
/* Application must enable USB by itself */
260-
if (!device_is_ready(dev) || usb_enable(NULL)) {
259+
if (!device_is_ready(dev)) {
261260
return 0;
262261
}
263262

0 commit comments

Comments
 (0)