Merge branch 'main' into CrossR/Sofle

This commit is contained in:
CrossR
2020-08-16 12:25:47 +01:00
16 changed files with 117 additions and 57 deletions

View File

@@ -106,6 +106,10 @@ if ZMK_SPLIT_BLE_ROLE_CENTRAL
config BT_MAX_CONN
default 5
config BT_MAX_PAIRED
# Bump this everywhere once we support switching active connections!
default 2
endif
config ZMK_SPLIT_BLE_ROLE_PERIPHERAL

View File

@@ -0,0 +1,6 @@
config BOARD_ENABLE_DCDC
bool "Enable DCDC mode"
select SOC_DCDC_NRF52X
default y
depends on BOARD_NICE_NANO

View File

@@ -6,3 +6,4 @@
config BOARD_NICE_NANO
bool "nice!nano"
depends on SOC_NRF52840_QIAA

View File

@@ -1,4 +1,4 @@
# SPDX-License-Identifier: Apache-2.0
# SPDX-License-Identifier: MIT
board_runner_args(nrfjprog "--nrf-family=NRF52" "--softreset")
include(${ZEPHYR_BASE}/boards/common/blackmagicprobe.board.cmake)

View File

@@ -1,4 +1,4 @@
# SPDX-License-Identifier: Apache-2.0
# SPDX-License-Identifier: MIT
if(CONFIG_PINMUX)
zephyr_library()

View File

@@ -1,7 +1,7 @@
/*
* Copyright (c) 2017 I-SENSE group of ICCS
*
* SPDX-License-Identifier: Apache-2.0
* SPDX-License-Identifier: MIT
*/
#include <kernel.h>

View File

@@ -1,5 +1,6 @@
# Uncomment the following line to enable the Corne RGB Underglow
# Uncomment the following lines to enable the Corne RGB Underglow
# ZMK_RGB_UNDERGLOW=y
# CONFIG_WS2812_STRIP=y
# Uncomment the following line to enable the Corne OLED Display
# CONFIG_ZMK_DISPLAY=y

View File

@@ -5,5 +5,6 @@
# Uncomment the following line to enable the Kyria OLED Display
# CONFIG_ZMK_DISPLAY=y
# Uncomment the following line to enable RGB underglow
# Uncomment the following lines to enable RGB underglow
# CONFIG_ZMK_RGB_UNDERGLOW=y
# CONFIG_WS2812_STRIP=y

View File

@@ -1,7 +1,7 @@
/*
* Copyright (c) 2016 Intel Corporation
*
* SPDX-License-Identifier: Apache-2.0
* SPDX-License-Identifier: MIT
*/
#define DT_DRV_COMPAT alps_ec11

View File

@@ -31,11 +31,11 @@ static void connected(struct bt_conn *conn, u8_t err)
if (err)
{
printk("Failed to connect to %s (%u)\n", addr, err);
LOG_WRN("Failed to connect to %s (%u)", log_strdup(addr), err);
return;
}
printk("Connected %s\n", addr);
LOG_DBG("Connected %s", log_strdup(addr));
bt_conn_le_param_update(conn, BT_LE_CONN_PARAM(0x0006, 0x000c, 30, 400));
@@ -45,7 +45,7 @@ static void connected(struct bt_conn *conn, u8_t err)
if (bt_conn_set_security(conn, BT_SECURITY_L2))
{
printk("Failed to set security\n");
LOG_ERR("Failed to set security");
}
}
@@ -55,7 +55,7 @@ static void disconnected(struct bt_conn *conn, u8_t reason)
bt_addr_le_to_str(bt_conn_get_dst(conn), addr, sizeof(addr));
printk("Disconnected from %s (reason 0x%02x)\n", addr, reason);
LOG_DBG("Disconnected from %s (reason 0x%02x)", log_strdup(addr), reason);
}
static void security_changed(struct bt_conn *conn, bt_security_t level,
@@ -67,11 +67,11 @@ static void security_changed(struct bt_conn *conn, bt_security_t level,
if (!err)
{
printk("Security changed: %s level %u\n", addr, level);
LOG_DBG("Security changed: %s level %u", log_strdup(addr), level);
}
else
{
printk("Security failed: %s level %u err %d\n", addr, level,
LOG_ERR("Security failed: %s level %u err %d", log_strdup(addr), level,
err);
}
}
@@ -107,7 +107,7 @@ static void auth_passkey_display(struct bt_conn *conn, unsigned int passkey)
bt_addr_le_to_str(bt_conn_get_dst(conn), addr, sizeof(addr));
printk("Passkey for %s: %06u\n", addr, passkey);
LOG_DBG("Passkey for %s: %06u", log_strdup(addr), passkey);
}
#ifdef CONFIG_ZMK_BLE_PASSKEY_ENTRY
@@ -118,7 +118,7 @@ static void auth_passkey_entry(struct bt_conn *conn)
bt_addr_le_to_str(bt_conn_get_dst(conn), addr, sizeof(addr));
printk("Passkey entry requested for %s\n", addr);
LOG_DBG("Passkey entry requested for %s", log_strdup(addr));
auth_passkey_entry_conn = bt_conn_ref(conn);
}
@@ -138,7 +138,7 @@ static void auth_cancel(struct bt_conn *conn)
passkey_digit = 0;
printk("Pairing cancelled: %s\n", addr);
LOG_DBG("Pairing cancelled: %s", log_strdup(addr));
}
static struct bt_conn_auth_cb zmk_ble_auth_cb_display = {
@@ -169,14 +169,14 @@ static void zmk_ble_ready(int err)
LOG_DBG("ready? %d", err);
if (err)
{
printk("Bluetooth init failed (err %d)\n", err);
LOG_ERR("Bluetooth init failed (err %d)", err);
return;
}
err = bt_le_adv_start(BT_LE_ADV_CONN_NAME, zmk_ble_ad, ARRAY_SIZE(zmk_ble_ad), NULL, 0);
if (err)
{
printk("Advertising failed to start (err %d)\n", err);
LOG_ERR("Advertising failed to start (err %d)", err);
return;
}
}
@@ -187,7 +187,7 @@ static int zmk_ble_init(struct device *_arg)
if (err)
{
printk("BLUETOOTH FAILED");
LOG_ERR("BLUETOOTH FAILED (%d)", err);
return err;
}