اطلاعیه

Collapse
No announcement yet.

برنامه نویسی GPIO رزبری پای با NetBeans به زبان C

Collapse
X
 
  • فیلتر
  • زمان
  • Show
Clear All
new posts

    برنامه نویسی GPIO رزبری پای با NetBeans به زبان C

    سلام
    من شروع به برنامه نویسی برای رزبری به زبان C در محیط NetBeans کردم ولی با مشکل مواجه شدم.
    نمیدونم خطایی که میگیره مربوط به چیه .متن پیغام رو کامل میزارم تا اگه شد دوستان راهنمایی کنند.
    با تشکر

    Copying project files to /root/.netbeans/remote/192.168.1.3/mahzak-Windows-x86 at root@192.168.1.3
    Building project files list...
    Checking directory structure...
    Checking previously uploaded files...
    Checking links...
    Uploading changed files:
    Checking exec permissions...
    Uploading changed files finished successfully.


    cd '/root/.netbeans/remote/192.168.1.3/mahzak-Windows-x86/C/Users/mahzak/Documents/NetBeansProjects/test'
    /usr/bin/make -f Makefile CONF=Debug
    make: Warning: File 'nbproject/private/Makefile-variables.mk' has modification time 904473 s in the future
    "/usr/bin/make" -f nbproject/Makefile-Debug.mk QMAKE= SUBPROJECTS= .build-conf
    make[1]: Entering directory '/root/.netbeans/remote/192.168.1.3/mahzak-Windows-x86/C/Users/mahzak/Documents/NetBeansProjects/test'
    make[1]: Warning: File 'nbproject/private/Makefile-variables.mk' has modification time 904473 s in the future
    "/usr/bin/make" -f nbproject/Makefile-Debug.mk dist/Debug/GNU-Linux/test
    make[2]: Entering directory '/root/.netbeans/remote/192.168.1.3/mahzak-Windows-x86/C/Users/mahzak/Documents/NetBeansProjects/test'
    make[2]: Warning: File 'nbproject/private/Makefile-variables.mk' has modification time 904473 s in the future
    mkdir -p build/Debug/GNU-Linux
    rm -f "build/Debug/GNU-Linux/main.o.d"
    gcc -c -g -MMD -MP -MF "build/Debug/GNU-Linux/main.o.d" -o build/Debug/GNU-Linux/main.o main.c
    mkdir -p dist/Debug/GNU-Linux
    gcc -o dist/Debug/GNU-Linux/test build/Debug/GNU-Linux/main.o
    build/Debug/GNU-Linux/main.o: In function `main':
    /root/.netbeans/remote/192.168.1.3/mahzak-Windows-x86/C/Users/mahzak/Documents/NetBeansProjects/test/main.c undefined reference to `wiringPiSetupGpio'
    /root/.netbeans/remote/192.168.1.3/mahzak-Windows-x86/C/Users/mahzak/Documents/NetBeansProjects/test/main.c undefined reference to `pinMode'
    /root/.netbeans/remote/192.168.1.3/mahzak-Windows-x86/C/Users/mahzak/Documents/NetBeansProjects/test/main.c undefined reference to `digitalWrite'
    /root/.netbeans/remote/192.168.1.3/mahzak-Windows-x86/C/Users/mahzak/Documents/NetBeansProjects/test/main.c undefined reference to `delay'
    /root/.netbeans/remote/192.168.1.3/mahzak-Windows-x86/C/Users/mahzak/Documents/NetBeansProjects/test/main.c undefined reference to `digitalWrite'
    collect2: error: ld returned 1 exit status
    nbproject/Makefile-Debug.mk:62: recipe for target 'dist/Debug/GNU-Linux/test' failed
    make[2]: *** [dist/Debug/GNU-Linux/test] Error 1
    make[2]: Leaving directory '/root/.netbeans/remote/192.168.1.3/mahzak-Windows-x86/C/Users/mahzak/Documents/NetBeansProjects/test'
    nbproject/Makefile-Debug.mk recipe for target '.build-conf' failed
    make[1]: *** [.build-conf] Error 2
    make[1]: Leaving directory '/root/.netbeans/remote/192.168.1.3/mahzak-Windows-x86/C/Users/mahzak/Documents/NetBeansProjects/test'
    nbproject/Makefile-impl.mk recipe for target '.build-impl' failed
    make: *** [.build-impl] Error 2


    BUILD FAILED (exit value 2, total time: 695ms)

    #2
    پاسخ : برنامه نویسی GPIO رزبری پای با NetBeans به زبان C

    سلام
    خطا که میگه ماله نشناختن کتابخونه wiring pi هست
    الان باهاش ریموت زدین رو رزبری میخواین کامپایل کنین؟

    دیدگاه


      #3
      پاسخ : برنامه نویسی GPIO رزبری پای با NetBeans به زبان C

      سلام
      به احتمال زیاد شما کتابخانه wiringPi را به پروژه به اصطلاح لینک نکردید.
      روی پروژه راست کلیک کنید و بعد properties رو بزنید در قسمت linker جلوی فیل additional options عبارت -lwiringPi را وارد کنید.
      البته توجه کنید که بایستی این کتابخانه از قبل روی رزپبری نصب باشه

      دیدگاه


        #4
        پاسخ : برنامه نویسی GPIO رزبری پای با NetBeans به زبان C

        از Windows 10 IOT استفاده کنید و با سی شارپ به راحتی برنامه خودتون رو بنویسید
        مدت زمانی که صرف ایجاد تاپیک و منتظر پاسخ هستید را صرف سرچ کنید...

        دیدگاه

        لطفا صبر کنید...
        X