You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

14 lines
432 B

#include "../config.h"
#include "../makros.h"
#include "joystick.h"
#include <avr/io.h>
inline void joy_init(){
PORT_FROM_PIN(JOYSTICK_PIN_UP ) |= (1<<JOYSTICK_BIT_UP );
PORT_FROM_PIN(JOYSTICK_PIN_DOWN ) |= (1<<JOYSTICK_BIT_DOWN );
PORT_FROM_PIN(JOYSTICK_PIN_LEFT ) |= (1<<JOYSTICK_BIT_LEFT );
PORT_FROM_PIN(JOYSTICK_PIN_RIGHT) |= (1<<JOYSTICK_BIT_RIGHT);
PORT_FROM_PIN(JOYSTICK_PIN_FIRE ) |= (1<<JOYSTICK_BIT_FIRE );
}