[Lcdproc] Re: lcdproc-0.5.1 and serialized HD44780 on k-data wake-up 2.0 module

Bernd Büchs bernd.buechs@freenet.de
Tue Jan 23 23:24:01 2007


--Boundary-00=_xmptFrMP1pLituu
Content-Type: text/plain;
  charset="iso-8859-15"
Content-Transfer-Encoding: 7bit
Content-Disposition: inline

Am Sonntag, 21. Januar 2007 20:30 schrieb Matteo Pillon:
> Good work, Peter.
> Attached, the fix for "character mapping" and "multiple lcds"
> limitations ;-). I also included backlight switching support.
>
> For using the new character mapping, you have to put in LCDd.conf:
>  [hd44780]
>  Charmap=sed1278f_0b
>
> > Next I tried "lcdproc M". The following screens looked fine (time, cpu,
> > net load, hd usage, server name). But every time the next (lcdproc server
> > screen?!) is displayed the backlight is tured off!
>
> Very strange, I tried debugging the driver and seems that every 0xC9
> (switch off backlight) is correctly escaped by a 0xC0...
>
> > The next screen is somehow "messy", i.e. it shows a mixture of different
> > screens (lcdproc server parts and the server name). I considder this as
> > being ment with the limitation "no full redraw support".
>
> I think this is related to the backlight bug (if it really is),
> vdr-wakeup missed an escape byte, so data that comes after is
> misunderstood.
> Do you have exactly the same behaviour every time you run
> LCDd/lcdproc?
>
> I wonder why vdr-wakeup needs a full redraw....


Thank you Matteo for your patch!

I tried it as well. I use "lcdproc-0.5.1.tar.gz". I had some problems applying 
your patch to my version. I assume the ",v" at the end of the paths in the 
lines with "RCS file:" in the patch are a problem.

With the file "hd44780-serial.c" I got even a rejection (see attached file). 
The content that was in my version is as following:

lcdproc-0.5.1.tar.gz [...
unsigned int conf_bitrate;
size_t bitrate;

conf_bitrate=atoi( drvthis->config_get_string(drvthis->name, "Speed", 
0, "0") );
if (conf_bitrate==0)
	conf_bitrate=SERIAL_IF.default_bitrate;
if (convert_bitrate(conf_bitrate, &bitrate)) {
	report(RPT_ERR, "HD44780: serial: invalid configured bitrate speed");
	return -1;
...]

That in mind, I think this migth be the reason for some of the problems that I 
discribed with the version from Peter!?

Anyhow here comes my test report of the current version:

LCDd.conf with Backligth=yes switchs it on when starting LCDd and switchs it 
off when stoping LCDd  - good!
With Backlight=no I recofgnized that the Backligth is turned off when I stop 
LCDd! I wonder if this is a bug or a feature? (For me this behaviour it is 
fine!)
I both cases I can turn the backligth on and off with vdr-wakeup hardware 
(receiving IR command).

I also experimented with lcdproc:
lcdpro.conf: [...
[Load]
# Show screen
Active=true
# Min Load Avg at which the backlight will be turned off [default: 0.05]
LowLoad=0.05
# Max Load Avg at which the backlight will start blinking [default: 1.3]
HighLoad=1.3 ...]

This load screen turns of the backligth, even with LCDd.conf Backligth=no!
The screen shows in the first line "hostname 0.13               0" and in the 
second line "                    0". The first parts of the second line are 
filling from rigth to left with blocks/symboles.
Unfortunately I have not experimented with the load screen before.

All other screens activated in the standard lcdproc.conf are working correct.

I have recongnized that I thougth in my previous report that parts of the LCDd 
server screen and another screen are mixed. Now I recognised that I was 
wrong. The "mixed" screens are LCDd server and TimeDate screen.

I also tried Charmap=sed1278f_0b for curiosity and every thing still looked 
like with the default?! I have to admit that I never used char maps before 
and I have no clue how this could be tested in a propper way. If my 
understanding is correct this feature is somehow LCD dependent. I use the 
following LCD 
<http://www.reichelt.de/?SID=29wzKd6KwQAR0AAH7RiW092aed62a4d907ffedb39f64556e3e886;ACTION=3;LA=3;GROUP=A5212;GROUPID=3006;ARTICLE=53953;START=0;SORT=artnr;OFFSET=16>

Regards


Bernd






--Boundary-00=_xmptFrMP1pLituu
Content-Type: text/x-diff;
  charset="iso-8859-15";
  name="hd44780-serial.c.rej"
Content-Transfer-Encoding: 7bit
Content-Disposition: attachment;
	filename="hd44780-serial.c.rej"

***************
*** 170,176 ****
  	unsigned int conf_bitrate;
  	size_t bitrate;
  
- 	conf_bitrate = drvthis->config_get_string(drvthis->name, "Speed", 0, SERIAL_IF.default_bitrate);
  	if (convert_bitrate(conf_bitrate, &bitrate)) {
  		report(RPT_ERR, "HD44780: serial: invalid configured bitrate speed");
  		return -1;
--- 172,180 ----
  	unsigned int conf_bitrate;
  	size_t bitrate;
  
+ 	conf_bitrate = drvthis->config_get_int(drvthis->name, "Speed", 0, SERIAL_IF.default_bitrate);
+         if (conf_bitrate==0)
+                 conf_bitrate = SERIAL_IF.default_bitrate;
  	if (convert_bitrate(conf_bitrate, &bitrate)) {
  		report(RPT_ERR, "HD44780: serial: invalid configured bitrate speed");
  		return -1;

--Boundary-00=_xmptFrMP1pLituu--