Announcement

Collapse

Forum etiquette

Our mission ...

This forum is part of our mission to promote the preservation of vintage computers through education and outreach. (In real life we also run events and have a museum.) We encourage you to join us, participate, share your knowledge, and enjoy.

This forum has been around in this format for over 15 years. These rules and guidelines help us maintain a healthy and active community, and we moderate the forum to keep things on track. Please familiarize yourself with these rules and guidelines.


Remain civil and respectful

There are several hundred people who actively participate here. People come from all different backgrounds and will have different ways of seeing things. You will not agree with everything you read here. Back-and-forth discussions are fine but do not cross the line into rude or disrespectful behavior.

Conduct yourself as you would at any other place where people come together in person to discuss their hobby. If you wouldn't say something to somebody in person, then you probably should not be writing it here.

This should be obvious but, just in case: profanity, threats, slurs against any group (sexual, racial, gender, etc.) will not be tolerated.


Stay close to the original topic being discussed
  • If you are starting a new thread choose a reasonable sub-forum to start your thread. (If you choose incorrectly don't worry, we can fix that.)
  • If you are responding to a thread, stay on topic - the original poster was trying to achieve something. You can always start a new thread instead of potentially "hijacking" an existing thread.



Contribute something meaningful

To put things in engineering terms, we value a high signal to noise ratio. Coming here should not be a waste of time.
  • This is not a chat room. If you are taking less than 30 seconds to make a post then you are probably doing something wrong. A post should be on topic, clear, and contribute something meaningful to the discussion. If people read your posts and feel that their time as been wasted, they will stop reading your posts. Worse yet, they will stop visiting and we'll lose their experience and contributions.
  • Do not bump threads.
  • Do not "necro-post" unless you are following up to a specific person on a specific thread. And even then, that person may have moved on. Just start a new thread for your related topic.
  • Use the Private Message system for posts that are targeted at a specific person.


"PM Sent!" messages (or, how to use the Private Message system)

This forum has a private message feature that we want people to use for messages that are not of general interest to other members.

In short, if you are going to reply to a thread and that reply is targeted to a specific individual and not of interest to anybody else (either now or in the future) then send a private message instead.

Here are some obvious examples of when you should not reply to a thread and use the PM system instead:
  • "PM Sent!": Do not tell the rest of us that you sent a PM ... the forum software will tell the other person that they have a PM waiting.
  • "How much is shipping to ....": This is a very specific and directed question that is not of interest to anybody else.


Why do we have this policy? Sending a "PM Sent!" type message basically wastes everybody else's time by making them having to scroll past a post in a thread that looks to be updated, when the update is not meaningful. And the person you are sending the PM to will be notified by the forum software that they have a message waiting for them. Look up at the top near the right edge where it says 'Notifications' ... if you have a PM waiting, it will tell you there.

Copyright and other legal issues

We are here to discuss vintage computing, so discussing software, books, and other intellectual property that is on-topic is fine. We don't want people using these forums to discuss or enable copyright violations or other things that are against the law; whether you agree with the law or not is irrelevant. Do not use our resources for something that is legally or morally questionable.

Our discussions here generally fall under "fair use." Telling people how to pirate a software title is an example of something that is not allowable here.


Reporting problematic posts

If you see spam, a wildly off-topic post, or something abusive or illegal please report the thread by clicking on the "Report Post" icon. (It looks like an exclamation point in a triangle and it is available under every post.) This send a notification to all of the moderators, so somebody will see it and deal with it.

If you are unsure you may consider sending a private message to a moderator instead.


New user moderation

New users are directly moderated so that we can weed spammers out early. This means that for your first 10 posts you will have some delay before they are seen. We understand this can be disruptive to the flow of conversation and we try to keep up with our new user moderation duties to avoid undue inconvenience. Please do not make duplicate posts, extra posts to bump your post count, or ask the moderators to expedite this process; 10 moderated posts will go by quickly.

New users also have a smaller personal message inbox limit and are rate limited when sending PMs to other users.


Other suggestions
  • Use Google, books, or other definitive sources. There is a lot of information out there.
  • Don't make people guess at what you are trying to say; we are not mind readers. Be clear and concise.
  • Spelling and grammar are not rated, but they do make a post easier to read.
See more
See less

Arduino PS2 to XT converter

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    #31
    So every AT keyboard has an XT mode, but it lacks of a switch or something to use that mode, is that what you say?

    Comment


      #32
      Originally posted by irix View Post
      So every AT keyboard has an XT mode, but it lacks of a switch or something to use that mode, is that what you say?
      It... half has the mode. It can be programmed to output the correct scancodes, but it still does so using the AT wiring and transmission protocol. All mode 1 does is change what scancodes it spits out, not how it spits them out.

      On the keyboards that have the switch, they likely force the keyboard into mode 1 for the scancodes, and then use the different output protocol as well. Setting mode 1 from software doesn't change the AT protocol itself -- it's still 11 bits bidirectional with release being a prefixed command code instead of stored on bit 7.

      Still, setting that mode will GREATLY simplify the process and reduce the memory footprint, as the whole lookup table thing can be pitched.
      From time to time the accessibility of a website must be refreshed with the blood of owners and designers. It is its natural manure.
      CUTCODEDOWN.COM

      Comment


        #33
        As told in a previous post I do have a few Samsung keyboards (they look like IBM). They're with a simple membrame though, but they do have the full Intel cpu on board and a hole where the AT/XT switch could have been. Also on the small pcb in the keyboard there are holes and lines where the switch would have been.
        They have 5p regular DIN though, not ps/2. Also when I connect the 2 empty pins (where the switch would have been) it doesn't directly work, but it may change the mode though. Don't know how to test that.

        Comment


          #34
          Seems like a fun project/challenge, but it it is for a real IBM 5160 PC/XT, wouldn't it just be easier to pop in a pair of BIOS chips with the 5/86 bios or flash one, which provided native PS/2 keyboard support rather than go through all of this, or just get a 5160 MOB with the right BIOS?

          Mike

          Comment


            #35
            I believe that the 1000's protocol is almost identical to the XT protocol except for the timing and the use of a stop bit as opposed to a start bit. Have you ever looked into it deathshadow?

            I do not believe that the 5160 can really handle the 11-bit AT/PS2 protocol. The 1986 IBM PC/XT Technical Reference indicates it uses the 9-bit XT protocol, so you still need a keyboard that can switch between the two.
            My Retro Computing and Vintage Gaming Blog : http://nerdlypleasures.blogspot.com/

            Comment


              #36
              Originally posted by irix View Post
              Also when I connect the 2 empty pins (where the switch would have been) it doesn't directly work, but it may change the mode though. Don't know how to test that.
              It probably does not -- when they omit the switch they usually cheap out with a smaller ROM, leaving off the code required to output the 10 bit (that people call 9 bit) monodirectional XT data format instead of the 11 bit AT format.

              Originally posted by nc_mike View Post
              but it it is for a real IBM 5160 PC/XT, wouldn't it just be easier to pop in a pair of BIOS chips with the 5/86 bios or flash one, which provided native PS/2 keyboard support rather than go through all of this, or just get a 5160 MOB with the right BIOS?
              1) Pretty sure a 286 BIOS isn't gonna fly on a 8088.

              2) PC/XT's hardware interface is monodirectional -- System side is read only. AT interface is bidirectional and requires an ACK bit to be set to function properly. The two aren't just different scancodes and bit encoding, the hardware interfaces themselves are fundamentally different!

              Pretty sure the PC/XT hardware would be incapable of even acknowledging the AT keyboard's power on and test ok message, much less setting the mode or ack bits.

              3) AT's have a intel 8048 processor dedicated to handling the keyboard input. The PC/XT uses a shift-in parallel out chip along with a 8255. Not even close to the same hardware.

              So no, it would not be "easier" -- much less how is burning a ROM and installing it easier?!? Much less that's ASSUMING you know what you are plugging it into, which I can't guarantee since I've got three XT clones here and one keyboard -- and christmas only knows what the clones did or what ROM's they'd be compatible with.

              I swear, every time someone uses the word "easier" I start to think I have an entirely different definition of the word from the rest of the world!

              Originally posted by Great Hierophant View Post
              I believe that the 1000's protocol is almost identical to the XT protocol except for the timing and the use of a stop bit as opposed to a start bit. Have you ever looked into it deathshadow?
              It's on my to-do list. Since I've got a perfectly good working 1000SX keyboard here, I'll be able to investigate what it REALLY outputs since again, the data I'm finding online doesn't make sense and/or doesn't seem to line up with reality... though the most complete and accurate data (which is still pretty inaccurate) seems to be about going the other direction; from every other type of keyboard to AT which... doesn't seem to me like the most useful of things to do.

              I'm also thinking on seeing what I can figure out about the Junior... if any computer ever desperately needed some lovin' from a model M...

              But... PC/XT first. I'm actually having trouble reading from the AT interface side of things reliably. None of the code I have that claims to work is doing a damned thing, nor is my own code... I can read it fine with my little homebrew scope, but in terms of translating it into useful data it goes tits up to the point of the DCCduino going off to never never land.

              Gonna try reading it using a teensy instead. Be a laugh if my one dollar Arduino nano knockoff is the actual stumbling block. You'd THINK Atmega 328p is Atmega 328p... but NO... (and yes, it's a newer one with the CH430, not the old FTDI knockoff that the driver updates now brick!)
              From time to time the accessibility of a website must be refreshed with the blood of owners and designers. It is its natural manure.
              CUTCODEDOWN.COM

              Comment


                #37
                What do you mean "Pretty sure a 286 BIOS isn't gonna fly on a 8088"? I've got the 5/86 BIOS in my IBM 5160 PC/XT and use a PS/2 keyboard - an IBM Model-M with the optional 5 pin DIN connector instead of the PS/2 connector, attached to my IBM PC/XT system and it works beautifully with no other mods needed. The 5/86 BIOS was the last native IBM BIOS update for PC/XTs that added support for 101-key PS/2 style keyboards. I don't understand your statement - can you please clarify?

                NC_Mike

                Comment


                  #38
                  Originally posted by nc_mike View Post
                  What do you mean "Pretty sure a 286 BIOS isn't gonna fly on a 8088"? I've got the 5/86 BIOS in my IBM 5160 PC/XT and use a PS/2 keyboard - an IBM Model-M with the optional 5 pin DIN connector instead of the PS/2 connector, attached to my IBM PC/XT system and it works beautifully with no other mods needed. The 5/86 BIOS was the last native IBM BIOS update for PC/XTs that added support for 101-key PS/2 style keyboards. I don't understand your statement - can you please clarify?

                  NC_Mike
                  You are one of the lucky people to get an autosensing Model M which works with both XT and AT systems. Not all Model M keyboards do that.

                  Comment


                    #39
                    I have a Model M as well, but never tested it on an XT. How can I know if it does autosense? Just test, or can you see it (type number or something)

                    Comment


                      #40
                      It has nothing to do with autosenese, that is nonsense. Either your XT BIOS is late enough to support 101-key keyboards or or isn't. I have many IBM Model-M keyboards - they all work. You have to make sure you use a 5 pin DIN cord, and not use a PS/2 to 5-pin DIN adapter.

                      Mike

                      Comment


                        #41
                        Originally posted by nc_mike View Post
                        It has nothing to do with autosenese, that is nonsense. Either your XT BIOS is late enough to support 101-key keyboards or or isn't. I have many IBM Model-M keyboards - they all work. You have to make sure you use a 5 pin DIN cord, and not use a PS/2 to 5-pin DIN adapter.

                        Mike
                        It's a Tulip Compact, they are very specific about keyboards, so I don't think it will work. I don't have a 5p DIN cord, only PS/2.

                        Comment


                          #42
                          Originally posted by irix View Post
                          It's a Tulip Compact, they are very specific about keyboards, so I don't think it will work. I don't have a 5pin DIN cord, only PS/2.
                          Right, that was my point. If its for a regular IBM 5160 its easy to check for the 5/86 BIOS. If its a clone then you'd have to find out some other way to check the BIOS or you might run into such limitations. A lot of people, even with the right BIOS, try using a PS/2 to 5-pin DIN adapter, and when it doesn't work they give up, not realizing they can't use an adapter. Many of the Model-M keyboard have removable cords. For my XTs I just picked up a $5 regular 5-pin din cord and after that it worked; it didn't with the adapter.

                          Regards,
                          Mike

                          Comment


                            #43
                            Somebody did build a PIC based converter, maybe that will help in making the Arduino solution happen?

                            This is the link: http://www.vcfed.org/forum/showthrea...oard-converter

                            Comment


                              #44
                              I have NEVER heard of an AT keyboard working on a PC/XT regardless of BIOS unless it had a switch on it to do so. That's definitely news to me... Though it might be auto-sense related to that endless string of 0xAA with the parity wrong that times out eventually. If that fails to get a "resend" message could that be the trigger?

                              ... and since the PS/2 to AT converter cable is pin to pin other than dropping the (officially "Not used") reset line, just how would that NOT work exactly?!? It's four lines with NO changes, no circuitry. Data, Clock, Ground, +5v. That's it. It's the same protocol on the same wiring, just different plugs!

                              ... and @nc_mike, I think you lost me at 5/86... With an AT keyboard I assumed you meant AT/later BIOS... is the 86 the year number or something? While I worked on a few early PC's and XT's, I was really more of a clone guy. Sounds like something even LESS likely to work on a clone. I never even heard of an XT BIOS that supports 101 key keyboards, so I assumed you were talking about an AT class or later one!

                              Also not sure how that would even work given the hardware wouldn't even EXIST on the system side to handle AT signalling.

                              Side note, figured out why I was having trouble reading the AT keyboard, it wasn't the keyboard, or my wiring, or my code... it was another broke-ass crappy USB cable between the Arduino and the computer I was using to debug. Laughably it was the cable from a real Arduino that failed... the cheap cable that came for free with the knockoff DCCDuino Nano? Works flawless.

                              I swear, one of these days I'm going to track down the creators of USB and SATA plugs and pull a Jay and Silent Bob... How many people wanna kick some ass? I'm one step away from stripping the ends off all my USB cables and device jacks and replacing them with old-fashioned 4 pin DIN! At least that would be reliable and not break if you accidentally sneeze in the same room...
                              Last edited by deathshadow; September 4, 2016, 04:22 PM.
                              From time to time the accessibility of a website must be refreshed with the blood of owners and designers. It is its natural manure.
                              CUTCODEDOWN.COM

                              Comment


                                #45
                                Early IBM Model Ms actually supported the XT explicitly (and IBM even sold a variant without the LEDs specifically for XTs), and they would (on the latest XT BIOS) switch to XT mode automatically.

                                Comment

                                Working...
                                X