Pages: [1]   Go Down
Author Topic: [ANN] LCDUI : Operator interface with 5-button LCD display  (Read 1831 times)
0 Members and 1 Guest are viewing this topic.
Offline Offline
Newbie
*
Karma: 0
Posts: 7
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

A new library to handle "stand alone" a complete user interface with menu's, input/output fields, navigation, editing (with input validation e.g. a date entry for February 2012 has 29 days, 2013 has 28 days, seconds limited to 59,...). Also alarm clock functionality is built in.
Developed for 2 x 16 chars (configurable) LCD with 5 push buttons.
Examples are provided, as is a test suite (uses ArduinoUnit).

Download at -> http://users.skynet.be/adrias/Arduino/index.html <-

Comments welcome ,

Wim
Logged

alabama
Offline Offline
Full Member
***
Karma: 1
Posts: 183
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Wim,
Got the library installed, installed ArduinUnit library, still can't get any examples to compile.
Errors abound

In file included from C:\Users\Tom\Documents\Arduino\libraries\LcdUi/utility/LcdEdit.h:38,
                 from C:\Users\Tom\Documents\Arduino\libraries\LcdUi/utility/LcdFields.h:38,
                 from C:\Users\Tom\Documents\Arduino\libraries\LcdUi/utility/LcdMenu.h:38,
                 from C:\Users\Tom\Documents\Arduino\libraries\LcdUi/utility/LcdMenus.h:38,
                 from C:\Users\Tom\Documents\Arduino\libraries\LcdUi/LcdUi.h:36,
                 from lcdui.ino:32:
C:\Users\Tom\Documents\Arduino\libraries\LcdUi/utility/LcdString.h:44: error: expected ',' or '...' before numeric constant
C:\Users\Tom\Documents\Arduino\libraries\LcdUi/utility/LcdString.h:46: error: expected ',' or '...' before numeric constant
C:\Users\Tom\Documents\Arduino\libraries\LcdUi/utility/LcdString.h:48: error: expected ',' or '...' before numeric constant
C:\Users\Tom\Documents\Arduino\libraries\LcdUi/utility/LcdString.h:50: error: expected ',' or '...' before numeric constant

I get the same errors in every example, plus more in most that could be caused by these.
Any solutions?  I am afraid to mess with the library on my own, just starting to understand them a little bit.
Sorry about the cut and paste, I can't figure out how to include the formating for errors.
Thanks
TomJ

Logged

Einstein once said you don't really understand anything until you can explain it to your Grandmother

Offline Offline
Newbie
*
Karma: 0
Posts: 7
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Hmm, it works here.

The common factor in the errormessages is the definition "PGM_P".

Now I'm neither an expert nor a long time user of Arduino, but it's only recently that this definition is included in <arduino.h> (in LcdUi.h).

So :
- do you have a recent version (> 1.0) of Arduino installed ?
- did you install the library as per the instructions on http://arduino.cc/en/Guide/Libraries ?
- does the library and the examples show up in Arduino (menu : File > examples) ?

Hope this helps, if not please post the answers to above questions

Wim
Logged

alabama
Offline Offline
Full Member
***
Karma: 1
Posts: 183
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

WM'
Woke up in the night thinking I should have included that info:

Arduino 1.0.3 and 1.0.1 tried

Both libraries installed in the sketchbook/ libraries folder  (that way easily updated between versions)

Both show up in Arduino, color from keyword files are correct, examples show up, and in "import library"

I ran the sample test program for ArduioUnit.h on their webpage and it worked fine.


arduino.h is in lots of places, but most importantly in Arduino1.0.3/hardware/arduino/cores/arduino/arduino.h

Probably some small thing, but would really like this library to work with keypad/lcds.
Thanks for your time,
TomJ
Logged

Einstein once said you don't really understand anything until you can explain it to your Grandmother

Offline Offline
Newbie
*
Karma: 0
Posts: 7
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

OK, I did something stupid...  I changed the name of the library zip-file from LcdUi to LCDUI...  Depending of the platform you are on this might give problems ? Can you check if the library is in "LcdUi" (as it should be) ?
To be entirely honest I already tried playing with the case on my PC (MacBook Pro) and for me they all seem to work, but who knows.

Wim

ps.: I'm going to try to reinstall Arduino and follow the same procedure to install the library, see what happens (that'll be tonight...)
Logged

Offline Offline
Newbie
*
Karma: 0
Posts: 7
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

I have been playing with settings, removing Arduino, reinstalling, unzipping the library file,...  Everything works every time.
I hope you are using the Arduino Uno ?  The Due is not compatible...

Wim
Logged

alabama
Offline Offline
Full Member
***
Karma: 1
Posts: 183
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Wim,
Yep, using a Uno, thought maybe my download was corrupt, tried to re-download following your links again and the file couldn't be found. Tried a different extraction tool on the old .zip, it didn't help either.
I will keep trying the download tomorrow.
TomJ
Logged

Einstein once said you don't really understand anything until you can explain it to your Grandmother

Offline Offline
Newbie
*
Karma: 0
Posts: 7
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

OK, the download should be available again.

On the forum is a thread "h:16: error: expected ',' or '...' before numeric" which might indicate that PGM_P or DATA has been redefined somewhere ?

Further : since the problem seems to be with PGM_P, you might try below code (adapted from an example in http://www.nongnu.org/avr-libc/user-manual/FAQ.html#faq_rom_array).
Should work with the <arduino.h> include as well as with the <avr/pgmspace.h>


//#include <avr/pgmspace.h>
#include <arduino.h>

const char foo[] PROGMEM = "Foo";
const char bar[] PROGMEM = "Bar";

PGM_P array[2] PROGMEM = {
    foo,
    bar
};

char buf[32];

void setup()          
{
  Serial.begin(9600);
}


void loop()          
{
    PGM_P p;
    memcpy_P(&p, &array[0], sizeof(PGM_P));
    strcpy_P(buf, p);
    Serial.println(buf);
    memcpy_P(&p, &array[1], sizeof(PGM_P));
    strcpy_P(buf, p);
    Serial.println(buf);
    delay(1000);
}

Wim
Logged

alabama
Offline Offline
Full Member
***
Karma: 1
Posts: 183
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Wim,
Well I downloaded the library again, downloaded and reinstalled Arduino 1.0.3 again, downloaded and ran the little test program from the last post, it worked fine. Having "foo bar" print over and over took me back  30+ years, but it did work both ways, 'course we spelled it FUBAR. Which seems to be the way this is going to go for me.
I'll quit bugging you now, thanks again for your time.
TomJ
Logged

Einstein once said you don't really understand anything until you can explain it to your Grandmother

Pages: [1]   Go Up
Jump to: