v1 Stable

Dependencies:   F401RE-USBHost USBHostXpad mbed

Controls.txt

Committer:
Ownasaurus
Date:
2017-04-15
Revision:
13:d7c1aae2b48f
Parent:
6:21365f733399

File content as of revision 13:d7c1aae2b48f:

    // Owna's Controls
    if(AXYB & 0x01) // a
    {
        n64_data.a = 1;
    }
    if((AXYB >> 2) & 0x01) // x
    {
        n64_data.b = 1;
    }
    if((AXYB >> 1) & 0x01) // b
    {
        n64_data.z = 1;
    }
    if((AXYB >> 3) & 0x01) // y
    {
        n64_data.c_up = 1;
    }
    if(bkStrtLCRC & 0x01) // start
    {
        n64_data.start = 1;
    }
    if((XLBRB >> 1) & 0x01) // right bumper
    {
        n64_data.r = 1;
    }
    if(XLBRB & 0x01) // left bumper
    {
        n64_data.l = 1;
    }*/
    
    // Supa's Controls
    /*if(AXYB & 0x01) // a
    {
        n64_data.a = 1;
    }
    if((AXYB >> 2) & 0x01) // x
    {
        n64_data.b = 1;
    }
    if((AXYB >> 1) & 0x01) // b
    {
        n64_data.c_down = 1;
    }
    if((AXYB >> 3) & 0x01) // y
    {
        n64_data.z = 1;
    }
    if(bkStrtLCRC & 0x01) // start
    {
        n64_data.start = 1;
    }
    if((XLBRB >> 1) & 0x01) // right bumper
    {
        n64_data.r = 1;
    }
    if(XLBRB & 0x01) // left bumper
    {
        n64_data.l = 1;
    }
    if(DPad & 0x01) // DPad Up
    {
        n64_data.c_up = 1;
    }
    if(DPad & 0x02) // DPad Down
    {
        n64_data.c_down = 1;
    }
    if(DPad & 0x04) // DPad Left
    {
        n64_data.c_left = 1;
    }
    if(DPad & 0x08) // DPad Right
    {
        n64_data.c_right = 1;
    }
    // JJ's Controls
    if(AXYB & 0x01) // a
    {
        n64_data.a = 1;
    }
    if((AXYB >> 2) & 0x01) // x
    {
        n64_data.b = 1;
    }
    if((AXYB >> 3) & 0x01) // y
    {
        n64_data.c_left = 1;
    }
    if((AXYB >> 1) & 0x01) // b
    {
        n64_data.c_right = 1;
    }
    if(bkStrtLCRC & 0x01) // start
    {
        n64_data.start = 1;
    }
    if((XLBRB >> 1) & 0x01) // right bumper
    {
        n64_data.r = 1;
    }
    if(XLBRB & 0x01) // left bumper
    {
        n64_data.z = 1;
    }
    if(DPad & 0x01) // DPad Up
    {
        n64_data.up = 1;
    }
    if(DPad & 0x02) // DPad Down
    {
        n64_data.down = 1;
    }
    if(DPad & 0x04) // DPad Left
    {
        n64_data.left = 1;
    }
    if(DPad & 0x08) // DPad Right
    {
        n64_data.right = 1;
    }
    if(Lt > 2 || Rt > 2) // Triggers greater than threshold
    {
        n64_data.z = 1;
    }
    
    // LD's Controls
    if(AXYB & 0x01) // a
    {
        n64_data.a = 1;
    }
    if((AXYB >> 2) & 0x01) // x
    {
        n64_data.b = 1;
    }
    if((AXYB >> 3) & 0x01) // y
    {
        n64_data.c_up = 1;
    }
    if(bkStrtLCRC & 0x01) // start
    {
        n64_data.start = 1;
    }
    if((XLBRB >> 1) & 0x01) // right bumper
    {
        n64_data.r = 1;
    }
    if(XLBRB & 0x01) // left bumper
    {
        n64_data.l = 1;
    }
    if(DPad & 0x01) // DPad Up
    {
        n64_data.c_up = 1;
    }
    if(DPad & 0x02) // DPad Down
    {
        n64_data.c_down = 1;
    }
    if(DPad & 0x04) // DPad Left
    {
        n64_data.c_left = 1;
    }
    if(DPad & 0x08) // DPad Right
    {
        n64_data.c_right = 1;
    }
    if(Rt > TRIGGER_THRESHOLD) // Right trigger greater than threshold
    {
        n64_data.z = 1;
    }