Pages: [1]   Go Down
Author Topic: Compile problem  (Read 706 times)
0 Members and 1 Guest are viewing this topic.
Offline Offline
Newbie
*
Karma: 0
Posts: 1
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Hi,

I'm having 6 problems when compiling my sketch.

http://pastebin.com/P3N6cHur

Errors:
timesharing:19: error: variable or field 'blink_red' declared void
timesharing:19: error: 'TaskManager' was not declared in this scope
timesharing:19: error: 'tm' was not declared in this scope
timesharing:20: error: variable or field 'blink_yellow' declared void
timesharing:20: error: 'TaskManager' was not declared in this scope
timesharing:20: error: 'tm' was not declared in this scope


Any sugestion? Help! smiley
Logged

Seattle, WA USA
Offline Offline
Brattain Member
*****
Karma: 644
Posts: 50512
Seattle, WA USA
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Quote
Any sugestion?
Yes. This is not C#. You can, and should, have separate files for the class declaration and class implementation.

You should have a total of 5 files - Task.h, Task.cpp, TaskManager.h, TaskManager..cpp, and the sketch.

Then, the compiler will tell you line numbers within files that are a lot easier to understand.

When you define a callback function, you have to define the number and types of arguments that the function takes, and the type of return value that it returns. Your actual function then needs to have that same signature. You are not properly defining the callback function signature, so you actual functions do not match that signature.

Logged

Pages: [1]   Go Up
Jump to: