Classes | Defines | Typedefs | Functions | Variables
Nclient.c File Reference
#include <unistd.h>
#include <stdlib.h>
#include <stdio.h>
#include <math.h>
#include <memory.h>
#include <errno.h>
#include <sys/types.h>
#include <sys/time.h>
#include <sys/socket.h>
#include <netinet/in.h>
#include <arpa/inet.h>
#include <netdb.h>
#include <fcntl.h>
#include <signal.h>
#include "Nclient.h"
Include dependency graph for Nclient.c:

Go to the source code of this file.

Classes

struct  _PosDataAll

Defines

#define AC_MSG   10
#define ACCELERATION_MSG   90
#define ADDOBS_MSG   50
#define BUMPER_MSG   87
#define COMPASS_MSG   86
#define CONF_CP_MSG   24
#define CONF_IR_MSG   22
#define CONF_LS_MSG   25
#define CONF_SG_MSG   36
#define CONF_SN_MSG   23
#define CONF_TM_MSG   26
#define CONFIGURATION_MSG   88
#define CONNECT_ROBOT_MSG   102
#define CREATE_ROBOT_MSG   101
#define CT_MSG   16
#define DA_MSG   38
#define DEBUG
#define DELETEOBS_MSG   51
#define DISCONNECT_MSG   103
#define DP_MSG   21
#define DRAWARC_MSG   62
#define DRAWLINE_MSG   61
#define DRAWROBOT_MSG   60
#define ERROR_MSG   91
#define FALSE   0
#define GET_BP_MSG   35
#define GET_CONF_MSG   200
#define GET_CP_MSG   32
#define GET_IR_MSG   27
#define GET_LS_MSG   33
#define GET_RA_MSG   31
#define GET_RC_MSG   29
#define GET_RPX_MSG   75
#define GET_RV_MSG   30
#define GET_SG_MSG   37
#define GET_SN_MSG   28
#define GS_MSG   15
#define INFRARED_MSG   83
#define INTERSECT_MSG   401
#define IPC_ERROR   111
#define IS_SERVER_ALIVE_ACK   1
#define IS_SERVER_ALIVE_MSG   0 /* message types */
#define LASER_MSG   85
#define LP_MSG   18
#define MAX_HOST_NAME_LENGTH   100
#define MAX_MESSAGE   100
#define MAX_MESSAGE   100
#define MAX_MESSAGE   100
#define MAX_USER_BUF   0xFFFF
#define MAX_VERT   10
#define MAX_VERTICES   10 /* maximum number of verices in a poly */
#define MAX_VERTICES   10
#define MCHECK_MSG   400
#define MOVED_MSG   81
#define MOVEOBS_MSG   52
#define MV_MSG   43
#define NEW_SOCKET   2
#define NEWWORLD_MSG   53
#define NUM_LASER   482
#define NUM_LASER   482
#define NUM_MASK   44
#define NUM_MASK   44
#define NUM_STATE   45
#define NUM_STATE   45
#define PA_MSG   14
#define PR_MSG   13
#define PREDICTSENSOR_MSG   42
#define QUIT_MSG   70
#define RANGE_CPU_VOLTAGE   12.0
#define RANGE_MOTOR_VOLTAGE   12.85
#define REALROBOT_MSG   71
#define RECEIVE_MESSAGE_MSG   73
#define REFRESHACTTRACE_MSG   152
#define REFRESHALL_MSG   150
#define REFRESHALLSENSORS_MSG   154
#define REFRESHALLTRACES_MSG   151
#define REFRESHBPSENSOR_MSG   155
#define REFRESHENCTRACE_MSG   153
#define REFRESHGRAPHICS_MSG   159
#define REFRESHIRSENSOR_MSG   156
#define REFRESHLSSENSOR_MSG   158
#define REFRESHSNSENSOR_MSG   157
#define REPLY_MSG   82
#define RMOVE_MSG   40
#define RPLACE_MSG   41
#define RPX_MSG   76
#define SEND_MESSAGE_MSG   72
#define SERIAL_ERROR   11
#define SETUP_LS_MSG   34
#define SIMULATEDROBOT_MSG   74
#define SONAR_MSG   84
#define SP_MSG   11
#define SPECIAL_MSG   300
#define ST_MSG   17
#define STATE_MSG   80
#define TK_MSG   19
#define TRUE   1
#define VELOCITY_MSG   89
#define VM_MSG   12
#define WS_MSG   39
#define ZR_MSG   20

Typedefs

typedef struct _PosDataAll PosDataAll

Functions

int ac (int t_ac, int s_ac, int r_ac)
int add_Obs (long obs[2 *MAX_VERTICES+1])
int add_obstacle (long obs[2 *MAX_VERTICES+1])
long arm_mv (long l_mode, long l_v, long g_mode, long g_v)
long arm_ws (short l, short g, long timeout, long *time_remain)
long arm_zr (short override)
static unsigned char bits_to_byte (char bt0, char bt1, char bt2, char bt3, char bt4, char bt5, char bt6, char bt7)
int conf_cp (int mode)
int conf_ir (int history, int order[16])
int conf_ls (unsigned int mode, unsigned int threshold, unsigned int width, unsigned int num_data, unsigned int processing)
int conf_sg (unsigned int threshold, unsigned int min_points, unsigned int gap)
int conf_sn (int rate, int order[16])
int conf_tm (unsigned char timeout)
int connect_robot (long robot_id,...)
char * convertAddr (char *name, char *addr)
int create_robot (long robot_id)
int ct (void)
int da (int th, int tu)
int delete_Obs (long obs[2 *MAX_VERTICES+1])
int delete_obstacle (long obs[2 *MAX_VERTICES+1])
int disconnect_robot (long robot_id)
int dp (int x, int y)
int draw_arc (long x_0, long y_0, long w, long h, int th1, int th2, int mode)
int draw_line (long x_1, long y_1, long x_2, long y_2, int mode)
int draw_robot (long x, long y, int th, int tu, int mode)
signed short extract2byteint (unsigned char *buffer, unsigned short *index)
unsigned short extract2byteuint (unsigned char *buffer, unsigned short *index)
signed long extract4byteint (unsigned char *buffer, unsigned short *index)
unsigned long extract4byteuint (unsigned char *buffer, unsigned short *index)
int extract_receive_buffer_header (unsigned short *length, unsigned char *serial_number, unsigned char *packet_type, unsigned char *buffer)
signed char extractchar (unsigned char *buffer, unsigned short *index)
double extractdouble (unsigned char *buffer, unsigned short *index)
unsigned char extractuchar (unsigned char *buffer, unsigned short *index)
int get_bp (void)
int get_cp (void)
int get_ir (void)
int get_laser (int laser[2 *NUM_LASER+1])
int get_ls (void)
int get_mask (int mask[NUM_MASK])
int get_ra (void)
int get_rc (void)
int get_robot_conf (long *conf)
int get_rpx (long *robot_pos)
int get_rv (void)
int get_sg (void)
int get_sn (void)
int get_state (long state[NUM_STATE])
int gethostname (char *name, int len)
int gs (void)
void init_mask (void)
int init_receive_buffer (unsigned short *index)
int init_send_buffer (unsigned short *index)
int init_sensors (void)
static int ipc_comm (struct request_struct *this_request, struct reply_struct *this_reply)
int lp (void)
int motion_check (long type, double a1, double a2, double a3, double a4, double a5, double a6, double a7, double collide[3])
int move_Obs (long obs[2 *MAX_VERTICES+1], long dx, long dy)
int move_obstacle (long obs[2 *MAX_VERTICES+1], long dx, long dy)
int mv (int t_mode, int t_mv, int s_mode, int s_mv, int r_mode, int r_mv)
int new_world (void)
static int open_socket_to_send_data (int tcp_port_num)
int pa (int t_pa, int s_pa, int r_pa)
int place_robot (int x, int y, int th, int tu)
int posBumperGet (PosData *posData)
int posCompassGet (PosData *posData)
int posDataCheck (void)
static int posDataProcess (long *buffer, int current, PosData *posData)
int posDataRequest (int posRequest)
int posInfraredGet (PosData *posData, int infraredNumber)
int posInfraredRingGet (PosData posData[INFRAREDS])
int posLaserGet (PosData *posData)
int posSonarGet (PosData *posData, int sonarNumber)
int posSonarRingGet (PosData posData[SONARS])
int posTimeGet (void)
int pr (int t_pr, int s_pr, int r_pr)
int predict_sensors (int x, int y, int th, int tu, long *state, int *laser)
static int process_bumper_reply (struct reply_struct *this_reply)
static int process_compass_reply (struct reply_struct *this_reply)
static int process_conf_reply (struct reply_struct *this_reply, long *conf)
static int process_configuration_reply (struct reply_struct *this_reply)
static int process_infrared_reply (struct reply_struct *this_reply)
static int process_laser_reply (struct reply_struct *this_reply)
static int process_mcheck_reply (struct reply_struct *this_reply, double collide[3])
static int process_obstacle_reply (struct reply_struct *this_reply, long *obs)
static int process_predict_reply (struct reply_struct *this_reply, long *state, int *laser)
static int process_rpx_reply (struct reply_struct *this_reply, long *robot_pos)
static int process_simple_reply (struct reply_struct *this_reply)
static int process_socket_reply (struct reply_struct *this_reply)
static int process_sonar_reply (struct reply_struct *this_reply)
static int process_special_reply (struct reply_struct *this_reply, unsigned char *data)
static int process_state_reply (struct reply_struct *this_reply)
static int process_velocity_reply (struct reply_struct *this_reply)
int quit_server (void)
static int read_reply_from_socket (int sock, struct reply_struct *this_reply)
static int readn (register int fd, register char *ptr, register int nbytes)
int real_robot (void)
int refresh_actual_trace (void)
int refresh_all (void)
int refresh_all_sensors (void)
int refresh_all_traces (void)
int refresh_bumper_sensor (void)
int refresh_client_graphics (void)
int refresh_encoder_trace (void)
int refresh_infrared_sensor (void)
int refresh_laser_sensor (void)
int refresh_sonar_sensor (void)
int server_is_running ()
int set_mask (int mask[NUM_MASK])
int set_serv_tcp_port (int port)
int set_server_machine_name (char *sname)
int simulated_robot (void)
int sp (int t_sp, int s_sp, int r_sp)
int special_request (unsigned char *user_send_buffer, unsigned char *user_receive_buffer)
int st (void)
int stuff2byteint (signed short data, unsigned char *buffer, unsigned short *index)
int stuff2byteuint (unsigned short data, unsigned char *buffer, unsigned short *index)
int stuff4byteint (signed long data, unsigned char *buffer, unsigned short *index)
int stuff4byteuint (unsigned long data, unsigned char *buffer, unsigned short *index)
int stuff_send_buffer_header (unsigned short index, unsigned char serial_number, unsigned char packet_type, unsigned char *buffer)
int stuffchar (signed char data, unsigned char *buffer, unsigned short *index)
int stuffdouble (double data, unsigned char *buffer, unsigned short *index)
int stuffuchar (unsigned char data, unsigned char *buffer, unsigned short *index)
static int timeDataProcess (long *buffer, int current, TimeData *theTime)
int tk (char *talk_string)
int vm (int t_vm, int s_vm, int r_vm)
static float voltConvert (unsigned char reading, float range)
float voltCpuGet (void)
static int voltDataProcess (long *buffer, int current, unsigned char *voltCPU, unsigned char *voltMotor)
float voltMotorGet (void)
static int write_request_to_socket (int sock, struct request_struct *this_request)
static int writen (register int fd, register char *ptr, register int nbytes)
int ws (unsigned char t_ws, unsigned char s_ws, unsigned char r_ws, unsigned char timeout)
int zr (void)

Variables

int CONN_TYPE = -1
static int connectedp = 0
char cvsid_host_client_Nclient_c [] = "$Header: /home/cvs/host/client/Nclient.c,v 1.31 1999/07/30 22:25:29 rak Exp $"
static int dest_socket = 0
static char Host_name [255] = ""
int Laser [2 *NUM_LASER+1]
double LASER_CALIBRATION [8]
static int laser_mode = 51
double LASER_OFFSET [2]
static int own_tcp_port = 0
static PosDataAll posDataAll
static unsigned long posDataTime
char ROBOT_MACHINE_NAME [80] = ""
int ROBOT_TCP_PORT = -1
int SERIAL_BAUD = -1
char SERIAL_PORT [40] = ""
int SERV_TCP_PORT = 7019
char SERVER_MACHINE_NAME [80] = ""
int Smask [NUM_MASK]
long State [NUM_STATE]
static struct reply_struct the_reply
static struct request_struct the_request
static int usedSmask [NUM_MASK]
static unsigned char voltageCPU
static unsigned char voltageMotor

Define Documentation

#define AC_MSG   10

Definition at line 35 of file Nclient.c.

#define ACCELERATION_MSG   90

Definition at line 111 of file Nclient.c.

#define ADDOBS_MSG   50

Definition at line 73 of file Nclient.c.

#define BUMPER_MSG   87

Definition at line 108 of file Nclient.c.

#define COMPASS_MSG   86

Definition at line 107 of file Nclient.c.

#define CONF_CP_MSG   24

Definition at line 50 of file Nclient.c.

#define CONF_IR_MSG   22

Definition at line 48 of file Nclient.c.

#define CONF_LS_MSG   25

Definition at line 51 of file Nclient.c.

#define CONF_SG_MSG   36

Definition at line 62 of file Nclient.c.

#define CONF_SN_MSG   23

Definition at line 49 of file Nclient.c.

#define CONF_TM_MSG   26

Definition at line 52 of file Nclient.c.

#define CONFIGURATION_MSG   88

Definition at line 109 of file Nclient.c.

#define CONNECT_ROBOT_MSG   102

Definition at line 115 of file Nclient.c.

#define CREATE_ROBOT_MSG   101

Definition at line 114 of file Nclient.c.

#define CT_MSG   16

Definition at line 42 of file Nclient.c.

#define DA_MSG   38

Definition at line 66 of file Nclient.c.

#define DEBUG

Definition at line 164 of file Nclient.c.

#define DELETEOBS_MSG   51

Definition at line 74 of file Nclient.c.

#define DISCONNECT_MSG   103

Definition at line 116 of file Nclient.c.

#define DP_MSG   21

Definition at line 47 of file Nclient.c.

#define DRAWARC_MSG   62

Definition at line 80 of file Nclient.c.

#define DRAWLINE_MSG   61

Definition at line 79 of file Nclient.c.

#define DRAWROBOT_MSG   60

Definition at line 78 of file Nclient.c.

#define ERROR_MSG   91

Definition at line 112 of file Nclient.c.

#define FALSE   0

Definition at line 22 of file Nclient.c.

#define GET_BP_MSG   35

Definition at line 61 of file Nclient.c.

#define GET_CONF_MSG   200

Definition at line 118 of file Nclient.c.

#define GET_CP_MSG   32

Definition at line 58 of file Nclient.c.

#define GET_IR_MSG   27

Definition at line 53 of file Nclient.c.

#define GET_LS_MSG   33

Definition at line 59 of file Nclient.c.

#define GET_RA_MSG   31

Definition at line 57 of file Nclient.c.

#define GET_RC_MSG   29

Definition at line 55 of file Nclient.c.

#define GET_RPX_MSG   75

Definition at line 64 of file Nclient.c.

#define GET_RV_MSG   30

Definition at line 56 of file Nclient.c.

#define GET_SG_MSG   37

Definition at line 63 of file Nclient.c.

#define GET_SN_MSG   28

Definition at line 54 of file Nclient.c.

#define GS_MSG   15

Definition at line 41 of file Nclient.c.

#define INFRARED_MSG   83

Definition at line 104 of file Nclient.c.

#define INTERSECT_MSG   401

Definition at line 123 of file Nclient.c.

#define IPC_ERROR   111

Definition at line 133 of file Nclient.c.

#define IS_SERVER_ALIVE_ACK   1

Definition at line 32 of file Nclient.c.

#define IS_SERVER_ALIVE_MSG   0 /* message types */

Definition at line 31 of file Nclient.c.

#define LASER_MSG   85

Definition at line 106 of file Nclient.c.

#define LP_MSG   18

Definition at line 44 of file Nclient.c.

#define MAX_HOST_NAME_LENGTH   100

Definition at line 30 of file Nclient.c.

#define MAX_MESSAGE   100

Definition at line 140 of file Nclient.c.

#define MAX_MESSAGE   100

Definition at line 140 of file Nclient.c.

#define MAX_MESSAGE   100

Definition at line 140 of file Nclient.c.

#define MAX_USER_BUF   0xFFFF

Definition at line 130 of file Nclient.c.

#define MAX_VERT   10

Definition at line 125 of file Nclient.c.

#define MAX_VERTICES   10 /* maximum number of verices in a poly */

Definition at line 136 of file Nclient.c.

#define MAX_VERTICES   10

Definition at line 136 of file Nclient.c.

#define MCHECK_MSG   400

Definition at line 122 of file Nclient.c.

#define MOVED_MSG   81

Definition at line 102 of file Nclient.c.

#define MOVEOBS_MSG   52

Definition at line 75 of file Nclient.c.

#define MV_MSG   43

Definition at line 39 of file Nclient.c.

#define NEW_SOCKET   2

Definition at line 27 of file Nclient.c.

#define NEWWORLD_MSG   53

Definition at line 76 of file Nclient.c.

#define NUM_LASER   482

Definition at line 139 of file Nclient.c.

#define NUM_LASER   482

Definition at line 139 of file Nclient.c.

#define NUM_MASK   44

Definition at line 138 of file Nclient.c.

#define NUM_MASK   44

Definition at line 138 of file Nclient.c.

#define NUM_STATE   45

Definition at line 137 of file Nclient.c.

#define NUM_STATE   45

Definition at line 137 of file Nclient.c.

#define PA_MSG   14

Definition at line 40 of file Nclient.c.

#define PR_MSG   13

Definition at line 38 of file Nclient.c.

#define PREDICTSENSOR_MSG   42

Definition at line 71 of file Nclient.c.

#define QUIT_MSG   70

Definition at line 82 of file Nclient.c.

#define RANGE_CPU_VOLTAGE   12.0

Definition at line 172 of file Nclient.c.

#define RANGE_MOTOR_VOLTAGE   12.85

Definition at line 173 of file Nclient.c.

#define REALROBOT_MSG   71

Definition at line 83 of file Nclient.c.

#define RECEIVE_MESSAGE_MSG   73

Definition at line 85 of file Nclient.c.

#define REFRESHACTTRACE_MSG   152

Definition at line 90 of file Nclient.c.

#define REFRESHALL_MSG   150

Definition at line 88 of file Nclient.c.

#define REFRESHALLSENSORS_MSG   154

Definition at line 92 of file Nclient.c.

#define REFRESHALLTRACES_MSG   151

Definition at line 89 of file Nclient.c.

#define REFRESHBPSENSOR_MSG   155

Definition at line 93 of file Nclient.c.

#define REFRESHENCTRACE_MSG   153

Definition at line 91 of file Nclient.c.

#define REFRESHGRAPHICS_MSG   159

Definition at line 97 of file Nclient.c.

#define REFRESHIRSENSOR_MSG   156

Definition at line 94 of file Nclient.c.

#define REFRESHLSSENSOR_MSG   158

Definition at line 96 of file Nclient.c.

#define REFRESHSNSENSOR_MSG   157

Definition at line 95 of file Nclient.c.

#define REPLY_MSG   82

Definition at line 103 of file Nclient.c.

#define RMOVE_MSG   40

Definition at line 69 of file Nclient.c.

#define RPLACE_MSG   41

Definition at line 70 of file Nclient.c.

#define RPX_MSG   76

Definition at line 65 of file Nclient.c.

#define SEND_MESSAGE_MSG   72

Definition at line 84 of file Nclient.c.

#define SERIAL_ERROR   11

Definition at line 132 of file Nclient.c.

#define SETUP_LS_MSG   34

Definition at line 60 of file Nclient.c.

#define SIMULATEDROBOT_MSG   74

Definition at line 86 of file Nclient.c.

#define SONAR_MSG   84

Definition at line 105 of file Nclient.c.

#define SP_MSG   11

Definition at line 36 of file Nclient.c.

#define SPECIAL_MSG   300

Definition at line 120 of file Nclient.c.

#define ST_MSG   17

Definition at line 43 of file Nclient.c.

#define STATE_MSG   80

Definition at line 101 of file Nclient.c.

#define TK_MSG   19

Definition at line 45 of file Nclient.c.

#define TRUE   1

Definition at line 25 of file Nclient.c.

#define VELOCITY_MSG   89

Definition at line 110 of file Nclient.c.

#define VM_MSG   12

Definition at line 37 of file Nclient.c.

#define WS_MSG   39

Definition at line 67 of file Nclient.c.

#define ZR_MSG   20

Definition at line 46 of file Nclient.c.


Typedef Documentation

typedef struct _PosDataAll PosDataAll

Function Documentation

int ac ( int  t_ac,
int  s_ac,
int  r_ac 
)

Definition at line 1074 of file Nclient.c.

int add_Obs ( long  obs[2 *MAX_VERTICES+1])

Definition at line 2016 of file Nclient.c.

int add_obstacle ( long  obs[2 *MAX_VERTICES+1])

Definition at line 1991 of file Nclient.c.

long arm_mv ( long  l_mode,
long  l_v,
long  g_mode,
long  g_v 
)

Definition at line 3673 of file Nclient.c.

long arm_ws ( short  l,
short  g,
long  timeout,
long *  time_remain 
)

Definition at line 3643 of file Nclient.c.

long arm_zr ( short  override)

Definition at line 3618 of file Nclient.c.

static unsigned char bits_to_byte ( char  bt0,
char  bt1,
char  bt2,
char  bt3,
char  bt4,
char  bt5,
char  bt6,
char  bt7 
) [static]

Definition at line 903 of file Nclient.c.

int conf_cp ( int  mode)

Definition at line 1560 of file Nclient.c.

int conf_ir ( int  history,
int  order[16] 
)

Definition at line 1493 of file Nclient.c.

int conf_ls ( unsigned int  mode,
unsigned int  threshold,
unsigned int  width,
unsigned int  num_data,
unsigned int  processing 
)

Definition at line 1609 of file Nclient.c.

int conf_sg ( unsigned int  threshold,
unsigned int  min_points,
unsigned int  gap 
)

Definition at line 1848 of file Nclient.c.

int conf_sn ( int  rate,
int  order[16] 
)

Definition at line 1528 of file Nclient.c.

int conf_tm ( unsigned char  timeout)

Definition at line 1642 of file Nclient.c.

int connect_robot ( long  robot_id,
  ... 
)

Definition at line 981 of file Nclient.c.

char * convertAddr ( char *  name,
char *  addr 
)

Definition at line 269 of file Nclient.c.

int create_robot ( long  robot_id)

Definition at line 940 of file Nclient.c.

int ct ( void  )

Definition at line 1308 of file Nclient.c.

int da ( int  th,
int  tu 
)

Definition at line 1902 of file Nclient.c.

int delete_Obs ( long  obs[2 *MAX_VERTICES+1])

Definition at line 2057 of file Nclient.c.

int delete_obstacle ( long  obs[2 *MAX_VERTICES+1])

Definition at line 2032 of file Nclient.c.

int disconnect_robot ( long  robot_id)

Definition at line 1039 of file Nclient.c.

int dp ( int  x,
int  y 
)

Definition at line 1440 of file Nclient.c.

int draw_arc ( long  x_0,
long  y_0,
long  w,
long  h,
int  th1,
int  th2,
int  mode 
)

Definition at line 2521 of file Nclient.c.

int draw_line ( long  x_1,
long  y_1,
long  x_2,
long  y_2,
int  mode 
)

Definition at line 2485 of file Nclient.c.

int draw_robot ( long  x,
long  y,
int  th,
int  tu,
int  mode 
)

Definition at line 2453 of file Nclient.c.

signed short extract2byteint ( unsigned char *  buffer,
unsigned short *  index 
)

Definition at line 3043 of file Nclient.c.

unsigned short extract2byteuint ( unsigned char *  buffer,
unsigned short *  index 
)

Definition at line 3122 of file Nclient.c.

signed long extract4byteint ( unsigned char *  buffer,
unsigned short *  index 
)

Definition at line 3070 of file Nclient.c.

unsigned long extract4byteuint ( unsigned char *  buffer,
unsigned short *  index 
)

Definition at line 3144 of file Nclient.c.

int extract_receive_buffer_header ( unsigned short *  length,
unsigned char *  serial_number,
unsigned char *  packet_type,
unsigned char *  buffer 
)

Definition at line 2774 of file Nclient.c.

signed char extractchar ( unsigned char *  buffer,
unsigned short *  index 
)

Definition at line 3019 of file Nclient.c.

double extractdouble ( unsigned char *  buffer,
unsigned short *  index 
)

Definition at line 3169 of file Nclient.c.

unsigned char extractuchar ( unsigned char *  buffer,
unsigned short *  index 
)

Definition at line 3101 of file Nclient.c.

int get_bp ( void  )

Definition at line 1817 of file Nclient.c.

int get_cp ( void  )

Definition at line 1766 of file Nclient.c.

int get_ir ( void  )

Definition at line 1664 of file Nclient.c.

int get_laser ( int  laser[2 *NUM_LASER+1])

Definition at line 3215 of file Nclient.c.

int get_ls ( void  )

Definition at line 1787 of file Nclient.c.

int get_mask ( int  mask[NUM_MASK])

Definition at line 3224 of file Nclient.c.

int get_ra ( void  )

Definition at line 1745 of file Nclient.c.

int get_rc ( void  )

Definition at line 1705 of file Nclient.c.

int get_robot_conf ( long *  conf)

Definition at line 2724 of file Nclient.c.

int get_rpx ( long *  robot_pos)

Definition at line 1957 of file Nclient.c.

int get_rv ( void  )

Definition at line 1725 of file Nclient.c.

int get_sg ( void  )

Definition at line 1871 of file Nclient.c.

int get_sn ( void  )

Definition at line 1685 of file Nclient.c.

int get_state ( long  state[NUM_STATE])

Definition at line 3206 of file Nclient.c.

int gethostname ( char *  name,
int  len 
)
int gs ( void  )

Definition at line 1356 of file Nclient.c.

void init_mask ( void  )

Definition at line 2333 of file Nclient.c.

int init_receive_buffer ( unsigned short *  index)

Definition at line 2754 of file Nclient.c.

int init_send_buffer ( unsigned short *  index)

Definition at line 2796 of file Nclient.c.

int init_sensors ( void  )

Definition at line 2346 of file Nclient.c.

static int ipc_comm ( struct request_struct this_request,
struct reply_struct this_reply 
) [static]

Definition at line 467 of file Nclient.c.

int lp ( void  )

Definition at line 1394 of file Nclient.c.

int motion_check ( long  type,
double  a1,
double  a2,
double  a3,
double  a4,
double  a5,
double  a6,
double  a7,
double  collide[3] 
)

Definition at line 2683 of file Nclient.c.

int move_Obs ( long  obs[2 *MAX_VERTICES+1],
long  dx,
long  dy 
)

Definition at line 2102 of file Nclient.c.

int move_obstacle ( long  obs[2 *MAX_VERTICES+1],
long  dx,
long  dy 
)

Definition at line 2075 of file Nclient.c.

int mv ( int  t_mode,
int  t_mv,
int  s_mode,
int  s_mv,
int  r_mode,
int  r_mv 
)

Definition at line 1261 of file Nclient.c.

int new_world ( void  )

Definition at line 2110 of file Nclient.c.

static int open_socket_to_send_data ( int  tcp_port_num) [static]

Definition at line 283 of file Nclient.c.

int pa ( int  t_pa,
int  s_pa,
int  r_pa 
)

Definition at line 1169 of file Nclient.c.

int place_robot ( int  x,
int  y,
int  th,
int  tu 
)

Definition at line 2368 of file Nclient.c.

int posBumperGet ( PosData posData)

Definition at line 3424 of file Nclient.c.

int posCompassGet ( PosData posData)

Definition at line 3462 of file Nclient.c.

int posDataCheck ( void  )

Definition at line 3315 of file Nclient.c.

static int posDataProcess ( long *  buffer,
int  current,
PosData posData 
) [static]

Definition at line 3548 of file Nclient.c.

int posDataRequest ( int  posRequest)

Definition at line 3288 of file Nclient.c.

int posInfraredGet ( PosData posData,
int  infraredNumber 
)

Definition at line 3357 of file Nclient.c.

int posInfraredRingGet ( PosData  posData[INFRAREDS])

Definition at line 3335 of file Nclient.c.

int posLaserGet ( PosData posData)

Definition at line 3443 of file Nclient.c.

int posSonarGet ( PosData posData,
int  sonarNumber 
)

Definition at line 3400 of file Nclient.c.

int posSonarRingGet ( PosData  posData[SONARS])

Definition at line 3380 of file Nclient.c.

int posTimeGet ( void  )

Definition at line 3482 of file Nclient.c.

int pr ( int  t_pr,
int  s_pr,
int  r_pr 
)

Definition at line 1137 of file Nclient.c.

int predict_sensors ( int  x,
int  y,
int  th,
int  tu,
long *  state,
int *  laser 
)

Definition at line 2635 of file Nclient.c.

static int process_bumper_reply ( struct reply_struct this_reply) [static]

Definition at line 719 of file Nclient.c.

static int process_compass_reply ( struct reply_struct this_reply) [static]

Definition at line 692 of file Nclient.c.

static int process_conf_reply ( struct reply_struct this_reply,
long *  conf 
) [static]

Definition at line 657 of file Nclient.c.

static int process_configuration_reply ( struct reply_struct this_reply) [static]

Definition at line 640 of file Nclient.c.

static int process_infrared_reply ( struct reply_struct this_reply) [static]

Definition at line 580 of file Nclient.c.

static int process_laser_reply ( struct reply_struct this_reply) [static]

Definition at line 746 of file Nclient.c.

static int process_mcheck_reply ( struct reply_struct this_reply,
double  collide[3] 
) [static]

Definition at line 862 of file Nclient.c.

static int process_obstacle_reply ( struct reply_struct this_reply,
long *  obs 
) [static]

Definition at line 820 of file Nclient.c.

static int process_predict_reply ( struct reply_struct this_reply,
long *  state,
int *  laser 
) [static]

Definition at line 788 of file Nclient.c.

static int process_rpx_reply ( struct reply_struct this_reply,
long *  robot_pos 
) [static]

Definition at line 831 of file Nclient.c.

static int process_simple_reply ( struct reply_struct this_reply) [static]

Definition at line 815 of file Nclient.c.

static int process_socket_reply ( struct reply_struct this_reply) [static]

Definition at line 854 of file Nclient.c.

static int process_sonar_reply ( struct reply_struct this_reply) [static]

Definition at line 610 of file Nclient.c.

static int process_special_reply ( struct reply_struct this_reply,
unsigned char *  data 
) [static]

Definition at line 881 of file Nclient.c.

static int process_state_reply ( struct reply_struct this_reply) [static]

Definition at line 507 of file Nclient.c.

static int process_velocity_reply ( struct reply_struct this_reply) [static]

Definition at line 674 of file Nclient.c.

int quit_server ( void  )

Definition at line 2567 of file Nclient.c.

static int read_reply_from_socket ( int  sock,
struct reply_struct this_reply 
) [static]

Definition at line 365 of file Nclient.c.

static int readn ( register int  fd,
register char *  ptr,
register int  nbytes 
) [static]

Definition at line 339 of file Nclient.c.

int real_robot ( void  )

Definition at line 2587 of file Nclient.c.

int refresh_actual_trace ( void  )

Definition at line 2174 of file Nclient.c.

int refresh_all ( void  )

Definition at line 2136 of file Nclient.c.

int refresh_all_sensors ( void  )

Definition at line 2212 of file Nclient.c.

int refresh_all_traces ( void  )

Definition at line 2155 of file Nclient.c.

int refresh_bumper_sensor ( void  )

Definition at line 2231 of file Nclient.c.

int refresh_client_graphics ( void  )

Definition at line 2308 of file Nclient.c.

int refresh_encoder_trace ( void  )

Definition at line 2193 of file Nclient.c.

int refresh_infrared_sensor ( void  )

Definition at line 2250 of file Nclient.c.

int refresh_laser_sensor ( void  )

Definition at line 2288 of file Nclient.c.

int refresh_sonar_sensor ( void  )

Definition at line 2269 of file Nclient.c.

int server_is_running ( void  )

Definition at line 2557 of file Nclient.c.

int set_mask ( int  mask[NUM_MASK])

Definition at line 3233 of file Nclient.c.

int set_serv_tcp_port ( int  port)

Definition at line 3249 of file Nclient.c.

int set_server_machine_name ( char *  sname)

Definition at line 3242 of file Nclient.c.

int simulated_robot ( void  )

Definition at line 2607 of file Nclient.c.

int sp ( int  t_sp,
int  s_sp,
int  r_sp 
)

Definition at line 1103 of file Nclient.c.

int special_request ( unsigned char *  user_send_buffer,
unsigned char *  user_receive_buffer 
)

Definition at line 2401 of file Nclient.c.

int st ( void  )

Definition at line 1375 of file Nclient.c.

int stuff2byteint ( signed short  data,
unsigned char *  buffer,
unsigned short *  index 
)

Definition at line 2860 of file Nclient.c.

int stuff2byteuint ( unsigned short  data,
unsigned char *  buffer,
unsigned short *  index 
)

Definition at line 2936 of file Nclient.c.

int stuff4byteint ( signed long  data,
unsigned char *  buffer,
unsigned short *  index 
)

Definition at line 2887 of file Nclient.c.

int stuff4byteuint ( unsigned long  data,
unsigned char *  buffer,
unsigned short *  index 
)

Definition at line 2957 of file Nclient.c.

int stuff_send_buffer_header ( unsigned short  index,
unsigned char  serial_number,
unsigned char  packet_type,
unsigned char *  buffer 
)

Definition at line 2818 of file Nclient.c.

int stuffchar ( signed char  data,
unsigned char *  buffer,
unsigned short *  index 
)

Definition at line 2837 of file Nclient.c.

int stuffdouble ( double  data,
unsigned char *  buffer,
unsigned short *  index 
)

Definition at line 2982 of file Nclient.c.

int stuffuchar ( unsigned char  data,
unsigned char *  buffer,
unsigned short *  index 
)

Definition at line 2917 of file Nclient.c.

static int timeDataProcess ( long *  buffer,
int  current,
TimeData theTime 
) [static]

Definition at line 3583 of file Nclient.c.

int tk ( char *  talk_string)

Definition at line 1417 of file Nclient.c.

int vm ( int  t_vm,
int  s_vm,
int  r_vm 
)

Definition at line 1202 of file Nclient.c.

static float voltConvert ( unsigned char  reading,
float  range 
) [static]

Definition at line 3527 of file Nclient.c.

float voltCpuGet ( void  )

Definition at line 3497 of file Nclient.c.

static int voltDataProcess ( long *  buffer,
int  current,
unsigned char *  voltCPU,
unsigned char *  voltMotor 
) [static]

Definition at line 3603 of file Nclient.c.

float voltMotorGet ( void  )

Definition at line 3512 of file Nclient.c.

static int write_request_to_socket ( int  sock,
struct request_struct this_request 
) [static]

Definition at line 448 of file Nclient.c.

static int writen ( register int  fd,
register char *  ptr,
register int  nbytes 
) [static]

Definition at line 420 of file Nclient.c.

int ws ( unsigned char  t_ws,
unsigned char  s_ws,
unsigned char  r_ws,
unsigned char  timeout 
)

Definition at line 1933 of file Nclient.c.

int zr ( void  )

Definition at line 1463 of file Nclient.c.


Variable Documentation

int CONN_TYPE = -1

Definition at line 214 of file Nclient.c.

int connectedp = 0 [static]

Definition at line 234 of file Nclient.c.

char cvsid_host_client_Nclient_c[] = "$Header: /home/cvs/host/client/Nclient.c,v 1.31 1999/07/30 22:25:29 rak Exp $"

Definition at line 14 of file Nclient.c.

int dest_socket = 0 [static]

Definition at line 229 of file Nclient.c.

char Host_name[255] = "" [static]

Definition at line 231 of file Nclient.c.

int Laser[2 *NUM_LASER+1]

Definition at line 207 of file Nclient.c.

double LASER_CALIBRATION[8]

Definition at line 219 of file Nclient.c.

int laser_mode = 51 [static]

Definition at line 233 of file Nclient.c.

double LASER_OFFSET[2]

Definition at line 220 of file Nclient.c.

int own_tcp_port = 0 [static]

Definition at line 228 of file Nclient.c.

Definition at line 240 of file Nclient.c.

unsigned long posDataTime [static]

Definition at line 241 of file Nclient.c.

char ROBOT_MACHINE_NAME[80] = ""

Definition at line 213 of file Nclient.c.

int ROBOT_TCP_PORT = -1

Definition at line 217 of file Nclient.c.

int SERIAL_BAUD = -1

Definition at line 216 of file Nclient.c.

char SERIAL_PORT[40] = ""

Definition at line 215 of file Nclient.c.

int SERV_TCP_PORT = 7019

Definition at line 209 of file Nclient.c.

char SERVER_MACHINE_NAME[80] = ""

Definition at line 208 of file Nclient.c.

Definition at line 206 of file Nclient.c.

Definition at line 205 of file Nclient.c.

struct reply_struct the_reply [static]

Definition at line 237 of file Nclient.c.

struct request_struct the_request [static]

Definition at line 236 of file Nclient.c.

int usedSmask[NUM_MASK] [static]

Definition at line 230 of file Nclient.c.

unsigned char voltageCPU [static]

Definition at line 244 of file Nclient.c.

unsigned char voltageMotor [static]

Definition at line 245 of file Nclient.c.



scout_ndirect
Author(s): Gonçalo Cabrita and Pedro Sousa
autogenerated on Mon Jan 6 2014 11:25:23