Go Down

Topic: Error while attempting to use WiiClassicController code provided (Read 1 time) previous topic - next topic

coffeetablesex

http://www.arduino.cc/playground/Main/WiiClassicController

This just will not compile, I don't know what else I can do. I saved the library file provided into my library folder, I saved the sketch as a pde and attempted to upload it, and get a whole string of errors. I don't really know what else I can say, this is the exact code from the website copied and pasted, I'm using the current version of the program, and a fresh installation at that., and it will not compile what so ever. Please, someone help!
Quote










In file included from wiiclassic_demo.cpp:15:
C:\arduino-0022\arduino-0022\libraries\wiiclassic/WiiClassic.h:25: error: 'byte' does not name a type
C:\arduino-0022\arduino-0022\libraries\wiiclassic/WiiClassic.h:27: error: 'byte' does not name a type
C:\arduino-0022\arduino-0022\libraries\wiiclassic/WiiClassic.h:74: error: ISO C++ forbids declaration of 'byte' with no type
C:\arduino-0022\arduino-0022\libraries\wiiclassic/WiiClassic.h:74: error: expected ';' before '*' token
C:\arduino-0022\arduino-0022\libraries\wiiclassic/WiiClassic.h:78: error: expected `;' before 'byte'
C:\arduino-0022\arduino-0022\libraries\wiiclassic/WiiClassic.h:78: error: ISO C++ forbids declaration of 'byte' with no type
C:\arduino-0022\arduino-0022\libraries\wiiclassic/WiiClassic.h:78: error: expected ';' before '*' token
C:\arduino-0022\arduino-0022\libraries\wiiclassic/WiiClassic.h:82: error: expected `;' before 'boolean'
C:\arduino-0022\arduino-0022\libraries\wiiclassic/WiiClassic.h:82: error: 'boolean' does not name a type
C:\arduino-0022\arduino-0022\libraries\wiiclassic/WiiClassic.h:86: error: 'boolean' does not name a type
C:\arduino-0022\arduino-0022\libraries\wiiclassic/WiiClassic.h:90: error: 'boolean' does not name a type
C:\arduino-0022\arduino-0022\libraries\wiiclassic/WiiClassic.h:94: error: 'boolean' does not name a type
C:\arduino-0022\arduino-0022\libraries\wiiclassic/WiiClassic.h:98: error: 'boolean' does not name a type
C:\arduino-0022\arduino-0022\libraries\wiiclassic/WiiClassic.h:102: error: 'boolean' does not name a type
C:\arduino-0022\arduino-0022\libraries\wiiclassic/WiiClassic.h:106: error: 'boolean' does not name a type
C:\arduino-0022\arduino-0022\libraries\wiiclassic/WiiClassic.h:110: error: 'boolean' does not name a type
C:\arduino-0022\arduino-0022\libraries\wiiclassic/WiiClassic.h:114: error: 'boolean' does not name a type
C:\arduino-0022\arduino-0022\libraries\wiiclassic/WiiClassic.h:118: error: 'boolean' does not name a type
C:\arduino-0022\arduino-0022\libraries\wiiclassic/WiiClassic.h:122: error: 'boolean' does not name a type
C:\arduino-0022\arduino-0022\libraries\wiiclassic/WiiClassic.h:126: error: 'boolean' does not name a type
C:\arduino-0022\arduino-0022\libraries\wiiclassic/WiiClassic.h:130: error: 'boolean' does not name a type
C:\arduino-0022\arduino-0022\libraries\wiiclassic/WiiClassic.h:134: error: 'boolean' does not name a type
C:\arduino-0022\arduino-0022\libraries\wiiclassic/WiiClassic.h:138: error: 'boolean' does not name a type
C:\arduino-0022\arduino-0022\libraries\wiiclassic/WiiClassic.h:169: error: 'boolean' does not name a type
C:\arduino-0022\arduino-0022\libraries\wiiclassic/WiiClassic.h:175: error: 'byte' does not name a type
C:\arduino-0022\arduino-0022\libraries\wiiclassic/WiiClassic.h: In member function 'void WiiClassic::begin()':
C:\arduino-0022\arduino-0022\libraries\wiiclassic/WiiClassic.h:39: error: 'cnt' was not declared in this scope
C:\arduino-0022\arduino-0022\libraries\wiiclassic/WiiClassic.h:40: error: 'averageCounter' was not declared in this scope
C:\arduino-0022\arduino-0022\libraries\wiiclassic/WiiClassic.h: In member function 'void WiiClassic::update()':
C:\arduino-0022\arduino-0022\libraries\wiiclassic/WiiClassic.h:60: error: 'cnt' was not declared in this scope
C:\arduino-0022\arduino-0022\libraries\wiiclassic/WiiClassic.h:61: error: '_nunchuk_decode_byte' was not declared in this scope
C:\arduino-0022\arduino-0022\libraries\wiiclassic/WiiClassic.h:64: error: '_nunchuk_decode_byte' was not declared in this scope
C:\arduino-0022\arduino-0022\libraries\wiiclassic/WiiClassic.h:66: error: 'cnt' was not declared in this scope
C:\arduino-0022\arduino-0022\libraries\wiiclassic/WiiClassic.h:68: error: 'cnt' was not declared in this scope
wiiclassic_demo.cpp: In function 'void loop()':
wiiclassic_demo:62: error: 'class WiiClassic' has no member named 'leftShoulderPressed'
wiiclassic_demo:65: error: 'class WiiClassic' has no member named 'rightShoulderPressed'
wiiclassic_demo:68: error: 'class WiiClassic' has no member named 'lzPressed'
wiiclassic_demo:71: error: 'class WiiClassic' has no member named 'rzPressed'
wiiclassic_demo:74: error: 'class WiiClassic' has no member named 'leftDPressed'
wiiclassic_demo:78: error: 'class WiiClassic' has no member named 'rightDPressed'
wiiclassic_demo:82: error: 'class WiiClassic' has no member named 'upDPressed'
wiiclassic_demo:85: error: 'class WiiClassic' has no member named 'downDPressed'
wiiclassic_demo:89: error: 'class WiiClassic' has no member named 'selectPressed'
wiiclassic_demo:93: error: 'class WiiClassic' has no member named 'homePressed'
wiiclassic_demo:96: error: 'class WiiClassic' has no member named 'startPressed'
wiiclassic_demo:100: error: 'class WiiClassic' has no member named 'xPressed'
wiiclassic_demo:104: error: 'class WiiClassic' has no member named 'yPressed'
wiiclassic_demo:108: error: 'class WiiClassic' has no member named 'aPressed'
wiiclassic_demo:112: error: 'class WiiClassic' has no member named 'bPressed'

PaulS

Add:
Code: [Select]
#include <WProgram.h>
to WiiClassic.h, just before the Wire.h include.
The art of getting good answers lies in asking good questions.

coffeetablesex

thank you, that seems to have fixed that problem

now onto figuring out the rest of it

Go Up