Can you turn off Pipeline in ARM Cortex M3

The keyboard scan codes are built into the keyboard - they are reported on USB, PS/2, Bluetooth, or whatever other interface is used. Then it is up to the software controlling it to interpret the scan codes in the way it wants.

Simple software, such as the BIOS, only does simple handling - typically not supporting different keyboard layouts.

DOS and Windows support a variety of layouts, which is chosen by configuration of the OS - it is completely independent of the BIOS, and of whatever keys happen to be on the keyboard. The US keyboard layout on Windows is pretty simplistic - amongst other things it makes little distinction between the left and right Alt keys (though only the right one works with the numeric keypad for entering ASCII/utf codes), and it has no support for dead keys.

Many international keyboard layouts are a bit more sophisticated, with a separation between Alt and AltGr (right-hand Alt) which lets you use the normal Alt for menu shortcuts, etc., and the right-hand AltGr to get more symbols, accents or letters required for other languages. They also generally support dead keys.

A dead key is one that does not generate any character when pressed, until you press another key. For example, in many layouts the backtick ` is a dead key. Pressing it does not produce anything unless you follow it with a space or a new ` to get a ` symbol. But if you follow

More advanced software, such as X, support much more configurable keyboard setups, and many more accessible characters.

Reply to
David Brown
Loading thread data ...

here's a danish keyboard, all the blue symbols are made with ALT-GR

formatting link

the left ALT doesn't do the same

i believe all most all the keys have separate scan code, so if you wanted to you could make left and right shift or ctrl key do something different

-Lasse

Reply to
lasselangwadtchristensen

Am 11.09.2015 um 06:04 schrieb rickman:

Then you're using the plain US-american keyboard layout. This is great for programming because all of []{}() and \| are easy to reach.

It's not so great for entering text in languages other than English

All this is the reason PC's have had localized keyboard layouts since just about forever. Many of these have one or two more keys than the US' 101. But that's not sufficient to accomodate all those accents and special characters. So at some point, the non-English special keys will squeeze some (presumably) not-so-frequently used keys off the layout. Typical victims of this include []{}\|~# and @.

International layouts have to routinely sacrifice the right Alt keys' original function to provide a secondary "shift" function that gives back access to those characters which got squeezed off the original layout. E.g. on the German layout, to get \ one can either type

Alt is relabeled AltGr (for "alternative graphic characters" or something like that). One consequence is that the Alt+ only work with the left Alt key on these layout.

Incidentally, this makes typing C source on non-US PC keyboards a royal pain, particularly if you've mastered touch typing. IMHO it qualifies as a miracle that any working C code was ever written in Belgium or Switzerland :-)

Reply to
Hans-Bernhard Bröker

I wonder now if the keyboard was part of the reason that Pascal family languages remained popular in Europe much longer than they did in the US.

George

Reply to
George Neuner

I was around when Pascal got supplanted by 'C' in the U.S. I think Borland sank Pascal when they went to a 'C' offering. But they were chasing Microsoft.

We have to be careful, because there's always observer bias. But 'C' had semi-legendary status back to when I was in school in the early '80s without the ability to use 'C'.

The tribe I was with went first to MSC then to Borland, a lot because of Paradigm Locate and how well it worked with Borland tools to produce ROMable images.

Side note: I got handed a Netburner a year or two ago, which still uses the Borland tool chain. I maxed out the available memory on the second day* and gave up :) The symptom was a complete latchup of the target. The weary support person had the solution far too ready.

*application already ran on a big ARM platform.

The old days weren't so good :)

--
Les Cargill
Reply to
Les Cargill

You get used to it quickly - I found it a slight inconvenience for a few weeks when I moved to Norway, but not more than that. It was actually not the {[]} symbols, that need the AltGr key on a Norwegian layout, that were the most annoying. It is the shifted symbols above the number keys that are worst (at least when I now occasionally have to deal with a US or UK layout).

And there is the odd program around whose developers think the world ends at the borders of the USA, and can't cope when the keyboard layout is different. But fortunately those are rare.

Reply to
David Brown

No, that would have absolutely nothing to do with it. It is not hard to type {} on non-US keyboards - it is certainly quicker and shorter than typing begin/end. And despite the myth that many design decisions in C were because of the terrible DEC keyboards used by K&R, such considerations are totally insignificant in choosing a language. (Except for APL, of course.)

Reply to
David Brown

Same here.

But languages evolve and I have always wondered why some of the more capable family members didn't generate more interest.

Apple pushed Object Pascal quite hard with Lisa and Mac. It was a number of years before they made C available [as an Apple product - there were Macintosh C compilers available from other vendors. I don't ever recall seeing C for the Lisa].

I really liked Modula 3. I know Wirth himself had nothing to do with it, but it was based on (extended) Modula 2 and I consider it to be in the Pascal family [a cousin maybe].

I'm not sure I really agree with that. They continued to work on and improve Pascal long after they introduced the C compiler.

I think the problem far more was delay in offering a decent Pascal for Windows ... TPW on Windows 3 was horrible. It took them 6 years to bring out Delphi and although it could [theoretically] run on Windows

3 or 95, it was unstable on those systems and really needed NT4 to do serious work. For quite a while there was no low-cost starter version, so until Win98 came along, Delphi effectively excluded many students and hobbyists.

I don't recall other Pascals being available for Windows early on, so Borland's mis-steps there certainly can be credited with Pascal's demise. I just don't think their offering C had quite so much to do with it. YMMV.

George

Reply to
George Neuner

Source code is intended to be read by humans as well as by compilers. I use C because employers will pay me to do so, not because I particularly like it. All of C's power [and then some] is available in languages that are safer to use and don't look so much like line noise. That may not have been true in 1975 [though I could make a case that it was], but it certainly was true by 1985.

George

Reply to
George Neuner

Beats me. But I don't consider Pascal that vast an improvement over 'C'. No disrespect to Wirth, but I disagree with his complaints about that.

Agreed - but I never saw any interest in it. There was a short span of time where I could be on a project that mixed 68000 and x86, and the most sensible thing seemed to be 'C' for that.

Excellent point - I sort of recall that now. I had one contact who used Delphi and he'd complained about this.

It never made sense to me that it should be unstable.

It's probably observer bias on my part - the people I knew who could decide between Pascal and 'C' weren't writing GUI applications and 'C' was the better choice for systems work.

--
Les Cargill
Reply to
Les Cargill

Am 12.09.2015 um 14:34 schrieb David Brown:

I find it enough of one to have my German keyboard set to US layout for everything but writing actual German prose. Drives colleagues crazy if they want to type something on my machine, too ;-). In my student years I even used actual US keyboards both at home and on the university's machines.

At least on the German layout, the AltGr and {[]} are really in the worst position they could possibly have picked, from a touch typing point-of-view. Given where AltGr is located, you can't really keep your right hand in home position; the thumb just won't go there. And once

{[]}\ is just too error-prone to be acceptable. Typing those [] alone sometimes took longer than all the stuff that went in between them!

Absolutely. Why on earth are the () Shift+8 and Shift+9 on a German layout, but Shift+9 and Shift+0 in US?

Reply to
Hans-Bernhard Bröker

Reply to
Dimiter_Popoff

During my years in Germany (20+years ago) I had a US layout keyboard. When I had to use some of the PC-s at the company I had learned how to switch off the German layout, was something like alt-f1 or alt-ctrl-f2 (or completely different, I may have forgotten it altogether). The keys were coming to their normal places which was good enough for me, although many did not correspond to the key caps... Obviously I used these keyboards rarely and for short tasks. I never got used to the German layout; and I think the French one is even worse.

Dimiter

(sorry for the null message I posted - was just beginning to write what was supposed to be this one and inadvertently hit "send").

Reply to
Dimiter_Popoff

That's fair enough as an argument. There is plenty in C that I don't like. To paraphrase Churchill, C is the worst of all programming languages - but it's the best we've got.

I just disagree with the theory that keyboard layouts had any say in the matter.

Reply to
David Brown

Shift+8 and Shift-9 date back to earlier (19th century, Remington?) keyboard layouts, which in turn influenced ASCII.

Shift+9 and Shift-0 come from the IBM Selectric (early '60s). According to this Wikipedia article:

formatting link
"This change was made because smaller characters hit the paper with less force, and consolidating smaller characters such as '" into a pair on a single key avoided needing to adjust the force based on shift state."

Regards, Allan

Reply to
Allan Herriman

Tradition/history in both places. I've seen typewriters from the early 20th century from both countries with the 8/9 and 9/0 placement of the parenthesis. Of course those were not completely standardized, so you can find exceptions for both.

Reply to
Robert Wessel

Conveniently Windows at least since XP installs the US keyboard layout and has a quick key to switch layouts. People do tend to cling to the various awful national layouts like a baby to a mother's teat but really a proper layout is easily toggled into and back out of for when one writes in their native language. Same thing in at least the bigger Linux desktops.

Reply to
Anssi Saari

ElectronDepot website is not affiliated with any of the manufacturers or service providers discussed here. All logos and trade names are the property of their respective owners.