UnicodeDecodeError: 'utf-8' codec can't decode byte 0x92 in position 2138: invalid start byte

Hi there,

I previously had an issue with header files not being detected and could not resolve it, so decided to reinstall the extensions for Visual Code and the Connect SDK itself.

I am now unable to build the code (the included samples as well).

Find below the error message for building.

Slight side question, but some of the header files are also not there for the sample code and I'm wondering if that's an issue with the SDK or the install (e.g. syscalls/atomic_c.h, syscalls/kernal.h)

Thanks in advance!

Windows 10, SDK 1.9.1

[1/156] Generating misc/generated/syscalls.json, misc/generated/struct_tags.json
FAILED: zephyr/misc/generated/syscalls.json zephyr/misc/generated/struct_tags.json 
cmd.exe /C "cd /D C:\nordicToolchain\myapps\i2c\build\zephyr && C:\nordicToolchain\v1.9.1\toolchain\opt\bin\python.exe C:/nordicToolchain/v1.9.1/zephyr/scripts/parse_syscalls.py --include C:/nordicToolchain/v1.9.1/zephyr/include --include C:/nordicToolchain/v1.9.1/zephyr/drivers --include C:/nordicToolchain/v1.9.1/zephyr/subsys/net --json-file C:/nordicToolchain/myapps/i2c/build/zephyr/misc/generated/syscalls.json --tag-struct-file C:/nordicToolchain/myapps/i2c/build/zephyr/misc/generated/struct_tags.json"
Traceback (most recent call last):
  File "C:/nordicToolchain/v1.9.1/zephyr/scripts/parse_syscalls.py", line 153, in <module>
    main()
  File "C:/nordicToolchain/v1.9.1/zephyr/scripts/parse_syscalls.py", line 132, in main
    syscalls, tagged = analyze_headers(args.include)
  File "C:/nordicToolchain/v1.9.1/zephyr/scripts/parse_syscalls.py", line 80, in analyze_headers
    contents = fp.read()
  File "codecs.py", line 322, in decode
UnicodeDecodeError: 'utf-8' codec can't decode byte 0x92 in position 2138: invalid start byte
ninja: build stopped: subcommand failed.
FATAL ERROR: command exited with status 1: 'c:\nordicToolchain\v1.9.1\toolchain\opt\bin\cmake.EXE' --build 'c:\nordicToolchain\myapps\i2c\build'

Parents
  • Hello, 

    When installing the nRF Connect SDK with our Toolchain Manager, the SDK and toolchain should be included. Please verify that is has been installed properly and that no firewall or VPN causes install issues.

    What sample are you trying to build? Are you able to build a standard sample e.g. zephyr\samples\basic\blinky or nrf\samples\bluetooth\peripheral_lbs? What device are you targeting? 

    Thanks. 

    Kind regards,
    Øyvind

  • I did a full uninstall of VS code, Connect SDK, Nordic Command Line, Python and CMake, plus the extensions in VS Code and reinstall following the guide on the Nordic Academy again.

    This has fixed the issue with building the default sample applications

    I think some of the VS Code recommended extensions may have cause issues (C/C++ extension pack, CMake Tools) or CMake on my system.

Reply
  • I did a full uninstall of VS code, Connect SDK, Nordic Command Line, Python and CMake, plus the extensions in VS Code and reinstall following the guide on the Nordic Academy again.

    This has fixed the issue with building the default sample applications

    I think some of the VS Code recommended extensions may have cause issues (C/C++ extension pack, CMake Tools) or CMake on my system.

Children
No Data
Related