X forwarding to N900 with working hardware keyboard.
Not wishing to necrobump and old post; https://talk.maemo.org/showthread.php?t=41848 I found a clunky workaround to capturing keyboard input for X forwarding.
I did this with Chromium, which may appeal to those that don't wish to use the native web-browser due to security issues. Initially I found that the hardware N900 keyboard did not capture the X forwarded Chromium instance and instead sent keyboard input to the terminal, so tried to use xvkbd as an alternative input method, but accidentally discovered that typing with xvkbd it gave the N900 hardware keyboard focus of the X forwarded application and continued to work even if I killed xvkbd. This is a clunky fix though so there's probably a more elegant solution, this could be written into a shell script or other. Regardless, here are the steps I go through to run Chromium on the N900; First up is the SSH session to the server with Chromium and xvkbd installed on it; Code:
ssh -YC user@192.x.x.x Then with the remote shell; Code:
chromium > /dev/null 2>&1 & Once both are open, go into the xvkbd GUI and type anything and press xvkbd's return, Chromium should accept this input, plus at this stage it will give the N900's own hardware keyboard focus of Chromium, so you can close xvkbd. As I say, it's far from elegant, but it's a workaround some of you may appreciate. https://i.imgur.com/kR0PATt.png |
Re: X forwarding to N900 with working hardware keyboard.
Okay, this qualifies as the crazy hack of the month! :p
|
Re: X forwarding to N900 with working hardware keyboard.
You should be able to get the same result with wmctrl and its -a or -R switch.
You'll still need to wait for the Chromium window to be rendered, but you won't have to close the xvkbd window afterwards. slightly off-topic: Combine this with a pocketable computer (some compute stick or a Zbox pico or a single-board computer) that is powered by a powerbank, and you should be able to offload any computing from the aged N900 to a relatively powerfull "server" at rather low costs in terms of money and mobility. For testing, any laptop will do that doesn't die due to overheating when stored running in your backpack. Im not sure about the optimal interface betweeen those two devices though. The obvious choice would be wifi, but you might need that for communicating with the outside world. A 2nd wifi adapter might be necessary. An alternative could be Bluetooth (PAN), but the N900 only supports BT 2.1, which severely limits the data rate to 2.1Mbit/s. |
Re: X forwarding to N900 with working hardware keyboard.
Quote:
|
Re: X forwarding to N900 with working hardware keyboard.
Quote:
|
Re: X forwarding to N900 with working hardware keyboard.
Interesting idea sulu, when X forwarded from a local machine it certainly seems a little quicker than the native browsers.
Regarding the USB; I would err on the side of caution and only have it connected when it's safely planted on a desk, sadly at that point it renders X forwarding moot, as I only plug the N900 into USB when I'm next to a perfectly usable desktop PC or similar. I think the use-case for X forwarding with a browser is to hand-off the CPU load and gain the security of a frequently updated browser. I have noticed that Luakit (a webkit & lua, w/ vi-binds browser) managed to capture the hardware keyboard of the N900 just fine with no fiddling, I didn't dig around to find why. At this point though it'd require some fettling as fonts were quite small... also Luakit receives infrequent commits, so something to be mindful of. I think it gets to a stage here of diminishing returns, but interesting to know it can be done. https://i.imgur.com/0yvDD0P.png |
Re: X forwarding to N900 with working hardware keyboard.
Quote:
but for jolla they are still in business, so you can just tell them that my usb port is broken after 1 year of usage and let them repair it or ask to give refund. |
Re: X forwarding to N900 with working hardware keyboard.
Quote:
I also found that some other applications (e.g. Stellarium or VBox) produce segfaults, when run via X forwarding from the N900. Then I remembered, that I have Presence VNC installed on my N900, so I created a Xephyr desktop with 800x480 pixels on $DISPLAY :2 of my desktop computer, started openbox and lxpanel on it and attached an x11vnc instance to it. To this I connected via Presence VNC and could run Chromium, Stellarium, a VBox VM and Libreoffice without actual problems. The display refresh lag was considerable though, with the bottleneck being the N900's wifi. So I'd say it's ok for pretty static window contents (most websites with a sane layout), but not for dynamic content (panning the view in Stellarium). If possible I'd still prefer X forwarding. Quote:
Also connecting both devices via USB would mean, you'd have a cable dangling from your N900 which I'd consider a limitation in mobility, either because you have to hold another device in your hands or because you're literally tied to whatever bag you store the other device in. |
All times are GMT. The time now is 00:53. |
vBulletin® Version 3.8.8