annuncio

Comprimi
Ancora nessun annuncio.

aiuto su arduino uno e codice multiwii

Comprimi
X
  • Filtro
  • Ora
  • Visualizza
Elimina tutto
nuovi messaggi

  • aiuto su arduino uno e codice multiwii

    Buongiorno a tutti, sono Simone e sono nuovo sul sito, in realtà è già un po che ci bazzico per trovare una soluzione al mio problema. Sono da qualche tempo impegnato nella costruzione di un quadricottero, non ho avuto molti problemi nel creare il frame, montare i motori e assemblare insieme un nunchuck e wii motion plus (per ottenere i sensori per la stabilità). Ho già anche settato il mio file config.h con le specifiche del mio multicopter ma niente, al momento di caricare il programma sulla scheda mi appaiono diversi errori..

    se lancio il config.h ottengo come risposta: errore nella libreria main che è di base installata con arduino.

    se invece lancio il MultiWiiConf.pde come fanno vedere in diverse guide ottengo questa serie di errori:

    sketch_feb06a:1458: error: stray '#' in program
    sketch_feb06a:1563: error: integer constant is too large for 'long' type
    sketch_feb06a:-1: error: expected ',' or '...' before 'names'
    sketch_feb06a:-1: error: expected unqualified-id before 'public'
    sketch_feb06a:-1: error: expected unqualified-id before 'public'
    sketch_feb06a:-1: error: expected unqualified-id before 'public'
    sketch_feb06a:-1: error: expected unqualified-id before 'public'
    sketch_feb06a:-1: error: expected unqualified-id before 'public'
    sketch_feb06a:-1: error: expected unqualified-id before 'public'
    sketch_feb06a:-1: error: expected unqualified-id before 'public'
    sketch_feb06a:-1: error: expected unqualified-id before 'public'
    sketch_feb06a:-1: error: expected unqualified-id before 'public'
    sketch_feb06a:-1: error: expected unqualified-id before 'public'
    sketch_feb06a:-1: error: expected unqualified-id before 'public'
    sketch_feb06a:-1: error: expected unqualified-id before 'public'
    sketch_feb06a:-1: error: expected unqualified-id before 'public'
    sketch_feb06a:-1: error: expected unqualified-id before 'public'
    sketch_feb06a:-1: error: expected unqualified-id before 'public'
    sketch_feb06a:-1: error: expected unqualified-id before 'public'
    sketch_feb06a:-1: error: expected unqualified-id before 'public'
    sketch_feb06a:0: error: expected unqualified-id before 'public'
    sketch_feb06a:1: error: 'import' does not name a type
    sketch_feb06a:2: error: 'import' does not name a type
    sketch_feb06a:3: error: 'import' does not name a type
    sketch_feb06a:4: error: 'import' does not name a type
    sketch_feb06a:5: error: 'import' does not name a type
    sketch_feb06a:6: error: 'import' does not name a type
    sketch_feb06a:7: error: 'import' does not name a type
    sketch_feb06a:8: error: 'import' does not name a type
    sketch_feb06a:12: error: 'Serial' does not name a type
    sketch_feb06a:13: error: 'ControlP5' does not name a type
    sketch_feb06a:14: error: 'Textlabel' does not name a type
    sketch_feb06a:15: error: 'ListBox' does not name a type
    sketch_feb06a:21: error: 'cGraph' does not name a type
    sketch_feb06a:39: error: initializer fails to determine size of 'byteMP'
    sketch_feb06a:41: error: 'cDataArray' does not name a type
    sketch_feb06a:47: error: expected unqualified-id before 'private'
    sketch_feb06a:49: error: 'Numberbox' does not name a type
    sketch_feb06a:50: error: initializer fails to determine size of 'byteP'
    sketch_feb06a:50: error: initializer fails to determine size of 'byteI'
    sketch_feb06a:50: error: initializer fails to determine size of 'byteD'
    sketch_feb06a:52: error: 'Numberbox' does not name a type
    sketch_feb06a:56: error: 'Slider' does not name a type
    sketch_feb06a:58: error: 'Slider' does not name a type
    sketch_feb06a:62: error: 'Slider' does not name a type
    sketch_feb06a:65: error: 'Slider' does not name a type
    sketch_feb06a:67: error: 'Button' does not name a type
    sketch_feb06a:70: error: 'Toggle' does not name a type
    sketch_feb06a:73: error: 'color' does not name a type
    sketch_feb06a:88: error: initializer fails to determine size of 'mot'
    sketch_feb06a:89: error: initializer fails to determine size of 'servo'
    sketch_feb06a:95: error: 'CheckBox' does not name a type
    sketch_feb06a:96: error: storage size of 'activation' isn't known
    sketch_feb06a:98: error: 'Button' does not name a type
    sketch_feb06a:99: error: 'PFont' does not name a type
    sketch_feb06a:101: error: expected ',' or '...' before 'names'
    sketch_feb06a.cpp: In function 'void create_checkboxes(String*)':
    sketch_feb06a:104: error: 'buttonCheckbox' was not declared in this scope
    sketch_feb06a:105: error: 'checkbox' was not declared in this scope
    sketch_feb06a:109: error: 'checkbox' was not declared in this scope
    sketch_feb06a:109: error: expected type-specifier before 'CheckBox'
    sketch_feb06a:109: error: expected `;' before 'CheckBox'
    sketch_feb06a:110: error: 'buttonCheckbox' was not declared in this scope
    sketch_feb06a:110: error: expected type-specifier before 'Button'
    sketch_feb06a:110: error: expected `;' before 'Button'
    sketch_feb06a:111: error: 'names' was not declared in this scope
    sketch_feb06a:112: error: a function-definition is not allowed here before ':' token
    sketch_feb06a:124: error: expected primary-expression before '}' token
    sketch_feb06a:124: error: expected `)' before '}' token
    sketch_feb06a:124: error: expected primary-expression before '}' token
    sketch_feb06a:124: error: expected `;' before '}' token
    sketch_feb06a.cpp: At global scope:
    sketch_feb06a:137: error: expected constructor, destructor, or type conversion before '.' token
    sketch_feb06a.cpp: In function 'void setup()':
    sketch_feb06a:144: error: 'OPENGL' was not declared in this scope
    sketch_feb06a:144: error: 'size' was not declared in this scope
    sketch_feb06a:145: error: 'frameRate' was not declared in this scope
    sketch_feb06a:147: error: 'font8' was not declared in this scope
    sketch_feb06a:147: error: 'createFont' was not declared in this scope
    sketch_feb06a:148: error: 'font9' was not declared in this scope
    sketch_feb06a:149: error: 'font12' was not declared in this scope
    sketch_feb06a:150: error: 'font15' was not declared in this scope
    sketch_feb06a:152: error: 'controlP5' was not declared in this scope
    sketch_feb06a:152: error: expected type-specifier before 'ControlP5'
    sketch_feb06a:152: error: expected `;' before 'ControlP5'
    sketch_feb06a:155: error: 'g_graph' was not declared in this scope
    sketch_feb06a:155: error: expected type-specifier before 'cGraph'
    sketch_feb06a:155: error: expected `;' before 'cGraph'
    sketch_feb06a:156: error: 'commListbox' was not declared in this scope
    sketch_feb06a:159: error: 'red_' was not declared in this scope
    sketch_feb06a:160: error: 'class HardwareSerial' has no member named 'list'
    sketch_feb06a:161: error: 'class HardwareSerial' has no member named 'list'
    sketch_feb06a:167: error: 'txtlblWhichcom' was not declared in this scope
    sketch_feb06a:169: error: 'buttonSAVE' was not declared in this scope
    sketch_feb06a:170: error: 'buttonIMPORT' was not declared in this scope
    sketch_feb06a:172: error: 'buttonSTART' was not declared in this scope
    sketch_feb06a:173: error: 'buttonSTOP' was not declared in this scope
    sketch_feb06a:175: error: 'buttonAcc' was not declared in this scope
    sketch_feb06a:176: error: 'buttonBaro' was not declared in this scope
    sketch_feb06a:177: error: 'buttonMag' was not declared in this scope
    sketch_feb06a:178: error: 'buttonGPS' was not declared in this scope
    sketch_feb06a:179: error: 'buttonSonar' was not declared in this scope
    sketch_feb06a:180: error: 'buttonOptic' was not declared in this scope
    sketch_feb06a:180: error: 'grey_' was not declared in this scope
    sketch_feb06a:182: error: 'color' was not declared in this scope
    sketch_feb06a:182: error: expected `;' before 'c'
    sketch_feb06a:183: error: 'black' was not declared in this scope
    sketch_feb06a:194: error: 'tACC_ROLL' was not declared in this scope
    sketch_feb06a:195: error: 'tACC_PITCH' was not declared in this scope
    sketch_feb06a:196: error: 'tACC_Z' was not declared in this scope
    sketch_feb06a:197: error: 'tGYRO_ROLL' was not declared in this scope
    sketch_feb06a:198: error: 'tGYRO_PITCH' was not declared in this scope
    sketch_feb06a:199: error: 'tGYRO_YAW' was not declared in this scope
    sketch_feb06a:200: error: 'tBARO' was not declared in this scope
    sketch_feb06a:201: error: 'tHEAD' was not declared in this scope
    sketch_feb06a:202: error: 'tMAGX' was not declared in this scope
    sketch_feb06a:203: error: 'tMAGY' was not declared in this scope
    sketch_feb06a:204: error: 'tMAGZ' was not declared in this scope
    sketch_feb06a:205: error: 'tDEBUG1' was not declared in this scope
    sketch_feb06a:206: error: 'tDEBUG2' was not declared in this scope
    sketch_feb06a:207: error: 'tDEBUG3' was not declared in this scope
    sketch_feb06a:208: error: 'tDEBUG4' was not declared in this scope
    sketch_feb06a:229: error: 'axSlider' was not declared in this scope
    sketch_feb06a:230: error: 'aySlider' was not declared in this scope
    sketch_feb06a:231: error: 'azSlider' was not declared in this scope
    sketch_feb06a:232: error: 'gxSlider' was not declared in this scope
    sketch_feb06a:233: error: 'gySlider' was not declared in this scope
    sketch_feb06a:234: error: 'gzSlider' was not declared in this scope
    sketch_feb06a:235: error: 'altSlider' was not declared in this scope
    sketch_feb06a:236: error: 'headSlider' was not declared in this scope
    sketch_feb06a:237: error: 'magxSlider' was not declared in this scope
    sketch_feb06a:238: error: 'magySlider' was not declared in this scope
    sketch_feb06a:239: error: 'magzSlider' was not declared in this scope
    sketch_feb06a:240: error: 'debug1Slider' was not declared in this scope
    sketch_feb06a:241: error: 'debug2Slider' was not declared in this scope
    sketch_feb06a:242: error: 'debug3Slider' was not declared in this scope
    sketch_feb06a:243: error: 'debug4Slider' was not declared in this scope
    sketch_feb06a:246: error: 'confP' was not declared in this scope
    sketch_feb06a:246: error: expected `;' before 'hideLabel'
    sketch_feb06a:247: error: 'Controller' was not declared in this scope
    sketch_feb06a:248: error: 'confI' was not declared in this scope
    sketch_feb06a:248: error: expected `;' before 'hideLabel'
    sketch_feb06a:250: error: 'confD' was not declared in this scope
    sketch_feb06a:250: error: expected `;' before 'hideLabel'
    sketch_feb06a:254: error: 'confI' was not declared in this scope
    sketch_feb06a:254: error: 'confD' was not declared in this scope
    sketch_feb06a:255: error: 'confP' was not declared in this scope
    sketch_feb06a:268: error: 'rollPitchRate' was not declared in this scope
    sketch_feb06a:268: error: expected `;' before 'hideLabel'
    sketch_feb06a:269: error: 'Controller' was not declared in this scope
    sketch_feb06a:270: error: 'yawRate' was not declared in this scope
    sketch_feb06a:270: error: expected `;' before 'hideLabel'
    sketch_feb06a:272: error: 'dynamic_THR_PID' was not declared in this scope
    sketch_feb06a:272: error: expected `;' before 'hideLabel'
    sketch_feb06a:275: error: 'confRC_RATE' was not declared in this scope
    sketch_feb06a:277: error: 'confRC_EXPO' was not declared in this scope
    sketch_feb06a:280: error: 'confSetting' was not declared in this scope
    sketch_feb06a:283: error: 'confSelectSetting' was not declared in this scope
    sketch_feb06a:286: error: 'throttle_MID' was not declared in this scope
    sketch_feb06a:288: error: 'throttle_EXPO' was not declared in this scope
    sketch_feb06a:291: error: 'buttonREAD' was not declared in this scope
    sketch_feb06a:292: error: 'buttonRESET' was not declared in this scope
    sketch_feb06a:293: error: 'buttonWRITE' was not declared in this scope
    sketch_feb06a:294: error: 'buttonCALIBRATE_ACC' was not declared in this scope
    sketch_feb06a:295: error: 'buttonCALIBRATE_MAG' was not declared in this scope
    sketch_feb06a:296: error: 'buttonSETTING' was not declared in this scope
    sketch_feb06a:298: error: 'rcStickThrottleSlider' was not declared in this scope
    sketch_feb06a:299: error: 'rcStickPitchSlider' was not declared in this scope
    sketch_feb06a:300: error: 'rcStickRollSlider' was not declared in this scope
    sketch_feb06a:301: error: 'rcStickYawSlider' was not declared in this scope
    sketch_feb06a:302: error: 'rcStickAUX1Slider' was not declared in this scope
    sketch_feb06a:303: error: 'rcStickAUX2Slider' was not declared in this scope
    sketch_feb06a:304: error: 'rcStickAUX3Slider' was not declared in this scope
    sketch_feb06a:305: error: 'rcStickAUX4Slider' was not declared in this scope
    sketch_feb06a:308: error: 'motSlider' was not declared in this scope
    sketch_feb06a:309: error: 'servoSliderH' was not declared in this scope
    sketch_feb06a:310: error: 'servoSliderV' was not declared in this scope
    sketch_feb06a:313: error: 'scaleSlider' was not declared in this scope
    sketch_feb06a:315: error: 'confPowerTrigger' was not declared in this scope
    sketch_feb06a.cpp: At global scope:
    sketch_feb06a:322: error: expected unqualified-id before 'private'
    sketch_feb06a:324: error: expected unqualified-id before 'private'
    sketch_feb06a:363: error: expected unqualified-id before 'public'
    sketch_feb06a:373: error: 'IDLE' was not declared in this scope
    sketch_feb06a:379: error: expected unqualified-id before '[' token
    sketch_feb06a.cpp: In function 'int read32()':
    sketch_feb06a:383: error: 'inBuf' was not declared in this scope
    sketch_feb06a.cpp: In function 'int read16()':
    sketch_feb06a:384: error: 'inBuf' was not declared in this scope
    sketch_feb06a.cpp: In function 'int read8()':
    sketch_feb06a:385: error: 'inBuf' was not declared in this scope
    sketch_feb06a.cpp: At global scope:
    sketch_feb06a:391: error: expected unqualified-id before 'private'
    sketch_feb06a:396: error: expected unqualified-id before 'private'
    Errore alla linea: -1


    non riesco a capire come sia possibile visto che ho scaricato il codice dalla piattaforma multiwii.

    sono accettati consigli e rimproveri!! XD

    ovviamente avrete capito che sono un neofita in questo campo ma sono molto interessato e vorrei terminare il mio progetto. Gradirei qualche aiuto se possibile grazie in anticipo

  • #2
    Occhio che MultiWiiConf.pde NON è un file compilabile con l'IDE di Arduino, ma è un file che contiene il codice scritto in Processing che riguarda la consolle di configurazione di MultiWii. Il relativo .exe lo trovi nella stessa cartella MultiWiiConf.

    Per la compilazione di MultiWii.ino devi avere una cartella che contiene tutti i file .ino, solitamente denominata MultiWii e basta. All'interno di quella cartella c'è MultiWii.ino che deve essere aperto facendo click destro->Apri.
    All'apertura dell'IDE ti troverai delle Tab. contenenti i rispettivi .ino presenti nella cartella indicata.

    Poi configuri il file config.h per rispecchiare il tu hardware e le funzionalità che ti interessano

    Prima leggiti bene bene le informazioni che trovi nella discussione specifica multiwii-guide-e-documentazione
    Giovanni

    Commenta


    • #3
      Per ora grazie mille guardo le guide e appena posso riprovo. Grazie ancora buona serata

      Commenta


      • #4
        Originariamente inviato da QuercusPetraea Visualizza il messaggio
        Occhio che MultiWiiConf.pde NON è un file compilabile con l'IDE di Arduino, ma è un file che contiene il codice scritto in Processing che riguarda la consolle di configurazione di MultiWii. Il relativo .exe lo trovi nella stessa cartella MultiWiiConf.

        Per la compilazione di MultiWii.ino devi avere una cartella che contiene tutti i file .ino, solitamente denominata MultiWii e basta. All'interno di quella cartella c'è MultiWii.ino che deve essere aperto facendo click destro->Apri.
        All'apertura dell'IDE ti troverai delle Tab. contenenti i rispettivi .ino presenti nella cartella indicata.

        Poi configuri il file config.h per rispecchiare il tu hardware e le funzionalità che ti interessano

        Prima leggiti bene bene le informazioni che trovi nella discussione specifica multiwii-guide-e-documentazione



        scusa, mi sono scervellato fino ad ora, ho lanciato tramite arduino il multiwii.ino come dicevi tu, e infatti ha subito richiamato tutte le librerie ed i file.ino presenti nella cartella. ora ho lo stesso problema che eseguendo lo sketch mi continua a dare tantissimi errori nel sensor.ino anche relative a cose che ho già disabilitato nel config.h (es il gps che io non ho).

        in questo caso cosa potrei provare a fare?

        intanto continuo a cercare guide su guide ma nessuna parla di questo passaggio visto che è molto soggettivo per ogni multicopter.

        Grazie, Simone

        Commenta


        • #5
          Buone notizie, sono appena riuscito a risolvere ho scaricato una versione più vecchia la 2.0 che a quanto ho visto è la più stabile per quanto riguarda il codice, sono riuscito a compilare e caricare su arduino. la GUI rileva correttamente il quad, ora devo solo più capire perchè non rileva i movimenti ma probabilmente è un problema hardware, domani controllerò, per adesso ancora tante grazie

          Commenta


          • #6
            come proseguire?

            Scusami, anche io ho caricato il firmware modificando il codice , ho caricato multiwii 2.1 ed è andato tutto ok. Ma tu dopo aver fatto il firmware cos'hai fatto ... ?? Devo usare il programma multiwiiconf???? Io ho caricato solo il firmware il la centralina si illumina ed emette anche il buzzer, ma i motori non si armano. Come mai???

            Commenta

            Sto operando...
            X