ugui error with Arduino IDE / teensy 3.2

Hello,

with raspberry pi 3 and raspbian I implemented follow ugui without problems:

but now with Arduino IDE/teensy and after #include "ugui.c" I get follow error:

\ugui.c: In function 'void _UG_PutChar(char, UG_S16, UG_S16, UG_COLOR, UG_COLOR, const UG_FONT*)':

\ugui.c:5291:100: error: invalid conversion from 'void*' to 'void ()(UG_COLOR) {aka void ()(short unsigned int)}' [-fpermissive]

push_pixel = ((void*(*)(UG_S16, UG_S16, UG_S16, UG_S16))gui->driver[DRIVER_FILL_AREA].driver)(x,y,x+actual_char_width-1,y+font->char_height-1);

whats wrong??

whats wrong??

You didn’t post ALL of your code.
You failed to use tags when posting code.

Why are you including a C file? You normally include .h files.

Why are you including a C file? You normally include .h files.

Because it's much code, and you can find the code also here (Please note: I have also the same problem if copy all the ugui.c code in the sketch):

my programm/sketch looks as follow:

#include "ugui.c"

void setup() {
//UG_GUI gui;
pinMode(21, OUTPUT);
reset();
}

void reset(void)
{
digitalWrite(21,HIGH);
delay(1000);
digitalWrite(21,LOW);
delay(1000);
digitalWrite(21,HIGH);
}

void loop() {
delay(1000);
digitalWrite(21,HIGH);
}

Error:

ugui.c: In function 'void _UG_PutChar(char, UG_S16, UG_S16, UG_COLOR, UG_COLOR, const UG_FONT*)':
ugui.c:5291: error: invalid conversion from 'void*' to 'void ()(UG_COLOR) {aka void ()(short unsigned int)}' [-fpermissive]
push_pixel = ((void*(*)(UG_S16, UG_S16, UG_S16, UG_S16))gui->driver[DRIVER_FILL_AREA].driver)(x,y,x+actual_char_width-1,y+font->char_height-1);

? nobody an idea?

?

Hi,
i get the same issue when trying to use uGUI with Teensy 3.2,

i have made sure i am using the sytax: #include "ugui.h" as opposed to "ugui.c"
and i have the same issue that is thrown up, ive found that part of the issue is caused by the put_string command which seems to not be compliant with C++ ??

as I can see now and in other forums (e.g. pjrc forum) I am not the only one who want make work ugui with arduino/teensy.

ugui is a very helpful and an easy GUI.
And it's very easy to write driver etc.

So is there any c/c++ crack which could explain, help us with the above problem??