Welcome! Log In Create A New Profile

Advanced

Full Graphic Smart LCD Controller

Posted by RicardoGA 
Full Graphic Smart LCD Controller
August 28, 2013 08:34PM
Hi my question is possible use Full Graphic Smart LCD Controller from reprap discount with repetier firmware, the firmware have an option for the Smart LCD Controller but i dont know if its compatible with the full graphic Smart LCD

Thanks In advance
Re: Full Graphic Smart LCD Controller
August 29, 2013 08:58AM
No, currently only the standard Smart Controller is supported, not the GLCD.


Repetier-Software - the home of Repetier-Host (Windows, Linux and Mac OS X) and Repetier-Firmware.
Repetier-Server - the solution to control your printer from everywhere.
Visit us on Facebook and Twitter!
Re: Full Graphic Smart LCD Controller
October 16, 2013 04:20PM
@repetier: please implement this. this would be really awesome! I think this firmware is the best for my delta printer with filament drive!
Re: Full Graphic Smart LCD Controller
October 25, 2013 07:42PM
Which version of GLCD do you have? I have one from Geeetech, I might have a go at implementing support for it.
Re: Full Graphic Smart LCD Controller
October 26, 2013 02:36AM
@bobc That would be great! If you do, please do it for the development version. It is unfortunately not fully compatible with previous version since I rewrote or refactored most of it. But it is now stable and only small changes are to expect.

I think most have the Reprapdiscount GLCD, also I think the controller is the same for all these 128x64 pixel monochrome LCDs. Only the pin assignment may vary.


Repetier-Software - the home of Repetier-Host (Windows, Linux and Mac OS X) and Repetier-Firmware.
Repetier-Server - the solution to control your printer from everywhere.
Visit us on Facebook and Twitter!
Re: Full Graphic Smart LCD Controller
October 26, 2013 02:35PM
Ok, I will use development branch.

First I need to compile for Arduino Due. I have built the ArduinoDUE folder successfully, so that's a good start smiling smiley

I notice that many of the common HAL files have small differences between AVR and DUE - is there some merging that needs to be done? I couldn't immediately see which changes are later. I guess that the AVR branch is the reference, but there are some changes for delta which have made on the DUE side.
Re: Full Graphic Smart LCD Controller
October 26, 2013 03:13PM
bobc Wrote:
-------------------------------------------------------
> Ok, I will use development branch.
>
Great.

> First I need to compile for Arduino Due. I have
> built the ArduinoDUE folder successfully, so
> that's a good start smiling smiley
>
> I notice that many of the common HAL files have
> small differences between AVR and DUE - is there
> some merging that needs to be done? I couldn't
> immediately see which changes are later. I guess
> that the AVR branch is the reference, but there
> are some changes for delta which have made on the
> DUE side.
There is a script avrtodue.bat that copies all files that should be hardware independent to the due. The reason I didn't copy the latest version is I changed the sd files and had no time to test them on due.

HAL files are supposed to be different, but the interfaces should of course be more or less identical and have the same effect on the output. It's the HAL (hardware abstaction layer) that codes the differences between the two architectures.


Repetier-Software - the home of Repetier-Host (Windows, Linux and Mac OS X) and Repetier-Firmware.
Repetier-Server - the solution to control your printer from everywhere.
Visit us on Facebook and Twitter!
Re: Full Graphic Smart LCD Controller
October 26, 2013 04:12PM
repetier Wrote:
-------------------------------------------------------
> bobc Wrote:
> --------------------------------------------------
> -----
> > Ok, I will use development branch.
> >
> Great.
>
> > First I need to compile for Arduino Due. I have
> > built the ArduinoDUE folder successfully, so
> > that's a good start smiling smiley
> >
> > I notice that many of the common HAL files have
> > small differences between AVR and DUE - is
> there
> > some merging that needs to be done? I couldn't
> > immediately see which changes are later. I
> guess
> > that the AVR branch is the reference, but there
> > are some changes for delta which have made on
> the
> > DUE side.
> There is a script avrtodue.bat that copies all
> files that should be hardware independent to the
> due. The reason I didn't copy the latest version
> is I changed the sd files and had no time to test
> them on due.
>
> HAL files are supposed to be different, but the
> interfaces should of course be more or less
> identical and have the same effect on the output.
> It's the HAL (hardware abstaction layer) that
> codes the differences between the two
> architectures.

Sorry, bad edit there, what I meant to say there are differences in the common files (ie. non-HAL), the ones copied by avrtodue.bat.

For example, in Repetier.h

25c25
< #define REPETIER_VERSION "0.90alpha"
---
> #define REPETIER_VERSION "0.90"
38c38
< //#define INCLUDE_DEBUG_NO_MOVE
---
> #define INCLUDE_DEBUG_NO_MOVE
103a104,109
> #if DRIVE_SYSTEM==3 || DRIVE_SYSTEM==4
> #define NONLINEAR_SYSTEM true
> #else
> #define NONLINEAR_SYSTEM false
> #endif
> 
312c318
< #if DRIVE_SYSTEM==3
---
> #if NONLINEAR_SYSTEM
314,316d319
< extern void set_delta_position(long xaxis, long yaxis, long zaxis);
< extern float rodMaxLength;
< extern void split_delta_move(uint8_t check_endstops,uint8_t pathOptimize, uint8_t softEndstop);
322a326,331
> #ifndef FEATURE_DITTO_PRINTING
> #define FEATURE_DITTO_PRINTING false
> #endif
> #if FEATURE_DITTO_PRINTING && NUM_EXTRUDER!=2
> #error Ditto printin requires exactly 2 extruder.
> #endif
325,328c334,336
< 
< extern unsigned long previousMillisCmd;
< extern unsigned long maxInactiveTime;
< extern unsigned long stepperInactiveTime;
---
> extern millis_t previousMillisCmd;
> extern millis_t maxInactiveTime;
> extern millis_t stepperInactiveTime;
378,379c386,387
<   void write_command(GCode *code);
<   void selectFile(char *filename);
---
>   void writeCommand(GCode *code);
>   bool selectFile(char *filename,bool silent=false);
416,420c424
< #if DRIVE_SYSTEM==3
< #define SIN_60 0.8660254037844386
< #define COS_60 0.5
< 
< 
---
> #if NONLINEAR_SYSTEM

I'm not sure how to resolve these differences.
Re: Full Graphic Smart LCD Controller
October 27, 2013 03:12AM
I see - there are some new settings etc that prevent compiling on due after running avrtodue.bat.

I just uploaded a new version on github where I fixed all these issues. Hope nothing got broken on that process.


Repetier-Software - the home of Repetier-Host (Windows, Linux and Mac OS X) and Repetier-Firmware.
Repetier-Server - the solution to control your printer from everywhere.
Visit us on Facebook and Twitter!
Re: Full Graphic Smart LCD Controller
November 06, 2013 03:22AM
How is the work going on? I really would appreciate this implementation =)
Re: Full Graphic Smart LCD Controller
November 07, 2013 06:04PM
I am still setting things up to work with my electronics+printer+character LCD, and I have never used Repetier before, so it might be a little while before I have a stable platform to work on.

I will post an update if I have anything.


What is Open Source?
What is Open Source Hardware?
Open Source in a nutshell: the Four Freedoms
CC BY-NC is not an Open Source license
Re: Full Graphic Smart LCD Controller
November 29, 2013 04:12AM
I have added initial support (for AVR version) for the reprapdiscount full graphic controller using the development branch here: github

It is using u8glib (which needs to be downloaded) and custom font with the "extra" characters in the same character locations 1-6 as with the other LCDs. The FEATURE_CONTROLLER is currently set to 22 and shares the same pin config as the smart controller. It ends up being a 6 line display using the 6x10 font.

Seems to work ok so far, although i havent tested while printing yet.

Edited 3 time(s). Last edit at 11/30/2013 03:10AM by sdavi.
Re: Full Graphic Smart LCD Controller
November 30, 2013 05:04AM
Thanks sdavi for the good initial version. I took that and included some fixes and added some more special chars. It is now in the github development tree as controller 11. With your work it was not much work needed:-) In a leter version I might add graphic information screens to take full advantage of it. This should also be faster to draw then the default screen.

U8glib is a good library, but the display is much slower then a simple lcd. I hope this has no negative impact on print quality.
For delta uses the bad news is that it needs some ram. I have not tested it with a delta but you might need to reduce buffer size if you get crashes. I get 851 byte free ram, that might just be enough or not.


Repetier-Software - the home of Repetier-Host (Windows, Linux and Mac OS X) and Repetier-Firmware.
Repetier-Server - the solution to control your printer from everywhere.
Visit us on Facebook and Twitter!
Re: Full Graphic Smart LCD Controller
November 30, 2013 05:41AM
I actually committed a new font today based on the u8g 6x10 font and copied over the arrow, folder etc characters from the other fonts and also created a temperature character, which will save space instead of including all the 3 fonts. They are currently in positions \001-\006 which matched the previous code.

I have also noticed it is much slower, i will try printing with it hopefully sometime soon and see if it causes any problems.
Re: Full Graphic Smart LCD Controller
November 30, 2013 05:56AM
I like the trick with the changed font. How did you create the changed font? Might add a 7th character

// printer ready - code 7
// *...* 17
// .*.*. 10
// ..*.. 4
// *...* 17
// ..*.. 4
// .*.*. 10
// *...* 17
// *...* 17

from an update I'm currently including which adds animations to the menu. I will update your font when I'm through with this.

The speed is nothing we can largely influence I think. Only the 1024 byte of the screen are already more then 80 bytes of the char lcds. Then building fonts manipulating the data and repeating the painting several times does not really help to speed up. The only good thing is that marlin uses it and it seems to work. I think mainly because the interrupts do get get blocked. You might only get troubles with many short lines where you might miss the cpu power.


Repetier-Software - the home of Repetier-Host (Windows, Linux and Mac OS X) and Repetier-Firmware.
Repetier-Server - the solution to control your printer from everywhere.
Visit us on Facebook and Twitter!
Re: Full Graphic Smart LCD Controller
November 30, 2013 06:34AM
I have attached the new font BDF and the new generated header file. Also now with the new code 7 - printer ready.

I currently use "fontforge" to draw the characters and it can also save to BDF. The BDF is just a text file so its also easy to copy and paste from the other fonts in a text editor.

U8Glib has a "bdf2u8g" tool and i use the params "-b 0 -e 255" as it defaults to starting at 32 and we need to make it include 0-7.

Edited 1 time(s). Last edit at 11/30/2013 06:52AM by sdavi.
Attachments:
open | download - repetier-6x10.bdf (22.6 KB)
open | download - Font_Repetier_6x10.h (8.2 KB)
Re: Full Graphic Smart LCD Controller
December 08, 2013 08:37AM
I've just uploaded (github) an update, based on your latest dev version, which now adds a status display page with, X,Y,Z, Ext1+2, heatbed, cooling fan, SD card progress, status line, buffer and feedrate multiplier all on one screen.

Added some animated icons in the fonts for extruder, heatbed and fan, and, added a progress bar like display for the fan and SD Card

After some testing i found the "picture loop" loops about 8 times so I have buffered the lines (only for status page) to save time parsing the same lines within the picture loop. Currently, the picture loop is taking approx 160ms for the status display page.
Re: Full Graphic Smart LCD Controller
December 08, 2013 11:24AM
The current dev version is currently a bit behind, because I do not want to update with the bugs I currently have. I have done the same buffering, also for animations when you slide menus in and out. Unfortunately this is quite slow also switching between full screens seems to be faster.

Anyway, a status display using even extra icons sounds great. I will have a look and copy what I need. How do you do animations? Simply switch icons every update?

What I also did was removing the u8glib dependency. I have now a big include file including all code parts needed. And I switched to c library calls to improve speed. I now check if a line is inside the update region, if not I do not try to print it. I'm already curious how both combined will work and look.


Repetier-Software - the home of Repetier-Host (Windows, Linux and Mac OS X) and Repetier-Firmware.
Repetier-Server - the solution to control your printer from everywhere.
Visit us on Facebook and Twitter!
Re: Full Graphic Smart LCD Controller
December 08, 2013 07:06PM
Sounds great. Yeah the animations are just switched between updates. I was mainly just trying to get a layout that squeezed in all the important info into one screen and it was a bit difficult to make it dynamic like the current menus (i.e if you only have one extruder how should it be rearranged etc), so it ended up being a bit hardcoded.
Re: Full Graphic Smart LCD Controller
December 14, 2013 12:30PM
A short update: The GCLD support is now finished an works.

Special thanks to sdavi who wrote the initial code, which I tweaked a bit more:-) But he will surely recognice his modified fonts and codes.

@sdavi: For your interest, I changed it to my new ui system which uses already a cache like you introduced, switched to c interface with some optimizations (faster) and sd card only appears if card is inserted/mounted. I now also invert the selected line in the submenus making it easier to see, where you are. All fonts and u8glib parts are now in u8glib_ex.h so no extra library needs to be installed.


Repetier-Software - the home of Repetier-Host (Windows, Linux and Mac OS X) and Repetier-Firmware.
Repetier-Server - the solution to control your printer from everywhere.
Visit us on Facebook and Twitter!
Re: Full Graphic Smart LCD Controller
December 15, 2013 02:32AM
Which LCDs can I use if i wanted to use this on my own boards (i.e pinout less important).

It used a1284p - so I assume SPI or I2C expanders as those 12864 lcds have a bunch of io pins and the 1284 is stretched thin...
Re: Full Graphic Smart LCD Controller
December 15, 2013 02:54AM
Currently only the ST7920 used for the GLCD Display is included. Since it uses the u8glib library it is easy to add any display which is supported. Add the driver to u8glib_ex.h and change the constructor. The code is optimized for monochrome 128x64 pixel display, so it's best to choose one of them. The GLCD is connected over software spi, so using a display with the same controller would be the easiest way. Simply modify the pins in ui.h for controller 11.


Repetier-Software - the home of Repetier-Host (Windows, Linux and Mac OS X) and Repetier-Firmware.
Repetier-Server - the solution to control your printer from everywhere.
Visit us on Facebook and Twitter!
Re: Full Graphic Smart LCD Controller
December 15, 2013 03:17AM
I'm curious to see a screenshot of the graphics on this screen.
thank you for the fantastic job
Re: Full Graphic Smart LCD Controller
December 15, 2013 03:31AM
Ok, so here a screenshot of the default start screen. Ignore temperatures - the board is not connected to a printer.




Repetier-Software - the home of Repetier-Host (Windows, Linux and Mac OS X) and Repetier-Firmware.
Repetier-Server - the solution to control your printer from everywhere.
Visit us on Facebook and Twitter!
Re: Full Graphic Smart LCD Controller
December 15, 2013 05:04AM
That's a big space saving going to the stripped down c version and its quite responsive too! I also like the inverted selection.

Couple of little things:
* When the 2nd ext or heatbed is disabled the text is out of alignment as its got the 2 extra characters. Just need to change the ---/--- to -----/--- for them both
* There is also the old u8glib header include still in the ino which will cause compile errors for those with u8glib in their arduino library.
Re: Full Graphic Smart LCD Controller
December 15, 2013 05:08AM
Yes, compared to the marlin version it is much more responsive :-) I guess they do not ask the encoder status often enough.

Code is now fixed on github, thanks.


Repetier-Software - the home of Repetier-Host (Windows, Linux and Mac OS X) and Repetier-Firmware.
Repetier-Server - the solution to control your printer from everywhere.
Visit us on Facebook and Twitter!
Re: Full Graphic Smart LCD Controller
December 15, 2013 05:49AM
Thanks... Ordered some ST7920 right away on ebay, now that my favourite firmware supports it (:

Peter
Re: Full Graphic Smart LCD Controller
December 21, 2013 02:35AM
HI... awesome work! THX

But where can I download this special code with the firmware.
On githubt I cant see these changes.

maxtex
Re: Full Graphic Smart LCD Controller
December 21, 2013 03:37AM
It is in the development tree. Select development as branch on github or follow this link: https://github.com/repetier/Repetier-Firmware/tree/development


Repetier-Software - the home of Repetier-Host (Windows, Linux and Mac OS X) and Repetier-Firmware.
Repetier-Server - the solution to control your printer from everywhere.
Visit us on Facebook and Twitter!
Re: Full Graphic Smart LCD Controller
January 10, 2014 02:29PM
Okay they arrived today. wired up to an Arduino and got u8gluib running in under 20 seconds! Impressive chip this ST7920

Okay, so back to Repetier. Cloned latest Dev branch from Github, changed to my board settings. With Display type 0 I compile fine

As soon as I set display type to 5, compile fails UI_FONT_DEFAULT was not Declared. sad smiley

Peter

Quote
peter6960
Thanks... Ordered some ST7920 right away on ebay, now that my favourite firmware supports it (:

Peter
Sorry, only registered users may post in this forum.

Click here to login