Our new official repo is on github
LCD Smartie version 5.6 is released!
Download it now: https://github.com/LCD-Smartie/LCDSmartie/releases

LCD2USB Button support

Discussion about LCD's and other related hardware

Moderators: _X7JAY7X_, caesar, IFR, mattcro, limbo, Fast351, hydrolisk1792

Post Reply
shinobi_h2o
Posts: 18
Joined: December 21st, 2007, 4:13 am
Location: Rio de Janeiro, RJ

LCD2USB Button support

Post by shinobi_h2o »

Hey all.

I got myself an LCD2USB (http://www.harbaum.org/till/lcd2usb/) and it's great and all, but the buttons are not implemented in the LCDSmartie driver.

The guy who made the controller (Till Harbaum) didn't really care about it. It actually looks like he asked somebody else to make the windows versions for the drivers and this other guy didn't implement the buttons.

What is funny is that I can see the source code for the buttons in the "TestApp", in the firmware and all. The TestApp shows the states of the buttons, but the source of the LCDSmartie plugin doesn't.

So off I went, with no knowlege at C-programming, and managed to download some includes from AVR and stuff, but I can't compile it (shows a lot of errors).

Can anyone PLEASE take a look at the source code (you can find it in the URL above) and see if it's easy to implement the buttons...? Please! lol


Thanks a lot in advance, guys.

shinobi_h2o
Posts: 18
Joined: December 21st, 2007, 4:13 am
Location: Rio de Janeiro, RJ

Post by shinobi_h2o »

Just for the record, maybe I managd to implement it in the source, but I can't get to compile it. :D

I don't know if I'm using the wrong includes, but apparently it shows a lot of errors that are not related to the code I added myself...

So any suggestions? :D

Henk
Posts: 2
Joined: July 18th, 2008, 7:09 am
Location: Belgium

LCD2SUB buttons are working in Smartie

Post by Henk »

Hi,

I mananged to modify the LCD2USB.DLL for smartie so that the buttons do work. I have programmed it so that:
Upper button returns '1'
Lower button returns '2'
Both buttons together return '3' (with only two buttons one has to be creative)
I also have a working config.ini to use the buttons with the menu-plugin.

But I don't know where and how I can post this new version of dll.
If someone it interested and would like to make this new version official. Let me know and I can e-mail it.

best regards,

Henk

limbo
Plugin Author
Posts: 1604
Joined: February 13th, 2005, 7:38 pm
Location: Athens - Greece
Contact:

Re: LCD2SUB buttons are working in Smartie

Post by limbo »

Henk wrote:Hi,


But I don't know where and how I can post this new version of dll.
If someone it interested and would like to make this new version official. Let me know and I can e-mail it.

best regards,

Henk
You can upload the file 9zipped here to forums. Just use the attachment option when you posting a new thread

Henk
Posts: 2
Joined: July 18th, 2008, 7:09 am
Location: Belgium

Post by Henk »

Nope, I can't attach anything to a post.
Probably because I'm a newbie I don't have the rights to do so.

But it is actualy very simple. Just add this one function to the lcd2usb.cpp file:

Code: Select all

unsigned short __stdcall DISPLAYDLL_ReadKey(void)
{
  int keymask = lcd_get(LCD_GET_KEYS);

  if(keymask > 0) 
	  return (keymask & 3) + '0';
  else
	return 0xFF00;
}
And this line to LCD2USB.DEF

Code: Select all

DISPLAYDLL_ReadKey @11
Recompile and that's it.

Henk

RAIDER
Posts: 1
Joined: September 5th, 2010, 12:49 pm

Re: LCD2USB Button support

Post by RAIDER »

Hello,
I succeed to build and compile the LCD2USB driver and here it is: http://rapidshare.com/files/417198973/LCD2USB.rar

caesar
Forum Supporter
Posts: 734
Joined: October 15th, 2005, 10:39 am
Location: Romania
Contact:

Re: LCD2USB Button support

Post by caesar »

And here is RAIDER's file as an attachment (Rapidshare tends to terminate them pretty fast).
LCD2USB.rar
You do not have the required permissions to view the files attached to this post.

schnubbi-gilles
Posts: 3
Joined: April 29th, 2011, 11:40 am

Re: LCD2USB Button support

Post by schnubbi-gilles »

Nicely Done!
I´ver searched a long Time till i found this :)
Thanks a lot for the driver!

schnubbi-gilles
Posts: 3
Joined: April 29th, 2011, 11:40 am

Re: LCD2USB Button support

Post by schnubbi-gilles »

Can anyone write the LCD2USB driver for Windows x64 Systems?

fritech
Posts: 1
Joined: March 23rd, 2012, 8:28 am

Re: LCD2USB Button support

Post by fritech »

Hi,

i have a question about LCD2USB extended Button Support


Originally i use a LCD2USB (no pushbuttons connected) and a keypad
matrix connected to parport0 together with LCDproc/LCDd.

i use firmwire from :

http://www.dl9sec.de/LCD2USB/LCD2USBsed_1V0.zip

The keypad is connected as following:

+5V ----------+--------+--------+--------+
| | | |
22k 22k 22k 22k
| | | |
/STRB (1) -|<---+--------+--------+--------+ |
| | | | | | | |
o | o | o | o |
S1 \ | S2 \ | S3 \ | S4 \ |
o | o | o | o |
| | | | | | | |
+---+ +---+ +---+ +---+
| | | |
/LF (14) -|<---+-----------------+--------+ |
| | | | | | |
o | | o | o |
S5 \ | | S6 \ | S7 \ |
o | | o | o |
| | | | | | |
+---+ | +---+ +---+
| | | |
/ACK (10) ----------+ | | |
BUSY (11) -------------------+ | |
PE (12) ----------------------------+ |
SELIN (13) -------------------------------------+

Is it possible to use the smartie LCD2USB.dll together with this keypad ?

Thx in advance

Post Reply