is there any downloadable form or repository where i can download the files for testing and verifying - would be great as you really hit the spot by combining the essential libs to one Gui tooolbox i'm thinking about an Dali based lighting control with an Due and 5" touch display which i will put on the playgroud once i have everything put together - your toolbox would be very helpfull for this project.

Kind regards, Mike

I have got checkboxs and a variant of them called cycleboxs working. I am just working on an input box for text and will then release a downloadable version for testing whilst I finish the other planned bits.I have a demo running here that has three pages and allows people to switch between them and keep the variables consistent etc. The input box effectively scrolls up the part of the screen with the input and creates a keyboard across the bottom half of the screen so quite a bit of work... I will also be adding the option of PS2 and bluetooth keyboard support etc but that is for later.......

I have a full qwerty keyboard with number pad very nearly finished. This will be for text input boxes. I am hoping that it will be in a fit state to go out for alpha testing within the week. There are dozens of functions added and a demo program which shows them in action. All the object orientated stuff works via an interrupt which is added by the library so you can even end up with the loop function empty!

Well I've had a useful day with the library. There was a bug that was corrupting the variables and causing hours of wasted time but I've fixed it now!

Anyway new additions to the working objects list:

addInputBox !!!drawInputBoxupdateInputBoxupdateLabel (automates the sequence.. if variable has changed then remove old value,display new value, update object.setColorLong (these new colour commands allow setting of a colour using 1 long int in the form 0xFFFFFF where value is 0xRRGGBBsetBackColorLong having it as one value makes it easy to have presets such as clrBlack,clrBlue,clrYellow etc)

This scrolls the screen up so that the object is visible in the top half of the screen and displays a keyboard at the bottom half of the screen. The keyboard is definable with a caps key and a symbol key allowing 3 full 52 key keyboards.

So we are nearing the point where it is alpha testable.....

I need to write a manual for it first but as my code is very heavily remarked that will make it much easier.

There are still parts not finished but I will highlight those in the manual.....

//////////////////////////////////////////////////////////////////////////////////////////// Due GUI Object demonstration sketch////////////////////////////////////////////////////////////////////////////////////////////// (c) 2013 Darren Hill (Cowasaki)//// Version 0.10//// This program is not as yet complete. There are a number of missing features and features not fully implemented.// There is also the possibility that anything implemented in this pre-release version may be implemented in a different// way in any subsequent version//// Many thanks to those persons that created the original UTFT library - Henning //// BASIC PROGRAM.

//////////////////////////////////////////////////////////////////////////////////////////// Setup variables for Due GUI////////////////////////////////////////////////////////////////////////////////////////////

///////////////////////////////////////////////////////////////////////////////////////////// Due GUI Interupt routine and variables////////////////////////////////////////////////////////////////////////////////////////////// fast ticks for Due GUI interuptvolatile int l;volatile int btnFound;//// DueGUI Interupt handler routine//void DueGUI_tickHandler(){ // // We don't want timer called whilst it's being handled. // DueGUI.stopTimer(DueGUI_timer); // // routine is called several times per second ie "ticksPerSecond". // l is incremented each time and by checking this against "ticksPerSecond" // we can make sure that once a second events are only called once per second. // l+=1; // // This is the "once per second" event routine. // if (l==ticksPerSecond){ // second passed l=0; if (DueGUI.anyClockVisible) { rtc_clock.get_time(&hh,&mm,&ss); rtc_clock.get_date(&dow,&yyyy,&mon,&dd); // // Insert below the set and redraw clock functions: // // Clocks that are only shown on some screens

// Set global variable to record which screen is in view DueGUI_currentlyDisplayedScreen=screen;

// Clear all the data and the screen DueGUI.clearAllObjects(); DueGUI.clrScr();

// Setup anything that is on EVERY screen // NOTE: pnlTitle's text is left blank as it is filled in by each screens functions. pnlTitle= DueGUI.addPanel(0,0,799,50,clrBlue,clrWhite,clrWhite,2,"",280,8,BVS_34,optVisible,URNnull);

//// Fan screen//// setup the fan screen's screen number definition:#define fan_screen 2////// The following line could be byte types but they are basically variables to store the object's object number. This is purely to make things easier, you don't actually have to remember the object's number in a variable you can get the object's number from the URN using the function "findObjectByURL(URNname);".//int btnFBonoff0,btnFBspeed0,btnFBonoff1,btnFBspeed1,btnFBonoff2,btnFBspeed2,btnFBonoff3,btnFBspeed3;////// Here we actually setup a URN for the main menu return button. The number can be anything that fits in an integer but for ease I will be using numbers 100-199 for the main menu (screen 1), 200-299 for screen 2 etc etc//#define URNFBmainmenu 209////// Here we setup the arrays used to store the values of the objects starting with the defaults.//int valFBspeed[] = {4000,3000,500,0};boolean valFBonoff[] = {true,false,false,true};

As the user clicks the main menu button you need to save the values of the inputs back to the arrays:

The following is added to the on button event function. You can see the URN is being checked and it is the URN defined above.

if (URN==URNFBmainmenu){ // Grab the data BEFORE you switch screens. // // Note the objects were created in order so we know that btnFBonoff1 is 1 more than btnFBonoff0 etc. We can use this // to calculate object values in order to place in loops etc. // // store the values of the cycBoxes in variables ready to use again later for (int i = 0; i < 4; i++){ valFBspeed[i]=DueGUI.returnIntValue(btnFBspeed0+i); valFBonoff[i]=DueGUI.returnBoolValue(btnFBonoff0+i); } printvariables(); DueGUI_createScreen(main_menu); }

Objects (these are all to be added but just what I've thought of so far):

Progress bar (vertical and horizontal)Rev counter (like a progress bar but looking like a car rev counter)Cyclebutton using an array of Strings.ButtonLED (like a check box but looks like an LED being switched on and off)LED (like the above Button LED but just as an output)StringBox (Box containing text)

Shapes

needs quite a few addingplus transform function to rotate a shape

Functions

modify AddImage to work with data and SDcard files as well as files in the EEPROM.finish CycleBox in order to use more options allowing the cycling text to be formatted to the user's preference.

General

add more coloursmake sure everything is in the keywords.txt filefinish manualadd more clock optionsadd more formatting options for objectsadd calibrate function (allowing you to add a calibrate option to your program which will store the values on EEPROM/SDcard etc) this will take into account the accuracy and sweep range

If you watch the video, one of the coordinates for the stylus appears on the main menu, a little bug in the demo program - easily sorted

Another issue that has been reported by one person taking a look was the keyboard accepting two button presses if held the stylus is not removed from the button quick enough. This is a fault I though of yesterday and will be fixed today with a setting changing the minimum amount of time between key presses to denounce it.

After that, a slider was mentioned by another user and that would be a useful addition as would support for a bluetooth keyboard and maybe eventually a keyboard/mouse combo.

A menu object is a obvious choice for a new addition too and this will be added.

A numeric/array input with + and - buttons was also mentioned and something I will look at BUT I have started to include a link on a button to allow it to automatically increment a value on another object which would allow you to easily accomplish this by the creation of 2 buttons and a panel - I will think about this one a little more.

I also want to make the calibration screen into a function that the user can just simply call and would finish with writing the calibration data to the EEPROM (subject to the screen or shield having one!) this would mean that you could simply add it as a menu option and your users could simply call it.

On occasion screen goes haywire when analogue clock drawn (sure this is due to trying to clear old hand pos when there isn't one so looking up a ridiculous value in the cosine/sine table - off to work now so will fix later!)

Spurious values from calibration screen sometimes appear on the main menu (again I can fix this in a few minutes but no time now).

Hopefully release bug fix later and then onto slider or calibration object.....

FIXED: Spurious values from calibration screen sometimes appear on the main menu.

Changes:

ADDITION: showCalibration() - This shows the calibration screen with no further code with a new "SAVE" button which will soon write the calibration data to a special data sector within the EEPROM of the screen.

CHANGE: Addition of two new functions HandleShowButtons(int URN) & HandleShowLoopStuff() - these functions pass control to the library during the loop function and button handler allowing the library to create it's own objects and handle them.

CHANGE: Removal of the calibration screen code from the demo program and switch to using the showCalibration() function which does the same thing.