ARMmbed / mbed-os-example-blinky

Blinky example for Mbed OS 6.0
Apache License 2.0
42 stars 157 forks source link

Ignoring hidapi: markers 'platform_system != "Linux"' don't match your environment #240

Closed symeonmattes closed 3 years ago

symeonmattes commented 3 years ago

Hi,

I'm running the command mbed compile -m EP_AGORA -t GCC_ARM --flash

and I receive:

[mbed] Working path "/home/symeon/Mbed Programs/EmbeddedPlannet/mbed-os-example-blinky" (program)
[mbed] WARNING: Missing Python modules were not auto-installed.
       The Mbed OS tools in this program require the following Python modules: six, idna, cryptography
       You can install all missing modules by running "pip install -r requirements.txt" in "/home/symeon/Mbed Programs/EmbeddedPlannet/mbed-os-example-blinky/mbed-os"
       On Posix systems (Linux, etc) you might have to switch to superuser account or use "sudo"
---
Could not find executable for GCC_ARM.
Currently set search path: No path set
[mbed] ERROR: "/usr/bin/python3" returned error.
       Code: 2
       Path: "/home/symeon/Mbed Programs/EmbeddedPlannet/mbed-os-example-blinky"
       Command: "/usr/bin/python3 -u /home/symeon/Mbed Programs/EmbeddedPlannet/mbed-os-example-blinky/mbed-os/tools/make.py -t GCC_ARM -m EP_AGORA --source . --build ./BUILD/EP_AGORA/GCC_ARM"
       Tip: You could retry the last command with "-v" flag for verbose output

Then I run sudo pip install -r mbed-os/requirements.txt

and I receive:

Ignoring hidapi: markers 'platform_system != "Linux"' don't match your environment
Ignoring pywin32: markers 'platform_system == "Windows"' don't match your environment
Ignoring wmi: markers 'platform_system == "Windows"' don't match your environment

I'm running python3, pip3 on

sudo lsb_release -a
No LSB modules are available.
Distributor ID: Debian
Description:    Debian GNU/Linux 10 (buster)
Release:    10
Codename:   buster
symeonmattes commented 3 years ago

I have managed to do the following:

sudo pip install -U -r requirements.txt

This installed the missing modules idna, cryptography, but not six. Then from requirments.txt I saw that "six==1.12.0" So I run

sudo pip install 'six==1.12.0' --ignore-installed

The ignore-installed was necessary otherwise I couldn't install it. Now what I receive with

mbed compile -m EP_AGORA -t GCC_ARM --flash

[mbed] Working path "/home/symeon/Mbed Programs/EmbeddedPlannet/mbed-os-example-blinky/mbed-os" (library)
[mbed] Program path "/home/symeon/Mbed Programs/EmbeddedPlannet/mbed-os-example-blinky"
Could not find executable for GCC_ARM.
Currently set search path: No path set
[mbed] ERROR: "/usr/bin/python3" returned error.
       Code: 2
       Path: "/home/symeon/Mbed Programs/EmbeddedPlannet/mbed-os-example-blinky/mbed-os"
       Command: "/usr/bin/python3 -u /home/symeon/Mbed Programs/EmbeddedPlannet/mbed-os-example-blinky/mbed-os/tools/make.py -t GCC_ARM -m EP_AGORA --source .. --build ../BUILD/EP_AGORA/GCC_ARM"
       Tip: You could retry the last command with "-v" flag for verbose output
symeonmattes commented 3 years ago

Ok...finally I've managed to make it work:

I downloaded the gcc compiler and I configured it by running:

mbed config --global GCC_ARM_PATH /gcc-arm-none-eabi-9-2019-q4-major/bin

Please fix also your documentation to include these commands as well because it took a while to understand what's going on

ciarmcom commented 3 years ago

Thank you for raising this detailed GitHub issue. I am now notifying our internal issue triagers. Internal Jira reference: https://jira.arm.com/browse/IOTOSM-2046

evedon commented 3 years ago

Hi @symeonmattes, Glad that you managed to install mbed cli and got the program to work. We do have documentation https://os.mbed.com/docs/mbed-os/v6.3/build-tools/install-and-set-up.html but I agree that the link is not easy to find.

evedon commented 3 years ago

@iriark01 Could you look into replacing https://os.mbed.com/docs/mbed-os/v6.3/quick-start/build-with-mbed-cli.html with https://os.mbed.com/docs/mbed-os/v6.3/build-tools/install-and-set-up.html as the quick start guide does not provide information to configure compiler location?

iriark01 commented 3 years ago

Do you still need to configure it when you use an installer?

0xc0170 commented 3 years ago

Closing as it has not been updated since the last year.

symeonmattes commented 3 years ago

Hi,

Sorry for my late reply, as I didn't notice the comment. Just in case somebody else has the same issue, actually it's a conflict of the pip library. I tried different things such as:

pip install -r mbed-os/requirements.txt

The idea is to uninstall the packages i.e.

pip uninstall six, idna, cryptography and then use this

pip install -r mbed-os/requirements.txt