Beispiel #1
0
void dfinput_activate(void)
{
	PadDataS pad;

	PAD1_readPort1(&pad);
	select_pad(1);

	PAD2_readPort2(&pad);
	select_pad(2);
}
Beispiel #2
0
unsigned char PADstartPoll_pad(int pad) {
	CurPad = pad - 1;
	CurByte = 0;

	if (pad == 1)
		PAD1_readPort1(&padstate[0].pad);
	else
		PAD2_readPort2(&padstate[1].pad);

	return 0xFF;
}
Beispiel #3
0
void pad_init(void)
{
	int i;

	PAD1_readPort1(&padstate[0].pad);
	PAD2_readPort2(&padstate[1].pad);

	for (i = 0; i < 2; i++) {
		padstate[i].PadID = padstate[i].pad.controllerType == PSE_PAD_TYPE_ANALOGPAD ? 0x73 : 0x41;
		padstate[i].PadMode = padstate[i].pad.controllerType == PSE_PAD_TYPE_ANALOGPAD;
	}
}
Beispiel #4
0
void pad_init(void)
{
	int i;

	PAD1_readPort1(&padstate[0].pad);
	PAD2_readPort2(&padstate[1].pad);

	for (i = 0; i < 2; i++) {
		switch (padstate[i].pad.controllerType)
		{
            case PSE_PAD_TYPE_NEGCON:
                padstate[i].PadID = padstate[i].pad.controllerType == PSE_PAD_TYPE_NEGCON ? 0x23 : 0x41;
                padstate[i].PadMode = padstate[i].pad.controllerType == PSE_PAD_TYPE_NEGCON;
                break;
            case PSE_PAD_TYPE_ANALOGPAD:
                padstate[i].PadID = padstate[i].pad.controllerType == PSE_PAD_TYPE_ANALOGPAD ? 0x73 : 0x41;
                padstate[i].PadMode = padstate[i].pad.controllerType == PSE_PAD_TYPE_ANALOGPAD;
                break;
            default:
                break;
		}
	}
}