5340 audio change to right channel

Hello

nRF5340-audio-DK, NCS2.0.2, VScode

press BUTTON_VOLUME_UP then button reset,can't change to channel right.

    if (CONFIG_AUDIO_DEV == HEADSET) {
        ret=channel_assignment_set(AUDIO_CHANNEL_RIGHT);
        if(ret)printk("set channel right err:%d\n",ret);
    }

change to channel right failed, return -30

  

another question,  5340-audio can DFU?

  

Best regards

Parents
  • Hi 

    Did you make any changes to the sample, or are you experiencing issues straight out of the box?

    Are you sure that both the left and right channels are being sent from somewhere?

    another question,  5340-audio can DFU?

    Yes, this is possible. You can read more about the DFU support here.

    Best regards
    Torbjørn 

  • Hi,

    thanks for reply,

    1.not change the sample code, only to know how to change channels dynamicy in code.

       

    2.form the link,i don' konw how to add DFU, is there have examples for it?

    i konw hello_world project add DFU like follow:

    #include <mgmt/mcumgr/smp_bt.h>
    #include "os_mgmt/os_mgmt.h"
    #include "img_mgmt/img_mgmt.h"
    void ota()
    {
        os_mgmt_register_group();
        img_mgmt_register_group();
        smp_bt_register();

        int err = bt_enable(NULL);
        if (err) {
            printk("Bluetooth init failed (err %d)\n", err);
            return;
        }
        if (IS_ENABLED(CONFIG_SETTINGS)) {
            settings_load();
        }

        err = bt_le_adv_start(BT_LE_ADV_CONN, upad, ARRAY_SIZE(upad),upsd, ARRAY_SIZE(upsd));
        if (err) {
            printk("Advertising failed to start (err %d)\n", err);
            return;
        }
    }
       
    Best regards
Reply
  • Hi,

    thanks for reply,

    1.not change the sample code, only to know how to change channels dynamicy in code.

       

    2.form the link,i don' konw how to add DFU, is there have examples for it?

    i konw hello_world project add DFU like follow:

    #include <mgmt/mcumgr/smp_bt.h>
    #include "os_mgmt/os_mgmt.h"
    #include "img_mgmt/img_mgmt.h"
    void ota()
    {
        os_mgmt_register_group();
        img_mgmt_register_group();
        smp_bt_register();

        int err = bt_enable(NULL);
        if (err) {
            printk("Bluetooth init failed (err %d)\n", err);
            return;
        }
        if (IS_ENABLED(CONFIG_SETTINGS)) {
            settings_load();
        }

        err = bt_le_adv_start(BT_LE_ADV_CONN, upad, ARRAY_SIZE(upad),upsd, ARRAY_SIZE(upsd));
        if (err) {
            printk("Advertising failed to start (err %d)\n", err);
            return;
        }
    }
       
    Best regards
Children
Related