CFA633 has different key values than expected?

moeburn

New member
I have a CFA633, the full model # on the sticker is "CFA633 TMC KU DP1784 A7G".

I am trying to program CC2 to use the keys to change screens and brightness. cc2_service.ini suggests that the key values should be the following:

Code:
; -- 633 & 635 KEY VALUES ---------------------------
; UP	= 1
; DOWN  = 32
; LEFT	= 8
; RIGHT = 16
; X     = 4
; TICK  = 2
The # for down was correct, 32 works. However, the # for up didn't work at all. After some fiddling, I managed to get the up key to work using this:

Code:
[m00-event00]     ; 1st module, 1st event
if_type=1
if=333939127     ; Substitute your id_keypad number here.
cond=0
to=8.000000     ; This tells CC2 that you want to poll the UP key.
do_type=9       ; This tells CC2 that this is a screen change command.
do=1.000000     ; This tells CC2 to scroll up one screen.
As you can see, to=8, not 1, as was suggested by cc2_service.ini. Does anyone have a list of the key values for my 633?

I also ran 633_WinTest_1_9.exe and used the packet debugger to see if I could figure out the key values myself. This is what I got:

Code:
C=128(key:KEY_UP_PRESS),L=1,D="\001",CRC=0xC271
C=128(key:KEY_UP_RELEASE),L=1,D="\007",CRC=0xA747

C=128(key:KEY_DOWN_PRESS),L=1,D="\002",CRC=0xF0EA
C=128(key:KEY_DOWN_RELEASE),L=1,D="\008",CRC=0x5FB0

C=128(key:KEY_LEFT_PRESS),L=1,D="\003",CRC=0xE163
C=128(key:KEY_LEFT_RELEASE),L=1,D="\009",CRC=0x4E39

C=128(key:KEY_RIGHT_PRESS),L=1,D="\004",CRC=0x95DC
C=128(key:KEY_RIGHT_RELEASE),L=1,D="\010",CRC=0x7CA2

C=128(key:KEY_ENTER_PRESS),L=1,D="\005",CRC=0x8455
C=128(key:KEY_ENTER_RELEASE),L=1,D="\011",CRC=0x6D2B

C=128(key:KEY_EXIT_PRESS),L=1,D="\006",CRC=0xB6CE
C=128(key:KEY_EXIT_RELEASE),L=1,D="\012",CRC=0x1994
So up is 1 and down is 2? Or if we look at the "CRC=" values and convert from hex to dec, up is 49,777 and down is 61,674. These don't make any sense, because in CC2, key value 32 works for down, and value 8 works for up.

I've tried googling this and searching the forums to find my keypad values, to no avail. It might be because this 633 module was removed from a NITIX Net Integrator server computer. It has two additional buttons on the front that do not register in the wintest packet debugger: "Backup" and "Restore". It also says "Net integrator" on the front. However, every thing else works beautifully. I have several different screens showing various system information, and at the moment, the up and down keys function to scroll through the screens, just not with the supplied key values.

Any help or suggestions would be greatly appreciated!
Looking for additional LCD resources? Check out our LCD blog for the latest developments in LCD technology.
 

CF Mark

Administrator
Greetings,

The WinTest information you copy & pasted shows that the 633 is returning the correct key codes, so the fact the display came from a NITIX system doesnt matter.
The CC2 key mapping numbers are different to those found in WinTest.
The information in the cc2_service.ini example file are correct, a value of 1 should be the up key (have re-checked the CC2 source code and confirmed it).
I have no explanation as to why its not the case for you :(

Can you ZIP up your INI setting files and attach them in here?
I would like to see if there is anything unusual going on in there.
 

moeburn

New member
Greetings,

The WinTest information you copy & pasted shows that the 633 is returning the correct key codes, so the fact the display came from a NITIX system doesnt matter.
The CC2 key mapping numbers are different to those found in WinTest.
The information in the cc2_service.ini example file are correct, a value of 1 should be the up key (have re-checked the CC2 source code and confirmed it).
I have no explanation as to why its not the case for you :(

Can you ZIP up your INI setting files and attach them in here?
I would like to see if there is anything unusual going on in there.
Greetings! Thanks for taking the time to assist me, I appreciate it. I wasn't sure which INI settings files you wanted, so I attached a zip with cc2_service.ini, lcd_633.ini, and cc2_keyboard.ini.

I have another possibly related problem. I am also unable to use keyboard commands to control CC2. I went through the whole guide to set them up:
- I used unassigned ID #s
- I used keytester to get the hex value of my keys, and confirmed they registered even when keytester wasn't the app in focus.
- I set up the key IDs in keyboard.ini, then assigned them to events in service.ini
My 633 panel buttons still work, but the keyboard assignments I made do nothing.

cc2_keyboard.ini
Code:
[options]

 ;ALT-F11
[input00]
 ;id for reported event
id=2110068363
 ;key repeat rate in milliseconds
repeat=250
 ;key codes are in hex (Alt + F11 here)
key0=0x1038
key1=0x0057
key2=0

;F11
[input01]
id=765769894
repeat=250
key0=0x0057
key1=0

;F12
[input02]
id=1113175586
repeat=250
key0=0x0058
key1=0
cc2_service.ini
Code:
[m00-event00]
if_type=1
if=765769894
cond=0
to=1.000000  
do_type=9     ; This tells CC2 that this is a screen change command.
do=1.000000  ; This tells CC2 to scroll up one screen.

[m00-event01]
if_type=1
if=1113175586
cond=0
to=1.000000
do_type=9
do=-1.000000
I thought maybe it wasn't working because [m00-event00] was already taken by the 633 keypad assignments, so I removed them, and it still didn't work.

Any time you spend on this is greatly appreciated!
 

Attachments

CF Mark

Administrator
The keyboard plugin will be a no go :(
It works on XP and older only due to the IPC security that Vista/Win7 introduced.

Sorry about that, ill be sure to make a note of it in the example INI in the future.
 

moeburn

New member
Internal Procedure Call security? Isn't that for things like Data Execution Protection? I can turn off DEP from both the system and the bios, I don't suppose that would help though would it?

How come the keytest.exe can read the keys fine, but cc2_tray.exe can't?

By the way, thank you for your dedication to my questions and your clear answers, I truly appreciate it.
 

moeburn

New member
IPC = inter-process communication

My mistake sorry, yes it should work as the IPC problem only occurs when running CC2 as a service.

Which INI files are you editing?
The ones in the ZIP are from the examples directory, which in their location have no effect.

The INI files that are used are located in "C:\ProgramData\CrystalControl2".

Can you do the following?
https://forum.crystalfontz.com/showthread.php?4418-How-to-report-a-CrystalControl2-problem
Crap do I ever feel stupid. I'm gonna stop this thread right here and assume that all my problems arose from not even being aware of the ProgramData directory.
 

CF Mark

Administrator
No thats ok :)
It happens fairly often with Vista/Win7 forcing apps to store config data away in some secret hard to get at place. Quite annoying.
 
Top