An update on my earlier post of 2012.
Driver 1.1.62 (15 May 2016) is now available at http://www.displaylink.com/downloads/ubuntu and does not require any fixups for wrong USB vendor ID numbers, or patches for kernels > 4.5.0
For my HP displaylink hub I have:
/etc/udev/rules.d/50-displaylink.rules:
# DisplayLink devices always have the active configuration on configuration #1
ATTR{idVendor}=="17e9", ATTR{idProduct}=="01d4", RUN+="/usr/bin/dlconfig"
and /usr/bin/dlconfig:
#! /bin/bash
echo 1 > "/sys/$DEVPATH/bConfigurationValue"
However, I must insert the USB device AFTER logging into to X or I get two fb devices added, one owned by udl and one by evdi. I suspect this is a race condition problem.
In any case, none of it works for me -- I'm not able to view anything at all on the frame buffer. I guess my USB device is too old.
However, if I modprobe udlfb and ignore the evdi drivers, and udl then I at least get a working framebuffer that can display images with fbi. -- but the colour depth is stuck at 16.
I'm able to use it as a primary device for an X11 session with this /etc/X11/xorg.conf
Section "ServerLayout"
Identifier "X.org Configured"
Screen 0 "Screen0" 0 0
InputDevice "Mouse0" "CorePointer"
InputDevice "Keyboard0" "CoreKeyboard"
EndSection
Section "Files"
ModulePath "/usr/lib/xorg/modules"
FontPath "/usr/share/fonts/X11/misc"
FontPath "/usr/share/fonts/X11/cyrillic"
FontPath "/usr/share/fonts/X11/100dpi/:unscaled"
FontPath "/usr/share/fonts/X11/75dpi/:unscaled"
FontPath "/usr/share/fonts/X11/Type1"
FontPath "/usr/share/fonts/X11/100dpi"
FontPath "/usr/share/fonts/X11/75dpi"
FontPath "built-ins"
EndSection
Section "Module"
Load "glx"
EndSection
Section "InputDevice"
Identifier "Keyboard0"
Driver "kbd"
EndSection
Section "InputDevice"
Identifier "Mouse0"
Driver "mouse"
Option "Protocol" "auto"
Option "Device" "/dev/input/mice"
Option "ZAxisMapping" "4 5 6 7"
EndSection
Section "Monitor"
Identifier "Monitor0"
VendorName "Monitor Vendor"
ModelName "Monitor Model"
EndSection
Section "Device"
Identifier "Card1"
Driver "fbdev"
BusID "USB"
Option "fbdev" "/dev/fb1"
Option "ReportDamage" "true"
EndSection
Section "Screen"
Identifier "Screen0"
Device "Card1"
Monitor "Monitor0"
DefaultDepth 16
SubSection "Display"
Viewport 0 0
Depth 1
EndSubSection
SubSection "Display"
Viewport 0 0
Depth 4
EndSubSection
SubSection "Display"
Viewport 0 0
Depth 8
EndSubSection
SubSection "Display"
Viewport 0 0
Depth 15
EndSubSection
SubSection "Display"
Viewport 0 0
Depth 16
EndSubSection
EndSection
Showing posts with label ubuntu. Show all posts
Showing posts with label ubuntu. Show all posts
Monday, 16 May 2016
Friday, 26 September 2014
shell-shocked: Updaing bash on Linux Mint Olivia
shell-shocked: Updaing bash on Linux Mint Olivia
I've go some old laptops running Linux Mint, Olivia release, based on Ubuntu Raring Ringtail which is not a long term support, and so no ready fix is available.The bug is shown with this test
rm -f echo ; env X='() { (a)=>\' bash -c "echo date"; cat echo bash: X: line 1: syntax error near unexpected token `=' bash: X: line 1: `' bash: error importing function definition for `X' Fri Sep 26 09:37:44 BST 2014which wrongly creates a file called echo holding the output of the date command.
Here is what is required to fix the bash shell-shocked bug.
1. Update the no-longer supported repositories to the new location:
(You should already have done this).You first need to make sure you have src-deb repositories enabled:
cd /etc/apt/sources.list.d/ test -r official-source-repositories.list || cp official-package-repositories.list official-source-repositories.list && sed -i -e 's/raring/trusty/g;s/^deb /^deb-src/' official-source-repositories.listAnd then update the server to old-releases:
sed -i -e 's/archive.ubuntu.com\|security.ubuntu.com/old-releases.ubuntu.com/g' official-package-repositories.list apt-get update
2. Install all updates for your system anyway
apt-get update apt-get upgrade
3. Build bash from the trusty sources
apt-get build-essential bash apt-get -b source bash
4. Install bash
dpkg -i bash*deb
5. Test the fix
# rm -f echo ; env X='() { (a)=>\' bash -c "echo date"; cat echo bash: X: line 1: syntax error near unexpected token `=' bash: X: line 1: `' bash: error importing function definition for `X' date cat: echo: No such file or directory
Tuesday, 26 August 2014
Google TV & Movies DRM on Mint/Ubuntu
Google Play Movies & TV works best under Chrome on Linux, but unless HTML5 is working for you, Flash is needed for playback and DRM Flash playback requires the long since deprecated HAL.
Fortunately an updated HAL is maintained for this purposes. The hal ppa is at:
https://launchpad.net/~mjblenner/+archive/ubuntu/ppa-hal
Most of these details are thanks to Justin Watt at askubuntu.com/questions/166760/how-do-i-play-movies-on-google-play who says:
Fortunately an updated HAL is maintained for this purposes. The hal ppa is at:
https://launchpad.net/~mjblenner/+archive/ubuntu/ppa-hal
Most of these details are thanks to Justin Watt at askubuntu.com/questions/166760/how-do-i-play-movies-on-google-play who says:
sudo add-apt-repository ppa:mjblenner/ppa-ha
sudo apt-get update
sudo apt-get install hal
cd ~/.adobe/Flash_Player
rm -rf NativeCache AssetCache APSPrivateData2
Wednesday, 19 March 2014
NFS/LDAP only at home
NOTE: This doesn't work reliable for only some users. It seems like nsswitch.conf needs faking earlier than that. A better answer might be to iptables-rst the ldap requests or something so that ldap fails quickly.
I have this pre-init script in /etc/init/autofs.conf
and these lines in my /etc/nsswitch.conf
When I'm on my home wireless network (detected by the access-point mac address, autofs will run to mount home directories, and ldap will be enabled and used to validate user accounts.
Otherwise it is a standalone laptop and will revert to built in accounts and home directories.
I have this pre-init script in /etc/init/autofs.conf
start on runlevel [2345] and net-device-up IFACE=wlan0 ... pre-start script modprobe -q autofs4 || true if iwconfig | grep 00:18:84:26:7E:1B then sed -e 's/ #ldap/ ldap/' /etc/nsswitch.conf > /var/tmp/nsswitch.conf && mount /var/tmp/nsswitch.conf /etc/nsswitch.conf -o bind else ! true fi end script
and these lines in my /etc/nsswitch.conf
passwd: compat #ldap group: compat #ldap shadow: compat #ldap
When I'm on my home wireless network (detected by the access-point mac address, autofs will run to mount home directories, and ldap will be enabled and used to validate user accounts.
Otherwise it is a standalone laptop and will revert to built in accounts and home directories.
Friday, 11 January 2013
Fix Charging on Acer ZG5
My Acer One ZG5 was not charging for the last year or so. I took it for repair to my local friendly and trusted Wizard Electronics but the chap there was too wise. Armed with the knowledge that it failed to charge two different batteries but yet would boot up under charger power he could conclude quite well that it was not the charger, the connector or the batteries and some troubleshooting on the system board was required. I already knew this of course which was why I took it to him; but he suggested it would be cheaper to replace the main board and a quick look at ebay prices for smashed screen netbooks showed that he was right.
However, to my surprise, while googling to find what the motherboard fault might be I found a clue that it might be (and was!) fixed with a BIOS update! http://www.acer.com/worldwide/support/download.htm and one version 3110 release later and I was charging both batteries again!
However, to my surprise, while googling to find what the motherboard fault might be I found a clue that it might be (and was!) fixed with a BIOS update! http://www.acer.com/worldwide/support/download.htm and one version 3110 release later and I was charging both batteries again!
Acer Aspire SD slots on bootup
My jmicron SD card slots not being recognized by Linux Mint unless a card was in the slot when booted. And there were two slots.
Tricks here http://ubuntuforums.org/showpost.php?p=10842957&postcount=62 that use
rebooting, and running:
Nothing else was required; no use of
early hacks
This post http://ubuntuforums.org/showpost.php?p=10842957&postcount=62 shows a way that works for me to re-scan and detect slots that now have a card in (although the card may need to be removed and re-inserted).
sudo echo 1 > /sys/bus/pci/rescan
Tricks here http://ubuntuforums.org/showpost.php?p=10842957&postcount=62 that use
setpci
don't work for me, failing to select the device if it isn't already detected, or the pciehp
driver which doesn't seem to be present on my installation.Success
I got auto-detection to work by following these tips https://bugs.launchpad.net/ubuntu/+source/linux/+bug/258446/comments/61 by adding the following files to/etc/modules
pciehp
acpiphp
jmb38x_ms
sdhci-pci
flash_bd
xd_card
jmb38x_xd
rebooting, and running:
update-initramfs -u
so that those modules would be built in to the ramdisk; and then rebooting again.Nothing else was required; no use of
pciehp
, no edit of /etc/default/grub.conf
and no creation of files in /etc/modprobe.d/
Friday, 7 December 2012
Media Buttons on Mint 14 Nadia
Sadly keyboard multi-media control buttons still have no effect on Mint 14 when logged in using the Gnome2 fork Mate desktop.
Gladly, Matteo Italia has written a short python script to convert the DBUS events into MPRIS2 events.
http://pastebin.com/N0Jv2W5Y
Start the script on login and media keys work! Thanks Matteo
Gladly, Matteo Italia has written a short python script to convert the DBUS events into MPRIS2 events.
http://pastebin.com/N0Jv2W5Y
Start the script on login and media keys work! Thanks Matteo
#!/usr/bin/env python
'''
Created on 30.05.2012
@author: Matteo Italia <mi_1@mitalia.net>
'''
import dbus
import dbus.mainloop.glib
import gobject
app_name = 'mmkeys-mate2mpris2'
Version=0.1
MediaKeysObjName = 'org.mate.SettingsDaemon'
MediaKeysObjectPath = '/org/mate/SettingsDaemon/MediaKeys'
MediaKeysInterface = 'org.mate.SettingsDaemon.MediaKeys'
MPRIS2Prefix = 'org.mpris.MediaPlayer2'
ActionMappings = {
'Play': 'PlayPause',
'Pause': 'Pause',
'Stop': 'Stop',
'Next': 'Next',
'Previous': 'Previous'}
def onMediaKeyPress(app_name, action):
sb = dbus.SessionBus()
# Get the compatible players
players = [n for n in sb.list_names() if n.startswith(MPRIS2Prefix + ".") ]
# Send them the command
for n in players:
# TODO: it doesn't make sense to perform the action on *all* the players!
# find a sensible criterion to choose the "best one"
sb.get_object(n, '/org/mpris/MediaPlayer2').__getattr__(ActionMappings[action])()
if __name__ == '__main__':
# DBUS boilerplate
dbus.mainloop.glib.DBusGMainLoop(set_as_default=True)
sb = dbus.SessionBus()
# Get the media keys notificator object
mediaKeysObj = sb.get_object(MediaKeysObjName, MediaKeysObjectPath)
# Register to receive media keys notifications
mediaKeysObj.GrabMediaPlayerKeys(app_name, 0, dbus_interface=MediaKeysInterface)
mediaKeysObj.connect_to_signal('MediaPlayerKeyPressed', onMediaKeyPress)
# Start the main loop
mainLoop = gobject.MainLoop()
mainLoop.run()
Thursday, 2 February 2012
HP Displayport Adaptor on Mint or Ubuntu
[Note: updated information here]
I post a correction on these notes: http://libdlo.freedesktop.org/wiki/DeviceQuirks which over-specify /sys (as well as hard-wiring it) as well as bConfigurationValue.
/usr/bin/dlconfig:
/etc/udev/rules.d/60-displaylink.rules
# DisplayLink devices always have the active configuration on configuration #1
SYSFS{idVendor}=="17e9", SYSFS{bConfigurationValue}=="2", RUN+="/usr/bin/dlconfig %S%p"
These cause the VGA adaptor to be intialized properly on each insert.
I post a correction on these notes: http://libdlo.freedesktop.org/wiki/DeviceQuirks which over-specify /sys (as well as hard-wiring it) as well as bConfigurationValue.
/usr/bin/dlconfig:
#! /bin/bash
if [ -e "$1"/device/bConfigurationValue ]; then
echo 1 > "$1"/device/bConfigurationValue
fi;
if [ -e "$1"/bConfigurationValue ]; then
echo 1 > "$1"/bConfigurationValue
fi;
/etc/udev/rules.d/60-displaylink.rules
# DisplayLink devices always have the active configuration on configuration #1
SYSFS{idVendor}=="17e9", SYSFS{bConfigurationValue}=="2", RUN+="/usr/bin/dlconfig %S%p"
These cause the VGA adaptor to be intialized properly on each insert.
Wednesday, 9 November 2011
Goodbye Ubuntu - probably
Ubuntu has been great. I've had years of top-notch software, for free, and with access to the source code which I have had to hack about from time to time.
But it may be time to say goodbye. Ubuntu's direction is entirely their concern but it is getting in my way.
So if I can't like it, and I don't want to lump it, I may have to leave it.
The Ubuntu/gnome strategy seems to be to replace a nearly-done application with a much less done application which will catch up real soon.
For instance:
And then there are problems with using launchpad their issue-tracker. The typical ubuntu bug-report scenario is like like this:
Ubuntu use of launchpad seems designed to disuade people from using launchpad. Rather than the point of "report all bugs" it is the point of "being insulted for reporting any bug".
In an effort to fix this (it seems) bug reports are now automatically closed if no-one from the Ubuntu team has responds in an arbitrary the time-frame.
What makes it worse is that Shuttleworth abandoned his bug-bounty idea; so it is impossible for individual users financially support Canonical or Ubuntu, or get support or contribute to support on issues that matter.
Individual users (non-enterprise customers) are reduced to the level of beggars who can contribute if they don't mind being insulted by launchpad. But any value in the contributions will likely leak away through inaction.
I like ubuntu but they don't like me, and there is no way to pay them any money as I'm not corporate enough to be worth bothering with.
I think that Mint is where it is at; while ubuntu is "debian done nicely" - Mint seems to be: "ubuntu with the bugs actually fixed"
so long, and thanks for all the fish.
It's been really great, and if it's been mostly one-way, it's not for want of trying.
But it may be time to say goodbye. Ubuntu's direction is entirely their concern but it is getting in my way.
So if I can't like it, and I don't want to lump it, I may have to leave it.
The Ubuntu/gnome strategy seems to be to replace a nearly-done application with a much less done application which will catch up real soon.
For instance:
- gthumb image viewer gets replaced with eog (eye-of-gnome) which can't print more than one photo to a page
- rhythmbox gets replaced with banshee
- beagle gets replaced with tracker
- gnome 3 shell gets replaced with unity
- tomboy gets replaced with gnote
And then there are problems with using launchpad their issue-tracker. The typical ubuntu bug-report scenario is like like this:
- file a bug
- wait 1-2 years
- bug gets marked as invalid
This doesn't mean it isn't a valid bug, it means the bug team can't/won't work with it - perhaps because the person who reported the bug got a new computer after a couple of years, and so wouldn't be able to confirm if a fix was ever released. - If you are lucky, the bug was fixed upstream and you may get the fix in a future Ubuntu release, along with some different long-term bugs.
Ubuntu use of launchpad seems designed to disuade people from using launchpad. Rather than the point of "report all bugs" it is the point of "being insulted for reporting any bug".
In an effort to fix this (it seems) bug reports are now automatically closed if no-one from the Ubuntu team has responds in an arbitrary the time-frame.
What makes it worse is that Shuttleworth abandoned his bug-bounty idea; so it is impossible for individual users financially support Canonical or Ubuntu, or get support or contribute to support on issues that matter.
Individual users (non-enterprise customers) are reduced to the level of beggars who can contribute if they don't mind being insulted by launchpad. But any value in the contributions will likely leak away through inaction.
I like ubuntu but they don't like me, and there is no way to pay them any money as I'm not corporate enough to be worth bothering with.
I think that Mint is where it is at; while ubuntu is "debian done nicely" - Mint seems to be: "ubuntu with the bugs actually fixed"
so long, and thanks for all the fish.
It's been really great, and if it's been mostly one-way, it's not for want of trying.
Subscribe to:
Posts (Atom)