PfSense on a Celestix S-X MSA 4000
-
Unfortunately it doesn't. It still uses the same Linux driver:
def lcd_display(message, line=1): message = str(message) line_selection = "\x00" if line == 1 else "\x01" preamble = "\x02\x00\x00{0}\x28\x00\x00\x00".format(line_selection) endpad = "\x20"*(40-len(message)) data = preamble + message + endpad with open("/dev/hidraw0", "w") as lcd: lcd.write(data)
Addresses /dev/hidraw0.
Interesting that that driver is in VyOS though…. if it's a standard Linux driver we might be able to see some clues.
Steve
-
dmesg on system yields:
ukbd0: <vendor 0="" 2="" 0x0cb6="" keyboard="" +="" lcd,="" class="" 0,="" rev="" 1.10="" 1.00,="" addr="">on usbus1</vendor>
-
Looks like there is something testable with the information published this far.
The Python code shows a sequence of hex codes
The device is known
The BSD shell has the printf built-in, and it accepts codes on octal format.
So, to hexadecimal 0x20 becomes octal \40
Try something like this:
printf "\02\00\00\61\50\00\00\00Some Message" > /dev/ukbd0
Try this for line 2:
printf "\02\00\00\62\50\00\00\00Some Message" > /dev/ukbd0
-
So something interesting happened. I rebooted the machine and now dmesg shows:
ukbd1: <vendor 0="" 2="" 0x0cb6="" keyboard="" +="" lcd,="" class="" 0,="" rev="" 1.10="" 1.00,="" addr="">on usbus1
This is what I get while running the printf command
[2.3.5-RELEASE][root@pfSense.geek.local]/: printf "\02\00\00\61\50\00\00\00Some Message" > /dev/ukbd1
/dev/ukbd1: Device busy.</vendor> -
Hmm, that's not good. Changing device names makes it that much harder to work with even we could get it to accept any input. :-\
Steve
-
Good reading here:
https://www.freebsd.org/cgi/man.cgi?query=ukbd&sektion=4
Seems like we would need that character device. Once it shows as /dev/kbd1, that printf should be directed to it. Worth a try…
-
Good reading here:
https://www.freebsd.org/cgi/man.cgi?query=ukbd&sektion=4
Seems like we would need that character device. Once it shows as /dev/kbd1, that printf should be directed to it. Worth a try…
I’m relatively new to pfsense here and have read that. How would I go about compiling that in the kernel and config to test? May need a little guidance here but looks like we’re getting somewhere here!
-
Actually, looking at the Linux device, it suggests it is a raw device. Maybe the character device is not needed.
Maybe it needs to be initialized read/write:
exec 3<> /dev/ukbd1
-
Actually, looking at the Linux device, it suggests it is a raw device. Maybe the character device is not needed.
Maybe it needs to be initialized read/write:
exec 3<> /dev/ukbd1
I'll give this a shot when I get home and report back!
-
Actually, looking at the Linux device, it suggests it is a raw device. Maybe the character device is not needed.
Maybe it needs to be initialized read/write:
exec 3<> /dev/ukbd1
[2.3.5-RELEASE][root@pfSense.geek.local]/: exec 3<> /dev/ukbd1
Missing name for redirect.