Author Topic: Change Keyboard layout for live USB  (Read 4621 times)

satm

  • Newbie
  • *
  • Posts: 3
    • View Profile
Change Keyboard layout for live USB
« on: July 22, 2014, 07:30:09 PM »
Hi all,
Being a recent Windows refugee, I am in the process of trying out several Linux distros.
I installed Wattos on a USB stick (with Unetbootin) and the OS loads just fine on my Easynote laptop. I really like the speed and cleanliness of Wattos but in order to test it some further I would like to be able to change the keyboard layout from US qwerty to BE azerty. Is there a way by adding a line in syslinux.cfg or in some other place? If so, what exactly do I have to add?
Thank you very much for your help

ourasi

  • Newbie
  • *
  • Posts: 4
    • View Profile
Re: Change Keyboard layout for live USB
« Reply #1 on: July 23, 2014, 06:05:25 AM »
This is what I used in Wattos 6 to change locale and keyboard layout to Finnish (part of syslinux.cfg):
Code: [Select]
label wattos1
  menu label wattos
  kernel /wattos/vmlinuz
  append  initrd=/wattos/initrd.gz locale=fi_FI.UTF-8 console-setup/layoutcode=fi live-media-path=/wattos/ boot=casper ignore_uuid --

I think those locale and console-setup/layoutcode commands are same with Debian based Wattos 8?

You can make your own customized Wattos 8 with Remastersys.
http://planetwatt.com/newforum/index.php?topic=37.msg368#msg368
« Last Edit: July 23, 2014, 06:09:46 AM by ourasi »

satm

  • Newbie
  • *
  • Posts: 3
    • View Profile
Re: Change Keyboard layout for live USB
« Reply #2 on: July 23, 2014, 08:48:01 AM »
Hi Ourasi,

I did try your recommendtions but no luck, still the qwerty keyboard.
Maybe it has something to do with running als live system from usb indtead of from cd.
By the way, I'm using microwatt.
My syslinux is quite different from yours.
The first entry is the default one created by Unetbootin, the second (test) is my adaptation.

label unetbootindefault
menu label Default
kernel /ubnkern
append initrd=/ubninit boot=live config quiet persistent

label test
menu label test
kernel /ubnkern
append initrd=/ubninit boot=live locale=be_FI.UTF-8 console-setup/layoutcode=be config quiet persistent


My intention was to try out the distro without first installing it to hd.
Anyway, thanks again for your time and help!

satm

  • Newbie
  • *
  • Posts: 3
    • View Profile
Re: Change Keyboard layout for live USB
« Reply #3 on: July 26, 2014, 12:12:38 PM »
After some more testing with syslinux.cfg I cannot get Wattos te recognise my Azerty keybord.
A pity and a bit strange, in most other distro's, working in live CD or live USB mode, changing the keyboard is quite easy.
I suppose that when installing to hard disk, Wattos gives us the choice of keyboard layout but I did want to test in live mode. I do not want to mess with my one and only hd yet.
So I'll move on and test some other live distros.
Good luck with Wattos to all of you!


teejay

  • wattOS Veteran
  • Sr. Member
  • ****
  • Posts: 80
    • View Profile
Re: Change Keyboard layout for live USB
« Reply #4 on: August 02, 2014, 12:34:15 AM »
@satm : in your test code, you had :
 append initrd=/ubninit boot=live locale=be_FI.UTF-8 console-setup/layoutcode=be config quiet persistent

Is the FI a residual from Ourasi's code ?    ie FI for Finnish

Since I don't have your need, I haven't explored the extent of kbd layouts in wattOS R8 iso s, but I have found with multiple distros that it is important when installing to get the language setup correctly as well as the location.  For me, failing to change the language to en_au (ie Australia) causes multiple irritants which are a pain to fix manually.    Hence it's important to check that the language is set correctly as well as locale and keyboard. 
There were discussions in Debian forums - as I said, I found the solutions didn't always work for me - getting the language correct did.

You might be interested in the following which directly addresses a Belgian keyboard on a live image.
  http://superuser.com/questions/659247/installing-different-keyboard-layout-on-live-debian-image



PCNetSpec

  • Guest
Re: Change Keyboard layout for live USB
« Reply #5 on: August 02, 2014, 04:11:07 PM »
As you say you're after be (azerty).....

Code: [Select]
cat /usr/share/X11/xkb/rules/xorg.lst | grep Belgianreturns:-
Code: [Select]
  be              Belgian
  oss             be: Belgian (alternative)
  oss_latin9      be: Belgian (alternative, Latin-9 only)
  oss_sundeadkeys be: Belgian (alternative, Sun dead keys)
  iso-alternate   be: Belgian (ISO alternate)
  nodeadkeys      be: Belgian (eliminate dead keys)
  sundeadkeys     be: Belgian (Sun dead keys)
  wang            be: Belgian (Wang model 724 azerty)

So if you're after "be wang" .. does:
Code: [Select]
setxkbmap be wanggive you the layout you want ?

or does just:
Code: [Select]
setxkbmap bedo it ?

Be Aware, that will NOT survive a reboot .. just want to know if it gives you the layout you're after.



Once you know the command you want, you could always (on a persistent LiveUSB) either save it to
/etc/default/keyboard
as say
XKBLAYOUT="be wang"

or create a launcher in
~/.config/autostart
with an "Exec=" line similar to:
Exec=bash -c "setxkbmap be"
« Last Edit: August 02, 2014, 04:25:06 PM by PCNetSpec »