I just discovered nRF Connect for Desktop. I am setting up one of our nRF52 DK (PCA10040) boards to serve as a Bluetooth central device for our other nRF52 peripherals. The desktop computer is running Ubuntu Linux 16.04.
I haven't compiled a Bluetooth peripheral example to test everything end-to-end quite yet. However, I can start the nRF Connect software with a board connected to USB, and then I scan for advertising devices, and it finds several. So far, that looks good.
However, when I exit the nRF Connect software, I get the following error:
A JavaScript error occurred in the main process
Uncaught Exception:
Error: EACCES: permission denied, open '/home/john/.config/nrfconnect/settings.json'
at Error (native)
at Object.fs.openSync (fs.js:634:18)
at Object.module.(anonymous function) [as openSync] (ELECTRON_ASAR.js:158:20)
at Object.fs.writeFileSync (fs.js:1337:33)
at save (/home/john/bin/nrf-connect-linux-x64/resources/app/node_modules/nrfconnect-appmodule-ble/node_modules/nrfconnect-core/settings.js:75:8)
at Object.exports.set (/home/john/bin/nrf-connect-linux-x64/resources/app/node_modules/nrfconnect-appmodule-ble/node_modules/nrfconnect-core/settings.js:81:5)
at Object.exports.storeLastWindow.lastWindowState [as storeLastWindow] (/home/john/bin/nrf-connect-linux-x64/resources/app/node_modules/nrfconnect-appmodule-ble/node_modules/nrfconnect-core/settings.js:120:10)
at BrowserWindow.<anonymous> (/home/john/bin/nrf-connect-linux-x64/resources/app/node_modules/nrfconnect-appmodule-ble/node_modules/nrfconnect-core/index.js:103:22)
at emitOne (events.js:96:13)
at BrowserWindow.emit (events.js:188:7)
Because I saw that permissions were being denied, I thought to try invoking nRF Connect using sudo from the Linux console. If I do that, the error disappears.
I wasn't given the option to install nRF Connect using sudo. I followed the installation instructions in the nRF Connect manual, and I ended up with a local, single-user installation without sudo privileges.
This may not actually interfere with my ability to operate nRF Connect. I'm still figuring that out. However, I have to ask: what's wrong, and how do I fix it? Thanks.