Notice. New forum software under development. It's going to miss a few functions and look a bit ugly for a while, but I'm working on it full time now as the old forum was too unstable. Couple days, all good. If you notice any issues, please contact me.
|
Forum Index : Microcontroller and PC projects : PZ Control - my quest for the perfect game controller
Page 2 of 2 | |||||
Author | Message | ||||
thwill Guru Joined: 16/09/2019 Location: United KingdomPosts: 4040 |
I wasnt't asking for emulation, just the bits for the digital controls in the order I gave, which should be the same order as Peter's Wii Classic support on CMM2/PicoMite (and not coincidentally my "ctrl.inc" library). It is the closest to a "standard" that we have. Best wishes, Tom Edited 2023-12-20 21:04 by thwill Game*Mite, CMM2 Welcome Tape, Creaky old text adventures |
||||
Mixtel90 Guru Joined: 05/10/2019 Location: United KingdomPosts: 6795 |
The bits will be returned as two bytes, I think. I2C under MMBasic seems to be strictly byte-orientated. Apart from that, no prob. :) Mick Zilog Inside! nascom.info for Nascom & Gemini Preliminary MMBasic docs & my PCB designs |
||||
JohnS Guru Joined: 18/11/2011 Location: United KingdomPosts: 3802 |
Two bytes will be fine if they are like Tom posted, just join them together as 16 bits. Possibly Windows will be awkward but should be able to map onto something the same or very close to Tom's list - I hope! John |
||||
Mixtel90 Guru Joined: 05/10/2019 Location: United KingdomPosts: 6795 |
Revised: J(U,D,L,R) = joystick virtual D0pad directions or LH buttons JB = Joystick switch or Soft_Reset (always high on the Classic) LT,RT = "shoulder" buttons P, Z two buttons below Select & Start (replace ZL and ZR) Command &h04 Returns two bytes: Byte 1 JR, JD, LT, Select, Hone, Start, RT, JB Byte 2 P, B, Y, A, X, Z, JL, JU Incidentally, Nintendo stopped making the Classic and Classic Pro controllers about ten years ago. They simply dropped them with no official announcement. . Edited 2023-12-22 07:25 by Mixtel90 Mick Zilog Inside! nascom.info for Nascom & Gemini Preliminary MMBasic docs & my PCB designs |
||||
vegipete Guru Joined: 29/01/2013 Location: CanadaPosts: 1109 |
I would try massage those bit patterns somewhat more. The order is mostly right, but the positions are off by one. From the Wii Classic docs: Bit 15 is missing and could presumably be your extra signal. What order does I2C sent the bits? Visit Vegipete's *Mite Library for cool programs. |
||||
Mixtel90 Guru Joined: 05/10/2019 Location: United KingdomPosts: 6795 |
On the Classic controller the spare location is actually bit 0 - it's MMBasic that's wrong. :) I realized that this morning. Bit 0 always returns a 1. Revised again: J(U,D,L,R) = joystick virtual D0pad directions or LH buttons JB = Joystick switch or Soft_Reset (always high on the Classic) LT,RT = "shoulder" buttons P, Z two buttons below Select & Start (replace ZL and ZR) Command &h04 Returns two bytes: Byte 1 (bits 7-0) JU, JR, JD, LT, Select, Hone, Start, RT Byte 2 (bits 15-8) JB, P, B, Y, A, X, Z, JL No idea about the I2C bit order. You shove a character (or an array in my case) in at one end and it pops out at the other. That's all I'm interested in. :) Mick Zilog Inside! nascom.info for Nascom & Gemini Preliminary MMBasic docs & my PCB designs |
||||
Page 2 of 2 |
Print this page |