#include <cstdlib>
#include <iostream>
#include <string>
#include <stdlib.h>
#include "../include/platform.h"
#include "../include/vecmath.h"
#include "../include/robot.h"
#include "../include/util.h"
#include "../include/cmd.h"
#include "../include/vars.h"
#include <stdio.h>
#include <string.h>
#include <unistd.h>
#include <fcntl.h>
#include <errno.h>
#include <termios.h>
#include <pthread.h>
#include <linux/serial.h>
#include <sys/types.h>
#include <sys/ipc.h>
#include <sys/shm.h>
#include <sys/sysinfo.h>
#include <sys/times.h>
#include <sys/time.h>
Defines | |
#define | FTOK_FILE "$HOME/." |
#define | sc(box, r, g, b) { box.red = r; box.green = g; box.blue = b; } |
#define | MAXSERIALERROR 100 |
#define | STDSERIALLINUX "/dev/ttyUSB0" |
#define | STDSERIALWINDOWS "COM4" |
Functions | |
void * | thread_callback (void *ptr) |
Variables | |
pthread_t | threads [THREADNUM] |
pthread_mutex_t | mutexes [MUTEXNUM] |
int | shmId |
void * | shm |
int | fdSerialPort |
#define FTOK_FILE "$HOME/." |
#define MAXSERIALERROR 100 |
#define sc | ( | box, | |||
r, | |||||
g, | |||||
b | ) | { box.red = r; box.green = g; box.blue = b; } |
#define STDSERIALLINUX "/dev/ttyUSB0" |
#define STDSERIALWINDOWS "COM4" |
void* thread_callback | ( | void * | ptr | ) |
int fdSerialPort |
pthread_mutex_t mutexes[MUTEXNUM] |
Initial value:
{ PTHREAD_MUTEX_INITIALIZER, PTHREAD_MUTEX_INITIALIZER, PTHREAD_MUTEX_INITIALIZER, PTHREAD_MUTEX_INITIALIZER, PTHREAD_MUTEX_INITIALIZER, PTHREAD_MUTEX_INITIALIZER, PTHREAD_MUTEX_INITIALIZER, PTHREAD_MUTEX_INITIALIZER}
void* shm |
int shmId |
pthread_t threads[THREADNUM] |