Shop OBEX P1 Docs P2 Docs Learn Events
Proposal for gamepad_drv standard? — Parallax Forums

Proposal for gamepad_drv standard?

Oldbitcollector (Jeff)Oldbitcollector (Jeff) Posts: 8,091
edited 2010-04-22 03:37 in Propeller 1
I've uploaded a simple keyboard version of gamepad_drv_001 to obex. Any game that requires NES
controls and uses gamepad_drv_001 should work find with this driver.

I'm getting ready to do a version for the Nintendo 64 and PropJoy as well..

Got a proposal for the game developers here:
If we could get everyone to agree to use this type of format for their creations, then
adapting any device could be as simple as changing the file before compile.

Consideration?

OBC

▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
New to the Propeller?

Getting started with the Protoboard? - Propeller Cookbook
Got an SD card? - PropDOS
A Living Propeller FAQ - The Propeller Wiki
(Got the Knowledge? Got a Moment? Add something today!)

Comments

  • JT CookJT Cook Posts: 487
    edited 2008-01-26 02:16
    In Spintris I have a controller setup that uses the keyboard, Hydra joypad and Hybrid joypad setup in one gamepad file. It made it easy because from game engine's perspective, it saw it as one controller (there wasn't different setups for the different inputs).
  • AndreLAndreL Posts: 1,004
    edited 2008-01-26 03:08
    Excellent, standards are the way of the Dark Side, I love it [noparse]:)[/noparse] Seriously though, without DirectX we would be in the stoneage of gamedev still, so the more standards for the hydra the better, so people can concentrate on making games and not re-writing basic drivers.

    Andre'
  • Oldbitcollector (Jeff)Oldbitcollector (Jeff) Posts: 8,091
    edited 2008-01-30 03:30
    N64 gamepad_drv_001 submitted to obex, waiting for approval.

    PropJoy/Hydra controls next. (easy stuff)

    OBC

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    New to the Propeller?

    Getting started with the Protoboard? - Propeller Cookbook
    Got an SD card? - PropDOS
    A Living Propeller FAQ - The Propeller Wiki
    (Got the Knowledge? Got a Moment? Add something today!)

  • Oldbitcollector (Jeff)Oldbitcollector (Jeff) Posts: 8,091
    edited 2008-11-25 17:00
    With the expanded focus of this forum, this is a thread that deserves a revisit.

    My original N64 conversion can be found here:
    obex.parallax.com/objects/250/

    I'm going to switch LOADRUNNER and SPYDRIVER to use a separated "gamepad_drv_001.spin"
    and so some testing with some of the other Propeller configurations in my collection starting with the Hybrid.

    OBC

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    New to the Propeller?

    Getting started with a Propeller Protoboard?
    Check out: Introduction to the Proboard & Propeller Cookbook 1.4
    Updates to the Cookbook are now posted to: Propeller.warrantyvoid.us
    Got an SD card connected? - PropDOS
  • morgandeomorgandeo Posts: 16
    edited 2008-12-02 10:02
    Hi,
    I am just playing simple game like car race , bike race etc.So there is no issue for driver.
  • ForrestForrest Posts: 1,341
    edited 2010-04-20 00:17
    OBC,

    I just finished soldering my PropJoy adapter and I'm looking for someway to test it. Did you ever finish the PropJoy driver for Atari joysticks? Does the PropJoy work with the Hydra NEC driver? Comments welcome.

    By the way I just viewed your Propeller Arcade Atari Interface Test - great job. Boulderdash is one of my favorite games.

    Forrest
  • Oldbitcollector (Jeff)Oldbitcollector (Jeff) Posts: 8,091
    edited 2010-04-21 16:53
    @Forrest

    No, but I think I can help you with it.

    Can you give me an idea of your connection points (I/O) to the Atari switches?

    Thanks!

    OBC

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Are you Propeller Powered? PropellerPowered.com
    Visit the: PROPELLERPOWERED SIG forum kindly hosted by Savage Circuits.
  • ForrestForrest Posts: 1,341
    edited 2010-04-21 23:41
    The PropJoy documentation is here ucontroller.com/documentation/propjoyDoc.html

    Each joystick port is connected thru a 4021N, and the pin outs to the Propeller are exactly the same as uController's NEC adapter ie. P3-Clock, P4-Latch, P5-Player1 Data and P6-Player2 Data.

    The only other reference I found to PropJoy on these forums is this thread about Defender - which apparently works with the PropJoy http://forums.parallax.com/showthread.php?p=697458
  • Oldbitcollector (Jeff)Oldbitcollector (Jeff) Posts: 8,091
    edited 2010-04-21 23:52
    IIRC, the PropJoy should work with any NES compatible program (which uses a single fire button)
    simply by changing the bit mask a little.

    Here's some NES code from one of my programs..

      ' NES bit encodings for NES gamepad 0
      NES0_RIGHT    = %00000000_00000001
      NES0_LEFT     = %00000000_00000010
      NES0_DOWN     = %00000000_00000100
      NES0_UP       = %00000000_00001000
      NES0_START    = %00000000_00010000
      NES0_SELECT   = %00000000_00100000
      NES0_B        = %00000000_01000000
      NES0_A        = %00000000_10000000  
      
      '' joypad serial shifter settings
      JOY_CLK = 3
      JOY_LCH = 4
      JOY_DATAOUT0 = 5
      JOY_DATAOUT1 = 6
    
    



    Adjusted for the PropJoy.

      ' NES bit encodings for NES gamepad 0
      NES0_RIGHT    = %00000000_00001000
      NES0_LEFT     = %00000000_00000100
      NES0_DOWN     = %00000000_00000010
      NES0_UP       = %00000000_00000001
      NES0_START    = %00000000_00010000
      NES0_SELECT   = %00000000_00100000
      NES0_B        = %00000000_01000000
      NES0_A        = %00000000_00100000
      
      '' joypad serial shifter settings
      JOY_CLK = 3
      JOY_LCH = 4
      JOY_DATAOUT0 = 5
      JOY_DATAOUT1 = 6
    
    



    You might need to ditch the 00000000_'s but it should work. In this example I've setup NES0_A to the fire button.

    OBC

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Are you Propeller Powered? PropellerPowered.com
    Visit the: PROPELLERPOWERED SIG forum kindly hosted by Savage Circuits.
  • ForrestForrest Posts: 1,341
    edited 2010-04-22 03:37
    Thanks - will try it out tomorrow.
Sign In or Register to comment.