Skip to content
This repository has been archived by the owner on Jan 15, 2024. It is now read-only.

Alexa Smart Screen SDK make error #41

Closed
1 of 8 tasks
ameraj1 opened this issue Sep 4, 2020 · 27 comments
Closed
1 of 8 tasks

Alexa Smart Screen SDK make error #41

ameraj1 opened this issue Sep 4, 2020 · 27 comments

Comments

@ameraj1
Copy link

ameraj1 commented Sep 4, 2020

IMPORTANT: Before you create an issue, please take a look at our Issue Reporting Guide.

Briefly summarize your issue:

while trying to make screen SDK gui error occurred.

What is the expected behavior?

What behavior are you observing?

Provide the steps to reproduce the issue, if applicable:

make AVS screen SDK

Tell us about your environment:

Raspberry pi

What version of the AVS Device SDK are you using?

  <x.y.z>

Tell us what hardware you're using:

  • Desktop / Laptop
  • [X ] Raspberry Pi
  • Other - tell us more:

Tell us about your OS (Type & version):

  • Linux
  • MacOS
  • Raspbian Stretch
  • Raspbian Jessy
  • Other - tell us more: Buster

Have you tried the same use case with AVS Device SDK SampleApp?

  • [X ] The issue is not applicable to the AVS Device SDK SampleApp.

  • The issue is not reproducible on the AVS Device SDK SampleApp.

    ^~~~~~~~~~~~
    

[ 98%] Building CXX object modules/Alexa/SampleApp/src/CMakeFiles/SampleApp.dir/PortAudioMicrophoneWrapper.cpp.o
[100%] Linking CXX executable SampleApp
[100%] Built target SampleApp
Scanning dependencies of target GUIClient
npm WARN deprecated tslint-loader@3.6.0: TSLint is deprecated. As such migrate from tslint-loader to eslint-loader.
npm WARN deprecated chokidar@2.1.8: Chokidar 2 will break on node v14+. Upgrade to chokidar 3 with 15x less dependencies.
npm WARN deprecated resolve-url@0.2.1: https://github.com/lydell/resolve-url#deprecated
npm WARN deprecated urix@0.1.0: Please see https://github.com/lydell/urix#deprecated
npm WARN deprecated fsevents@1.2.13: fsevents 1 will break on node v14+ and could be using insecure binaries. Upgrade to fsevents 2.
npm notice created a lockfile as package-lock.json. You should commit this file.
npm WARN notsup Unsupported engine for watchpack-chokidar2@2.0.0: wanted: {"node":"<8.10.0"} (current: {"node":"12.18.3","npm":"6.14.6"})
npm WARN notsup Not compatible with your version of node/npm: watchpack-chokidar2@2.0.0
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@~2.1.2 (node_modules/chokidar/node_modules/fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@2.1.3: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"arm"})
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@^1.2.7 (node_modules/watchpack-chokidar2/node_modules/chokidar/node_modules/fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.13: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"arm"})
npm WARN gui@1.0.0 No repository field.
npm WARN gui@1.0.0 license should be a valid SPDX license expression

added 508 packages from 334 contributors and audited 510 packages in 170.708s

22 packages are looking for funding
run npm fund for details

found 0 vulnerabilities

gui@1.0.0 build /home/pi/sdk_folder/alexa-smart-screen-sdk/modules/GUI/js
npm run lint && webpack --config webpack.config.js "--output-path" "/home/pi/sdk_folder/ss-build/modules/GUI" "--define" "DISABLE_WEBSOCKET_SSL=true" "--define" "USE_UWP_CLIENT=false"

gui@1.0.0 lint /home/pi/sdk_folder/alexa-smart-screen-sdk/modules/GUI/js
tslint --project tsconfig.json -c tslint.json 'src//*.ts' 'src//*.tsx'

Hash: 01b181f7dc8bb2a86259
Version: webpack 4.44.1
Time: 110762ms
Built at: 09/04/2020 15:38:02
34 assets
Entrypoint main = main.bundle.js
[1] /home/pi/sdk_folder/alexa-smart-screen-sdk/modules/GUI/apl-client/index.js 607 KiB {0} [built]
[4] ./lib/config/IDeviceAppConfig.ts 794 bytes {0} [built]
[5] ./lib/messages/messages.ts 1.73 KiB {0} [built]
[10] ./lib/displayCards/AVSDisplayCardHelpers.ts 2.86 KiB {0} [built]
[11] ./main.tsx 563 bytes {0} [built]
[12] ./app.tsx 17.9 KiB {0} [built]
[25] ./lib/messages/NavigationEvent.ts 637 bytes {0} [built]
[26] ./lib/messages/client.ts 3.51 KiB {0} [built]
[30] ./lib/messages/sdkLogTransport.ts 1.7 KiB {0} [built]
[31] ./lib/focus/FocusManager.ts 3.03 KiB {0} [built]
[32] ./lib/activity/ActivityTracker.ts 2.38 KiB {0} [built]
[37] ./lib/config/GuiConfigHelpers.ts 8.14 KiB {0} [built]
[38] ./lib/messages/UWPClient.ts 1.67 KiB {0} [built]
[46] ./main.css 1.05 KiB {0} [built]
[47] ../node_modules/css-loader/dist/cjs.js!./main.css 735 bytes {0} [built]
+ 33 hidden modules

ERROR in /home/pi/sdk_folder/alexa-smart-screen-sdk/modules/GUI/js/node_modules/@types/node/base.d.ts
[tsl] ERROR in /home/pi/sdk_folder/alexa-smart-screen-sdk/modules/GUI/js/node_modules/@types/node/base.d.ts(10,1)
TS1084: Invalid 'reference' directive syntax.

ERROR in /home/pi/sdk_folder/alexa-smart-screen-sdk/modules/GUI/js/node_modules/@types/node/base.d.ts
[tsl] ERROR in /home/pi/sdk_folder/alexa-smart-screen-sdk/modules/GUI/js/node_modules/@types/node/base.d.ts(11,1)
TS1084: Invalid 'reference' directive syntax.

ERROR in /home/pi/sdk_folder/alexa-smart-screen-sdk/modules/GUI/js/node_modules/@types/node/base.d.ts
[tsl] ERROR in /home/pi/sdk_folder/alexa-smart-screen-sdk/modules/GUI/js/node_modules/@types/node/base.d.ts(12,1)
TS1084: Invalid 'reference' directive syntax.

ERROR in /home/pi/sdk_folder/alexa-smart-screen-sdk/modules/GUI/js/node_modules/@types/node/base.d.ts
[tsl] ERROR in /home/pi/sdk_folder/alexa-smart-screen-sdk/modules/GUI/js/node_modules/@types/node/base.d.ts(13,1)
TS1084: Invalid 'reference' directive syntax.

ERROR in /home/pi/sdk_folder/alexa-smart-screen-sdk/modules/GUI/js/node_modules/@types/node/assert.d.ts
[tsl] ERROR in /home/pi/sdk_folder/alexa-smart-screen-sdk/modules/GUI/js/node_modules/@types/node/assert.d.ts(2,68)
TS1144: '{' or ';' expected.

ERROR in /home/pi/sdk_folder/alexa-smart-screen-sdk/modules/GUI/js/node_modules/@types/node/assert.d.ts
[tsl] ERROR in /home/pi/sdk_folder/alexa-smart-screen-sdk/modules/GUI/js/node_modules/@types/node/assert.d.ts(22,68)
TS1144: '{' or ';' expected.

ERROR in /home/pi/sdk_folder/alexa-smart-screen-sdk/modules/GUI/js/node_modules/@types/node/assert.d.ts
[tsl] ERROR in /home/pi/sdk_folder/alexa-smart-screen-sdk/modules/GUI/js/node_modules/@types/node/assert.d.ts(31,94)
TS1144: '{' or ';' expected.

ERROR in /home/pi/sdk_folder/alexa-smart-screen-sdk/modules/GUI/js/node_modules/@types/node/assert.d.ts
[tsl] ERROR in /home/pi/sdk_folder/alexa-smart-screen-sdk/modules/GUI/js/node_modules/@types/node/assert.d.ts(31,101)
TS1005: ';' expected.

ERROR in /home/pi/sdk_folder/alexa-smart-screen-sdk/modules/GUI/js/node_modules/@types/node/assert.d.ts
[tsl] ERROR in /home/pi/sdk_folder/alexa-smart-screen-sdk/modules/GUI/js/node_modules/@types/node/assert.d.ts(31,104)
TS1005: ';' expected.

ERROR in /home/pi/sdk_folder/alexa-smart-screen-sdk/modules/GUI/js/node_modules/@types/node/assert.d.ts
[tsl] ERROR in /home/pi/sdk_folder/alexa-smart-screen-sdk/modules/GUI/js/node_modules/@types/node/assert.d.ts(33,98)
TS1144: '{' or ';' expected.

ERROR in /home/pi/sdk_folder/alexa-smart-screen-sdk/modules/GUI/js/node_modules/@types/node/assert.d.ts
[tsl] ERROR in /home/pi/sdk_folder/alexa-smart-screen-sdk/modules/GUI/js/node_modules/@types/node/assert.d.ts(33,105)
TS1005: ';' expected.

ERROR in /home/pi/sdk_folder/alexa-smart-screen-sdk/modules/GUI/js/node_modules/@types/node/assert.d.ts
[tsl] ERROR in /home/pi/sdk_folder/alexa-smart-screen-sdk/modules/GUI/js/node_modules/@types/node/assert.d.ts(33,108)
TS1005: ';' expected.

ERROR in /home/pi/sdk_folder/alexa-smart-screen-sdk/modules/GUI/js/node_modules/@types/node/assert.d.ts
[tsl] ERROR in /home/pi/sdk_folder/alexa-smart-screen-sdk/modules/GUI/js/node_modules/@types/node/assert.d.ts(41,47)
TS1144: '{' or ';' expected.

ERROR in /home/pi/sdk_folder/alexa-smart-screen-sdk/modules/GUI/js/node_modules/@types/node/assert.d.ts
[tsl] ERROR in /home/pi/sdk_folder/alexa-smart-screen-sdk/modules/GUI/js/node_modules/@types/node/assert.d.ts(41,53)
TS1005: ';' expected.

ERROR in /home/pi/sdk_folder/alexa-smart-screen-sdk/modules/GUI/js/node_modules/@types/node/assert.d.ts
[tsl] ERROR in /home/pi/sdk_folder/alexa-smart-screen-sdk/modules/GUI/js/node_modules/@types/node/assert.d.ts(41,56)
TS1005: ';' expected.
Child html-webpack-plugin for "index.html":
1 asset
Entrypoint undefined = index.html
4 modules
npm ERR! code ELIFECYCLE
npm ERR! errno 2
npm ERR! gui@1.0.0 build: npm run lint && webpack --config webpack.config.js "--output-path" "/home/pi/sdk_folder/ss-build/modules/GUI" "--define" "DISABLE_WEBSOCKET_SSL=true" "--define" "USE_UWP_CLIENT=false"
npm ERR! Exit status 2
npm ERR!
npm ERR! Failed at the gui@1.0.0 build script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR! /home/pi/.npm/_logs/2020-09-04T14_38_02_946Z-debug.log
make[2]: *** [modules/GUI/CMakeFiles/GUIClient.dir/build.make:59: modules/GUI/CMakeFiles/GUIClient] Error 2
make[1]: *** [CMakeFiles/Makefile2:2468: modules/GUI/CMakeFiles/GUIClient.dir/all] Error 2
make: *** [Makefile:130: all] Error 2

@albanoandrea
Copy link

Got exactly the same error.
Here the complete log found.

2020-09-04T15_50_33_863Z-debug.log

I'm working on Ubuntu 16.04.

@powj
Copy link
Contributor

powj commented Sep 4, 2020

Thank you for raising this issue, it appears that an upgrade to one of our node dependencies has caused the build fail. We will be resolving these issues by locking the dependency versions in our next release.

In the meantime please can you use the attached package-lock.json file.
Once downloaded and extracted please copy it to modules/GUI/js/package-lock.json overwriting any generated files you may have there, I would also recommend you delete the contents of node_modules in the same directory to prevent the wrong dependencies being used. Once you have done this please run make again to retry the build.

package-lock.json.zip

@ameraj1
Copy link
Author

ameraj1 commented Sep 4, 2020

Hi Powj,

Thanks for the swift response.

I will give it a try the fix you mentioned. I will keep you posted with the progress.

Thanks,
Regards,
Ali

@ameraj1
Copy link
Author

ameraj1 commented Sep 4, 2020

Hi Powj,

quick update, after replacing the file it all works fine now.

I have another question. How can I enable the "Wake" Alexa feature on Screen SDK

@lynx-arul
Copy link
Contributor

Hi Ali,
I'm guessing you mean Wake Word? If so please follow the instructions on avs-device-sdk - Guide.

Also make sure to apply the same flags on the Smart-screen-sdk

 -DSENSORY_KEY_WORD_DETECTOR=ON \
 -DSENSORY_KEY_WORD_DETECTOR_LIB_PATH=/home/pi/sdk-folder/third-party/alexa-rpi/lib/libsnsr.a \
 -DSENSORY_KEY_WORD_DETECTOR_INCLUDE_DIR=/home/pi/sdk-folder/third-party/alexa-rpi/include \

@ameraj1
Copy link
Author

ameraj1 commented Sep 5, 2020

Hi Lynx-arul,

Thanks for the info. I will give it a try.

Thanks,
Ali

@ameraj1
Copy link
Author

ameraj1 commented Sep 5, 2020

Hi Lynx-Arul,

so got the AVS working with wake word turned on but I got AlexaClientSDK 1.20.1 instead of 1.20.0 so now when try to make config for screen then it fails as it is looking for 1.20.0. Is there a way to change the AlexaClientSDK version check to 1.20.1

below is the error details:
pi@raspberrypi:~/sdk_folder/ss-build $ cmake -DCMAKE_PREFIX_PATH=$HOME/sdk_folder/sdk-install \

-DWEBSOCKETPP_INCLUDE_DIR=$HOME/sdk_folder/third-party/websocketpp-0.8.1
-DSENSORY_KEY_WORD_DETECTOR=ON
-DSENSORY_KEY_WORD_DETECTOR_LIB_PATH=/home/pi/sdk_folder/third-party/alexa-rpi/lib/libsnsr.a
-DSENSORY_KEY_WORD_DETECTOR_INCLUDE_DIR=/home/pi/sdk_folder/third-party/alexa-rpi/include
-DDISABLE_WEBSOCKET_SSL=ON
-DGSTREAMER_MEDIA_PLAYER=ON
-DCMAKE_BUILD_TYPE=DEBUG
-DPORTAUDIO=ON -DPORTAUDIO_LIB_PATH=$HOME/sdk_folder/third-party/portaudio/lib/.libs/libportaudio.a
-DPORTAUDIO_INCLUDE_DIR=$HOME/sdk_folder/third-party/portaudio/include/
-DAPL_CORE=ON
-DAPLCORE_INCLUDE_DIR=$HOME/sdk_folder/apl-core-library/aplcore/include
-DAPLCORE_LIB_DIR=$HOME/sdk_folder/apl-core-library/build/aplcore
-DYOGA_INCLUDE_DIR=$HOME/sdk_folder/apl-core-library/build/yoga-prefix/src/yoga
-DYOGA_LIB_DIR=$HOME/sdk_folder/apl-core-library/build/lib
../alexa-smart-screen-sdk
-- The CXX compiler identification is GNU 8.3.0
-- Check for working CXX compiler: /usr/bin/c++
-- Check for working CXX compiler: /usr/bin/c++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Found PkgConfig: /usr/bin/pkg-config (found version "0.29")
-- Checking for module 'AlexaClientSDK=1.20.0'
-- Requested 'AlexaClientSDK = 1.20.0' but version of AlexaClientSDK is 1.20.1
CMake Error at /usr/share/cmake-3.13/Modules/FindPkgConfig.cmake:452 (message):
A required package was not found
Call Stack (most recent call first):
/usr/share/cmake-3.13/Modules/FindPkgConfig.cmake:622 (_pkg_check_modules_internal)
modules/Alexa/CMakeLists.txt:7 (pkg_check_modules)

-- Configuring incomplete, errors occurred!
See also "/home/pi/sdk_folder/ss-build/CMakeFiles/CMakeOutput.log".

@ameraj1
Copy link
Author

ameraj1 commented Sep 5, 2020

One more question how can I start Wake word along with smart screen

cd $HOME/sdk_folder/ss-build
PA_ALSA_PLUGHW=1 ./modules/Alexa/SampleApp/src/SampleApp -C
$HOME/sdk_folder/sdk-build/Integration/AlexaClientSDKConfig.json -C
$HOME/sdk_folder/alexa-smart-screen-sdk/modules/GUI/config/SmartScreenSDKConfig.json -L INFO

I tried adding ../third-party/alexa-rpi/models at the end of AlexaClientSDKConfig.json but that didnt work

@lynx-arul
Copy link
Contributor

For your first question, please use v1.20.0. The current Smart Screen SDK (v2.2.1) is only compatible with Device SDK v1.20.0 - Here is the repo link - avs-device-sdk.
For reference here are all their releases : https://github.com/alexa/avs-device-sdk/releases

As far as your second question, you should be able to run the Sample App the same way with or without the wake-word. The only difference is how you build the Sample App. As long as you create a new build folder and add the flags mentioned above you should be fine.
No need to modified the AlexaClientSDKConfig.json or SmartScreenSDKConfig.json

@ameraj1
Copy link
Author

ameraj1 commented Sep 7, 2020

Hi Lynx-arul,

Thanks for the help. I will give it a try with AVS SDK version v1.20.0 and let you know if it works.

Thanks,
Regards,
Ali

@albanoandrea
Copy link

Thank you for raising this issue, it appears that an upgrade to one of our node dependencies has caused the build fail. We will be resolving these issues by locking the dependency versions in our next release.

In the meantime please can you use the attached package-lock.json file.
Once downloaded and extracted please copy it to modules/GUI/js/package-lock.json overwriting any generated files you may have there, I would also recommend you delete the contents of node_modules in the same directory to prevent the wrong dependencies being used. Once you have done this please run make again to retry the build.

package-lock.json.zip

Thank you, it worked for me too.

@ameraj1
Copy link
Author

ameraj1 commented Sep 8, 2020

Hi,

so I have now everything up and working except the wake word.

when I run the following command then I still have to use "A" to talk to alexa.
cd $HOME/sdk_folder/ss-build
PA_ALSA_PLUGHW=1 ./modules/Alexa/SampleApp/src/SampleApp -C
$HOME/sdk_folder/sdk-build/Integration/AlexaClientSDKConfig.json -C
$HOME/sdk_folder/alexa-smart-screen-sdk/modules/GUI/config/SmartScreenSDKConfig.json -L INFO

if i run AVS independently with following command then the Wake word works
PA_ALSA_PLUGHW=1 ./SampleApp/src/SampleApp ./Integration/AlexaClientSDKConfig.json ../third-party/alexa-rpi/models

so the additional call in this case is "../third-party/alexa-rpi/models" which makes the wake word works.

now i dont know how to make this work with screen SDK, could you please help me to launch the wake word with screen as well thanks.

@powj
Copy link
Contributor

powj commented Sep 8, 2020

You will need to pass in the models using the -K (keyword) flag:
PA_ALSA_PLUGHW=1 ./modules/Alexa/SampleApp/src/SampleApp -C $HOME/sdk_folder/sdk-build/Integration/AlexaClientSDKConfig.json -C $HOME/sdk_folder/alexa-smart-screen-sdk/modules/GUI/config/SmartScreenSDKConfig.json -L INFO -K <path to third-party/alexa-rpi/models>

@ameraj1
Copy link
Author

ameraj1 commented Sep 8, 2020

Hi Powj,

Thank you very much for your help. Its all working nicely.

Regards,
Ali

@ulrich-berl
Copy link

ulrich-berl commented Sep 10, 2020

hi

using same environment (raspberry pi, buster, node 12.8.3, wakeword) with provided package-lock.json i get following error:

> gui@1.0.0 build /home/pi/sdk_folder/alexa-smart-screen-sdk/modules/GUI/js
> npm run lint && webpack --config webpack.config.js "--output-path" "/home/pi/sdk_folder/ss-build/modules/GUI" "--define" "DISABLE_WEBSOCKET_SSL=true" "--define" "USE_UWP_CLIENT=false"

> gui@1.0.0 lint /home/pi/sdk_folder/alexa-smart-screen-sdk/modules/GUI/js
> tslint --project tsconfig.json -c tslint.json 'src/**/*.ts' 'src/**/*.tsx'

Hash: 76e98e21af18c4283865
Version: webpack 4.44.1
Time: 41810ms
Built at: 09/10/2020 7:46:29 PM
 34 assets
Entrypoint main = main.bundle.js
 [1] /home/pi/sdk_folder/alexa-smart-screen-sdk/modules/GUI/apl-client/index.js 607 KiB {0} [built]
 [4] ./lib/config/IDeviceAppConfig.ts 832 bytes {0} [built]
 [5] ./lib/messages/messages.ts 1.84 KiB {0} [built]
[10] ./lib/displayCards/AVSDisplayCardHelpers.ts 2.97 KiB {0} [built]
[11] ./main.tsx 563 bytes {0} [built]
[12] ./app.tsx 17.9 KiB {0} [built] [1 error]
[25] ./lib/messages/NavigationEvent.ts 671 bytes {0} [built]
[26] ./lib/messages/client.ts 3.53 KiB {0} [built]
[30] ./lib/messages/sdkLogTransport.ts 1.73 KiB {0} [built]
[31] ./lib/focus/FocusManager.ts 3.06 KiB {0} [built]
[32] ./lib/activity/ActivityTracker.ts 2.42 KiB {0} [built]
[37] ./lib/config/GuiConfigHelpers.ts 8.21 KiB {0} [built]
[38] ./lib/messages/UWPClient.ts 1.7 KiB {0} [built]
[46] ./main.css 1.05 KiB {0} [built]
[47] ../node_modules/css-loader/dist/cjs.js!./main.css 735 bytes {0} [built]
    + 33 hidden modules

ERROR in /home/pi/sdk_folder/alexa-smart-screen-sdk/modules/GUI/js/src/app.tsx
./app.tsx
[tsl] ERROR in /home/pi/sdk_folder/alexa-smart-screen-sdk/modules/GUI/js/src/app.tsx(144,9)
      TS2322: Type 'Timeout' is not assignable to type 'number'.
Child html-webpack-plugin for "index.html":
     1 asset
    Entrypoint undefined = index.html
       4 modules
npm ERR! code ELIFECYCLE

build succeeds after changing app.tsx

private lastCaptionTimeOutId : number;

to

private lastCaptionTimeOutId : any;

br, uberl

@CAG5
Copy link

CAG5 commented Sep 14, 2020

I too am having the exact same problem. Has a solution to this been discovered yet?

As of the last time that I reinstalled raspbian and started from scratch, my OS is whatever the raspberry pi had for the noobs full download as of this morning. I am trying to install the Alexa Smart Screen SDK on my Raspberry Pi 4. I make it all the way without any issues to step 9. The second part of step 9 is the make portion of the code, upon completion I get the following errors and logfile (Attached Doc)
Errors and log file.docx

At this point of have completely erased and started from scratch at least 10 times in the past week, not to mention the countless retrys and fixes in between, so any help would be greatly appreciated.
Errors and log file.docx

After following the above guidance replacing the package-lock.json as instructed above, it still is not working for me.

This is what comes out in the terminal, however I still can't access the HTTP file via the web browser.
Build context error.docx

@chemudug-amzn
Copy link
Contributor

Hi @CAG5 - Please send us a log file in plain text as I am unable to open docx files.

@CAG5
Copy link

CAG5 commented Sep 17, 2020

Hi @CAG5 - Please send us a log file in plain text as I am unable to open docx files.

Sure, I can try anyway. Hope that this helps
Build.context.error.txt
Current errors.txt
Errors.and.log.file.txt

@chemudug-amzn
Copy link
Contributor

@CAG5
Your Current errors file indicate that everything built and the sampleApp is launched.

[100%] Built target GUIClient

In your Build context file, I can see the error message, how is this effecting the UI? Are you still able to invoke Alexa and ask for time for e.g.?

In your Errors and log file, I see error - but is this before you tried something else, because Current errors passes.

Please go through these steps:

  1. Remove node_modules folder rm -rf node_modules
  2. Install package-lock.json file unzip package-lock.json.zip
  3. In your build folder run make

@chemudug-amzn
Copy link
Contributor

@ulrich-berl Please delete your node_modules folder after you installed the package-lock.json . I repeated the steps above, and did not see the same error.

@CAG5
Copy link

CAG5 commented Sep 22, 2020

@ulrich-berl Please delete your node_modules folder after you installed the package-lock.json . I repeated the steps above, and did not see the same error.

When I followed the above steps this time. I recieved errno 2 ELIFECYCLE error, so I went to the /modules/gui/js/ folder and deleted all contents of the node-js folder and manually copy and pasted the unzipped package-lock json there and ran the make command again and it finally worked. However separate but related issue, even after going to sudo raspi-config and changing the speaker output and selecting analog from the desktop, it only plays out of my monitor speakers and not the speakers that I have plugged into the 3.5mm jack, and I still have not been able to get the wakeword to work so it is completely voice activated.

@chemudug-amzn
Copy link
Contributor

@CAG5 great!

Please paste this to your ${HOME}/.asoundrc file:

pcm.!default {
  type asym
  capture.pcm "mic"
  playback.pcm "speaker"
}
pcm.mic {
  type plug
  slave {
    pcm "hw:<card number>,<device number>"
  }
}
pcm.speaker {
  type plug
  slave {
    pcm "hw:<card number>,<device number>"
  }
}

Copied from https://iotbytes.wordpress.com/connect-configure-and-test-usb-microphone-and-speaker-with-raspberry-pi/

@chemudug-amzn
Copy link
Contributor

Please edit values as applicable to your setup.

@CAG5
Copy link

CAG5 commented Sep 22, 2020

Please edit values as applicable to your setup.

Awesome, didn't fix it at first, so did the raspi-config, and desktop and the ~/.asoundrc file and then rebooted it and now the speaker and mic work. Any suggestions on how to get it to recognize the wakeword so I can stop holding down the "A" key everytime I want to interact with it?

@ulrich-berl
Copy link

ulrich-berl commented Sep 22, 2020

@ulrich-berl Please delete your node_modules folder after you installed the package-lock.json . I repeated the steps above, and did not see the same error.

negative, already replaced package-lock.json and removed node_modules folder, then make:

[100%] Built target SampleApp
npm WARN gui@1.0.0 No repository field.
npm WARN gui@1.0.0 license should be a valid SPDX license expression
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.13 (node_modules/watchpack-chokidar2/node_modules/fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.13: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"arm"})
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@2.1.3 (node_modules/fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@2.1.3: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"arm"})

added 506 packages from 333 contributors and audited 511 packages in 81.984s

22 packages are looking for funding
  run `npm fund` for details

found 0 vulnerabilities


> gui@1.0.0 build /home/pi/sdk_folder/alexa-smart-screen-sdk/modules/GUI/js
> npm run lint && webpack --config webpack.config.js "--output-path" "/home/pi/sdk_folder/ss-build/modules/GUI" "--define" "DISABLE_WEBSOCKET_SSL=true" "--define" "USE_UWP_CLIENT=false"


> gui@1.0.0 lint /home/pi/sdk_folder/alexa-smart-screen-sdk/modules/GUI/js
> tslint --project tsconfig.json -c tslint.json 'src/**/*.ts' 'src/**/*.tsx'

Hash: 76e98e21af18c4283865
Version: webpack 4.44.1
Time: 112044ms
Built at: 09/22/2020 9:27:49 PM
 34 assets
Entrypoint main = main.bundle.js
 [1] /home/pi/sdk_folder/alexa-smart-screen-sdk/modules/GUI/apl-client/index.js 607 KiB {0} [built]
 [4] ./lib/config/IDeviceAppConfig.ts 832 bytes {0} [built]
 [5] ./lib/messages/messages.ts 1.84 KiB {0} [built]
[10] ./lib/displayCards/AVSDisplayCardHelpers.ts 2.97 KiB {0} [built]
[11] ./main.tsx 563 bytes {0} [built]
[12] ./app.tsx 17.9 KiB {0} [built] [1 error]
[25] ./lib/messages/NavigationEvent.ts 671 bytes {0} [built]
[26] ./lib/messages/client.ts 3.53 KiB {0} [built]
[30] ./lib/messages/sdkLogTransport.ts 1.73 KiB {0} [built]
[31] ./lib/focus/FocusManager.ts 3.06 KiB {0} [built]
[32] ./lib/activity/ActivityTracker.ts 2.42 KiB {0} [built]
[37] ./lib/config/GuiConfigHelpers.ts 8.21 KiB {0} [built]
[38] ./lib/messages/UWPClient.ts 1.7 KiB {0} [built]
[46] ./main.css 1.05 KiB {0} [built]
[47] ../node_modules/css-loader/dist/cjs.js!./main.css 735 bytes {0} [built]
    + 33 hidden modules

ERROR in /home/pi/sdk_folder/alexa-smart-screen-sdk/modules/GUI/js/src/app.tsx
./app.tsx
[tsl] ERROR in /home/pi/sdk_folder/alexa-smart-screen-sdk/modules/GUI/js/src/app.tsx(144,9)
      TS2322: Type 'Timeout' is not assignable to type 'number'.
Child html-webpack-plugin for "index.html":
     1 asset
    Entrypoint undefined = index.html
       4 modules
npm ERR! code ELIFECYCLE
npm ERR! errno 2
npm ERR! gui@1.0.0 build: `npm run lint && webpack --config webpack.config.js "--output-path" "/home/pi/sdk_folder/ss-build/modules/GUI" "--define" "DISABLE_WEBSOCKET_SSL=true" "--define" "USE_UWP_CLIENT=false"`
npm ERR! Exit status 2
npm ERR! 
npm ERR! Failed at the gui@1.0.0 build script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     /home/pi/.npm/_logs/2020-09-22T19_27_50_037Z-debug.log
make[2]: *** [modules/GUI/CMakeFiles/GUIClient.dir/build.make:59: modules/GUI/CMakeFiles/GUIClient] Error 2
make[1]: *** [CMakeFiles/Makefile2:2468: modules/GUI/CMakeFiles/GUIClient.dir/all] Error 2
make: *** [Makefile:130: all] Error 2

builds only if changing type of lastCaptionTimeOutId from number to any (app.tsx)
seems wrong definition of setTimeout function get selected (nodejs setTimeout returns a Timeout object)

@chemudug-amzn
Copy link
Contributor

Thanks for trying it out, yes it's resolving it to the wrong namespace. Can you please print your nodejs version?

in the meanwhile, you an explicitly add window.setTimeout - which is the correct usage.

https://stackoverflow.com/questions/45802988/typescript-use-correct-version-of-settimeout-node-vs-window

@ulrich-berl
Copy link

Thanks for trying it out, yes it's resolving it to the wrong namespace. Can you please print your nodejs version?

v12.18.4

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

7 participants