banish all c++-style comments

This commit is contained in:
Ryan Pavlik
2011-09-14 09:42:00 -05:00
parent 9763c37525
commit adbc96318b
25 changed files with 81 additions and 81 deletions

View File

@@ -32,11 +32,11 @@
*/
#include "classic.h"
#include "dynamics.h" // for calc_joystick_state
#include "events.h" // for handshake_expansion
#include "dynamics.h" /* for calc_joystick_state */
#include "events.h" /* for handshake_expansion */
#include <stdlib.h> // for malloc
#include <string.h> // for memset
#include <stdlib.h> /* for malloc */
#include <string.h> /* for memset */
static void classic_ctrl_pressed_buttons(struct classic_ctrl_t* cc, short now);

View File

@@ -53,4 +53,4 @@ void classic_ctrl_event(struct classic_ctrl_t* cc, byte* msg);
}
#endif
#endif // CLASSIC_H_INCLUDED
#endif /* CLASSIC_H_INCLUDED */

View File

@@ -42,7 +42,7 @@
#define WIIMOTE_PI 3.14159265f
//#define WITH_WIIUSE_DEBUG
/* #define WITH_WIIUSE_DEBUG */
extern FILE* logtarget[];
@@ -89,4 +89,4 @@ extern FILE* logtarget[];
/** @} */
#endif // DEFINITIONS_H_INCLUDED
#endif /* DEFINITIONS_H_INCLUDED */

View File

@@ -37,8 +37,8 @@
#include "dynamics.h"
#include <math.h> // for atan2f, atanf, sqrt
#include <stdlib.h> // for abs
#include <math.h> /* for atan2f, atanf, sqrt */
#include <stdlib.h> /* for abs */
/**

View File

@@ -57,4 +57,4 @@ void apply_smoothing(struct accel_t* ac, struct orient_t* orient, int type);
}
#endif
#endif // DYNAMICS_H_INCLUDED
#endif /* DYNAMICS_H_INCLUDED */

View File

@@ -37,24 +37,24 @@
#include "wiiuse_internal.h"
#include "events.h"
#include "classic.h" // for classic_ctrl_disconnected, etc
#include "dynamics.h" // for calculate_gforce, etc
#include "guitar_hero_3.h" // for guitar_hero_3_disconnected, etc
#include "ir.h" // for calculate_basic_ir, etc
#include "nunchuk.h" // for nunchuk_disconnected, etc
#include "wiiboard.h" // for wii_board_disconnected, etc
#include "io.h" // for wiiuse_io_read on Windows, etc
#include "classic.h" /* for classic_ctrl_disconnected, etc */
#include "dynamics.h" /* for calculate_gforce, etc */
#include "guitar_hero_3.h" /* for guitar_hero_3_disconnected, etc */
#include "ir.h" /* for calculate_basic_ir, etc */
#include "nunchuk.h" /* for nunchuk_disconnected, etc */
#include "wiiboard.h" /* for wii_board_disconnected, etc */
#include "io.h" /* for wiiuse_io_read on Windows, etc */
#ifndef WIIUSE_WIN32
#include <sys/time.h> // for timeval
#include <sys/select.h> // for select, fd_set
#include <unistd.h> // for read
#include <sys/time.h> /* for timeval */
#include <sys/select.h> /* for select, fd_set */
#include <unistd.h> /* for read */
#endif
#include <errno.h> // for errno
#include <stdio.h> // for printf, perror
#include <stdlib.h> // for free, malloc
#include <string.h> // for memcpy, memset
#include <errno.h> /* for errno */
#include <stdio.h> /* for printf, perror */
#include <stdlib.h> /* for free, malloc */
#include <string.h> /* for memcpy, memset */
static void idle_cycle(struct wiimote_t* wm);
static void clear_dirty_reads(struct wiimote_t* wm);

View File

@@ -56,4 +56,4 @@ void handshake_expansion(struct wiimote_t* wm, byte* data, uint16_t len);
void disable_expansion(struct wiimote_t* wm);
/** @} */
#endif // EVENTS_H_INCLUDED
#endif /* EVENTS_H_INCLUDED */

View File

@@ -33,11 +33,11 @@
#include "guitar_hero_3.h"
#include "dynamics.h" // for calc_joystick_state
#include "events.h" // for handshake_expansion
#include "dynamics.h" /* for calc_joystick_state */
#include "events.h" /* for handshake_expansion */
#include <stdlib.h> // for malloc
#include <string.h> // for memset
#include <stdlib.h> /* for malloc */
#include <string.h> /* for memset */
static void guitar_hero_3_pressed_buttons(struct guitar_hero_3_t* gh3, short now);

View File

@@ -63,4 +63,4 @@ void guitar_hero_3_event(struct guitar_hero_3_t* gh3, byte* msg);
}
#endif
#endif // GUITAR_HERO_3_H_INCLUDED
#endif /* GUITAR_HERO_3_H_INCLUDED */

View File

@@ -32,7 +32,7 @@
*/
#include "io.h"
#include <stdlib.h> // for free, malloc
#include <stdlib.h> /* for free, malloc */
/**

View File

@@ -60,4 +60,4 @@ int wiiuse_io_write(struct wiimote_t* wm, byte* buf, int len);
}
#endif
#endif // CONNECT_H_INCLUDED
#endif /* CONNECT_H_INCLUDED */

View File

@@ -36,15 +36,15 @@
#ifdef WIIUSE_BLUEZ
#include <bluetooth/bluetooth.h> // for ba2str, str2ba
#include <bluetooth/hci.h> // for inquiry_info
#include <bluetooth/hci_lib.h> // for hci_get_route, hci_inquiry, etc
#include <bluetooth/l2cap.h> // for sockaddr_l2
#include <bluetooth/bluetooth.h> /* for ba2str, str2ba */
#include <bluetooth/hci.h> /* for inquiry_info */
#include <bluetooth/hci_lib.h> /* for hci_get_route, hci_inquiry, etc */
#include <bluetooth/l2cap.h> /* for sockaddr_l2 */
#include <stdio.h> // for perror
#include <string.h> // for memset
#include <sys/socket.h> // for connect, socket
#include <unistd.h> // for close, write
#include <stdio.h> /* for perror */
#include <string.h> /* for memset */
#include <sys/socket.h> /* for connect, socket */
#include <unistd.h> /* for close, write */
#include <errno.h>
static int wiiuse_connect_single(struct wiimote_t* wm, char* address);
@@ -76,7 +76,7 @@ int wiiuse_find(struct wiimote_t** wm, int max_wiimotes, int timeout) {
/* reset all wiimote bluetooth device addresses */
for (found_wiimotes = 0; found_wiimotes < max_wiimotes; ++found_wiimotes) {
//bacpy(&(wm[found_wiimotes]->bdaddr), BDADDR_ANY);
/* bacpy(&(wm[found_wiimotes]->bdaddr), BDADDR_ANY); */
memset(&(wm[found_wiimotes]->bdaddr), 0, sizeof(bdaddr_t));
}
found_wiimotes = 0;

View File

@@ -63,7 +63,7 @@ int wiiuse_find(struct wiimote_t** wm, int max_wiimotes, int timeout) {
HIDD_ATTRIBUTES attr;
int found = 0;
(void) timeout; // unused
(void) timeout; /* unused */
device_data.cbSize = sizeof(device_data);
index = 0;

View File

@@ -33,7 +33,7 @@
#include "ir.h"
#include <math.h> // for atanf, cos, sin, sqrt
#include <math.h> /* for atanf, cos, sin, sqrt */
static int get_ir_sens(struct wiimote_t* wm, const byte** block1, const byte** block2);
static void interpret_ir_data(struct wiimote_t* wm);
@@ -82,7 +82,7 @@ void wiiuse_set_ir(struct wiimote_t* wm, int status) {
if(status) {
WIIUSE_DEBUG("Tried to enable IR, will wait until handshake finishes.");
WIIMOTE_ENABLE_STATE(wm, WIIMOTE_STATE_IR);
} // else ignoring request to turn off, since it's turned off by default
} /* else ignoring request to turn off, since it's turned off by default */
return;
}
@@ -429,7 +429,7 @@ static void interpret_ir_data(struct wiimote_t* wm) {
wm->ir.ay = wm->ir.y;
/* can't calculate yaw because we don't have the distance */
//wm->orient.yaw = calc_yaw(&wm->ir);
/* wm->orient.yaw = calc_yaw(&wm->ir); */
ir_convert_to_vres(&wm->ir.x, &wm->ir.y, wm->ir.aspect, wm->ir.vres[0], wm->ir.vres[1]);
break;

View File

@@ -56,6 +56,6 @@ float calc_yaw(struct ir_t* ir);
}
#endif
#endif // IR_H_INCLUDED
#endif /* IR_H_INCLUDED */

View File

@@ -33,11 +33,11 @@
#include "nunchuk.h"
#include "dynamics.h" // for calc_joystick_state, etc
#include "events.h" // for handshake_expansion
#include "dynamics.h" /* for calc_joystick_state, etc */
#include "events.h" /* for handshake_expansion */
#include <stdlib.h> // for malloc
#include <string.h> // for memset
#include <stdlib.h> /* for malloc */
#include <string.h> /* for memset */
static void nunchuk_pressed_buttons(struct nunchuk_t* nc, byte now);

View File

@@ -54,4 +54,4 @@ void nunchuk_event(struct nunchuk_t* nc, byte* msg);
}
#endif
#endif // NUNCHUK_H_INCLUDED
#endif /* NUNCHUK_H_INCLUDED */

View File

@@ -49,4 +49,4 @@
#pragma warning(disable:4217)
#endif
#endif // OS_H_INCLUDED
#endif /* OS_H_INCLUDED */

View File

@@ -40,7 +40,7 @@ void wiiuse_millisleep(int durationMilliseconds) {
#else /* not win32 - assuming posix */
#include <unistd.h> // for usleep
#include <unistd.h> /* for usleep */
void wiiuse_millisleep(int durationMilliseconds) {
usleep(durationMilliseconds * 1000);

View File

@@ -34,8 +34,8 @@
#include "wiiboard.h"
#include <stdio.h> // for printf
#include <string.h> // for memset
#include <stdio.h> /* for printf */
#include <string.h> /* for memset */
/**
* @brief Handle the handshake data from the wiiboard.

View File

@@ -36,11 +36,11 @@
*/
#include "wiiuse_internal.h"
#include "io.h" // for wiiuse_handshake, etc
#include "io.h" /* for wiiuse_handshake, etc */
#include <stdio.h> // for printf, FILE
#include <stdlib.h> // for malloc, free
#include <string.h> // for memcpy, memset
#include <stdio.h> /* for printf, FILE */
#include <stdlib.h> /* for malloc, free */
#include <string.h> /* for memcpy, memset */
static int g_banner = 0;
static const char g_wiiuse_version_string[] = WIIUSE_VERSION;

View File

@@ -104,7 +104,7 @@
#include <stdint.h>
#endif
#include <stdio.h> // for FILE
#include <stdio.h> /* for FILE */
/** @defgroup publicapi External API */
/** @{ */

View File

@@ -389,7 +389,7 @@ WIIUSE_DECLARE_BUFFERING_OPS(uint32_t)
#undef WIIUSE_DECLARE_BUFFERING_OPS
#endif // not in doxygen
#endif /* not in doxygen */
#ifdef __cplusplus
}