Hi Leute,
bin noch neu hier und auch was den Raspberry Pi angeht kein Held.
Es geht um folgendes:
Ich programmiere meine Python-Files am Mac mit PiCharm und lade sie dann von der Software aus auf den Pi.
Nachdem Hello World etc. funktioniert hat möchte ich nun beginnen die GPIOs anzusteuern. Allerdings ist die nötige lib nicht installiert.
Nach Recherche im Internet kam ich auf folgende Command-Line, welche ich in das Terminal am Mac eingegeben habe:
[font="sans-serif"]
[/font]
[font="sans-serif"]Als Ausgabe bekomme ich aber folgenden Fehler:[/font]
[font="sans-serif"][font="Menlo"]Collecting RPI.GPIO[/font]
[/font]
[font="Menlo"] Downloading RPi.GPIO-0.6.2.tar.gz[/font]
[font="Menlo"]Installing collected packages: RPI.GPIO[/font]
[font="Menlo"] Running setup.py install for RPI.GPIO ... error[/font]
[font="Menlo"] Complete output from command /Library/Frameworks/Python.framework/Versions/2.7/Resources/http://Python.app/Contents/MacOS/Python -u -c "import setuptools, tokenize;__file__='/private/tmp/pip-build-sUk_gg/http://RPI.GPIO/setup.py';exec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))" install --record /tmp/pip-16NuPR-record/install-record.txt --single-version-externally-managed --compile:[/font]
[font="Menlo"] running install[/font]
[font="Menlo"] running build[/font]
[font="Menlo"] running build_py[/font]
[font="Menlo"] creating build[/font]
[font="Menlo"] creating build/lib.macosx-10.6-intel-2.7[/font]
[font="Menlo"] creating build/lib.macosx-10.6-intel-2.7/RPi[/font]
[font="Menlo"] copying RPi/__init__.py -> build/lib.macosx-10.6-intel-2.7/RPi[/font]
[font="Menlo"] creating build/lib.macosx-10.6-intel-2.7/RPi/GPIO[/font]
[font="Menlo"] copying RPi/GPIO/__init__.py -> build/lib.macosx-10.6-intel-2.7/RPi/GPIO[/font]
[font="Menlo"] running build_ext[/font]
[font="Menlo"] building 'RPi._GPIO' extension[/font]
[font="Menlo"] creating build/temp.macosx-10.6-intel-2.7[/font]
[font="Menlo"] creating build/temp.macosx-10.6-intel-2.7/source[/font]
[font="Menlo"] /usr/bin/clang -fno-strict-aliasing -fno-common -dynamic -arch i386 -arch x86_64 -g -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -I/Library/Frameworks/Python.framework/Versions/2.7/include/python2.7 -c source/py_gpio.c -o build/temp.macosx-10.6-intel-2.7/source/py_gpio.o[/font]
[font="Menlo"] source/py_gpio.c:87:4: error: function definition is not allowed here[/font]
[font="Menlo"] {[/font]
[font="Menlo"] ^[/font]
[font="Menlo"] source/py_gpio.c:143:10: warning: implicit declaration of function 'cleanup_one' is invalid in C99 [-Wimplicit-function-declaration][/font]
[font="Menlo"] cleanup_one();[/font]
[font="Menlo"] ^[/font]
[font="Menlo"] source/py_gpio.c:200:24: error: function definition is not allowed here[/font]
[font="Menlo"] int setup_one(void) {[/font]
[font="Menlo"] ^[/font]
[font="Menlo"] source/py_gpio.c:293:13: warning: implicit declaration of function 'setup_one' is invalid in C99 [-Wimplicit-function-declaration][/font]
[font="Menlo"] if (!setup_one())[/font]
[font="Menlo"] ^[/font]
[font="Menlo"] source/py_gpio.c:345:21: error: function definition is not allowed here[/font]
[font="Menlo"] int output(void) {[/font]
[font="Menlo"] ^[/font]
[font="Menlo"] source/py_gpio.c:419:18: error: called object type 'PyObject *' (aka 'struct _object *') is not a function or function pointer[/font]
[font="Menlo"] if (!output())[/font]
[font="Menlo"] ~~~~~~^[/font]
[font="Menlo"] source/py_gpio.c:475:18: error: called object type 'PyObject *' (aka 'struct _object *') is not a function or function pointer[/font]
[font="Menlo"] if (!output())[/font]
[font="Menlo"] ~~~~~~^[/font]
[font="Menlo"] 2 warnings and 5 errors generated.[/font]
[font="Menlo"] error: command '/usr/bin/clang' failed with exit status 1[/font]
[font="Menlo"] [/font]
[font="Menlo"] ----------------------------------------[/font]
[font="sans-serif"][font="Menlo"]Command "/Library/Frameworks/Python.framework/Versions/2.7/Resources/http://Python.app/Contents/MacOS/Python -u -c "import setuptools, tokenize;__file__='/private/tmp/pip-build-sUk_gg/http://RPI.GPIO/setup.py';exec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))" install --record /tmp/pip-16NuPR-record/install-record.txt --single-version-externally-managed --compile" failed with error code 1 in /private/tmp/pip-build-sUk_gg/http://RPI.GPIO/[/font][/font]
[font="sans-serif"][font="Menlo"]Könnt ihr mir weiterhelfen? [/font][/font]
[font="sans-serif"][font="Menlo"]Danke im Voraus![/font][/font]
[font="sans-serif"][font="Menlo"]T-Bird[/font][/font]