MMM-Assistant
MMM-Assistant copied to clipboard
Update packages
New packages available;
@google-cloud/speech ^1.3.0 → ^1.4.0
speaker ^0.4.0 → ^0.4.1
I have made some trials with the latest packages. This showed to be quite a PITA, but it now works. The packages should now be ok with:
},
"dependencies": {
"@google-cloud/speech": "^1.4.0",
"aplay": "^1.2.0",
"electron-rebuild": "^1.7.3",
"google-assistant": "^0.2.2",
"node-aplay": "^1.0.3",
"node-record-lpcm16": "^0.3.0",
"snowboy": "^1.2.0",
"speaker": "^0.4.1"
},
"devDependencies": {
"yarg": "^1.0.8"
}
However! Raspberry pi foundation has pushed out two (!) new nodejs APT packages. So if you're still at v9.8.0
, you have to update twice!! (yeah, fcuking crazy!) The second problem with those are that they insist using the outdated npm version of v5.6.0
instead v5.8.0
. Important is that you will not get a working install with npm install
, until you have updated these!
So the way to update is this:
sudo apt-get updates
sudo apt-get upgrade
sudo reboot now
# Check your node/npm versions
node -v && npm -v
sudo apt-get updates
sudo apt-get install nodejs # v9.8.0 ==> v9.10.1
sudo apt-get updates
sudo apt-get install nodejs # v9.10.1 ==> v9.11.1
date; time sudo npm install npm@latest -g # ~4 min // v5.6.0 ==> v5.8.0
rm -fr ./node_modules
date; time npm install # ~ ?? min
date; time ./node_modules/.bin/electron-rebuild # ~21 min
AFAICT. The main difference is that the package that will be re-built this time, is not gRPC, which now has binaries, but snowboy, so it will be quicker. But who knows whats happening behind the scenes...
Then some package (I have no idea which) will mess up your ALSA config in ~/.asoundrc
. So make a backup! and then copy it back.
For a USB card, it should look something like this:
pcm.!default {
type asym
playback.pcm {
type plug
slave.pcm "hw:1,0"
}
capture.pcm {
type plug
slave.pcm "hw:1,0"
}
}
ctl.!default {
type hw
card 1
}