diff options
author | siddhu8990 | 2016-10-18 10:31:23 +0530 |
---|---|---|
committer | siddhu8990 | 2016-10-18 10:31:23 +0530 |
commit | 52de97290366abe6cfb0576ca19d9c1732c1f0ea (patch) | |
tree | c2effe8b6e60c112b126f1d39ddb0d82253dc4e9 /src/c/scilab-arduino | |
parent | 9a30882032e80661fe6c69d7c50da0154e4e431f (diff) | |
download | Scilab2C_fossee_old-52de97290366abe6cfb0576ca19d9c1732c1f0ea.tar.gz Scilab2C_fossee_old-52de97290366abe6cfb0576ca19d9c1732c1f0ea.tar.bz2 Scilab2C_fossee_old-52de97290366abe6cfb0576ca19d9c1732c1f0ea.zip |
Suppressed declaration of not required variables and functions
Diffstat (limited to 'src/c/scilab-arduino')
21 files changed, 30 insertions, 36 deletions
diff --git a/src/c/scilab-arduino/cmd_analog_out/u8cmd_analog_outs.c b/src/c/scilab-arduino/cmd_analog_out/u8cmd_analog_outs.c index aa7dac0..07e1805 100644 --- a/src/c/scilab-arduino/cmd_analog_out/u8cmd_analog_outs.c +++ b/src/c/scilab-arduino/cmd_analog_out/u8cmd_analog_outs.c @@ -13,9 +13,9 @@ #include "cmd_analog_out.h" #include "Arduino.h" -uint8 u8cmd_analog_outs(uint8 board_no, uint8 pin, uint8 value) +void u8cmd_analog_outs(uint8 board_no, uint8 pin, uint8 value) { analogWrite(pin,value); - return 0; + } diff --git a/src/c/scilab-arduino/cmd_dcmotor_run/u8cmd_dcmotor_runs.c b/src/c/scilab-arduino/cmd_dcmotor_run/u8cmd_dcmotor_runs.c index 07798ab..ff2f6e5 100644 --- a/src/c/scilab-arduino/cmd_dcmotor_run/u8cmd_dcmotor_runs.c +++ b/src/c/scilab-arduino/cmd_dcmotor_run/u8cmd_dcmotor_runs.c @@ -13,7 +13,7 @@ #include "cmd_dcmotor_run.h" #include "Arduino.h" -uint8 u8cmd_dcmotor_runs(uint8 board_no, uint8 motor_no, int16 duty) +void u8cmd_dcmotor_runs(uint8 board_no, uint8 motor_no, int16 duty) { uint8 direction = 1; if(duty >= 0) @@ -55,6 +55,5 @@ uint8 u8cmd_dcmotor_runs(uint8 board_no, uint8 motor_no, int16 duty) } } - return 0; } diff --git a/src/c/scilab-arduino/cmd_dcmotor_setup/u8cmd_dcmotor_setups.c b/src/c/scilab-arduino/cmd_dcmotor_setup/u8cmd_dcmotor_setups.c index d1d0fea..194074e 100644 --- a/src/c/scilab-arduino/cmd_dcmotor_setup/u8cmd_dcmotor_setups.c +++ b/src/c/scilab-arduino/cmd_dcmotor_setup/u8cmd_dcmotor_setups.c @@ -15,7 +15,7 @@ uint8 dcm_pin_1[4], dcm_pin_2[4], dcm_mode[4]; -uint8 u8cmd_dcmotor_setups(uint8 board_no, uint8 driver_type, uint8 motor_no,\ +void u8cmd_dcmotor_setups(uint8 board_no, uint8 driver_type, uint8 motor_no,\ uint8 pin_1, uint8 pin_2) { dcm_pin_1[motor_no] = pin_1; @@ -38,6 +38,5 @@ uint8 u8cmd_dcmotor_setups(uint8 board_no, uint8 driver_type, uint8 motor_no,\ digitalWrite(pin_2,LOW); } - return 0; } diff --git a/src/c/scilab-arduino/cmd_digital_out/u8cmd_digital_outs.c b/src/c/scilab-arduino/cmd_digital_out/u8cmd_digital_outs.c index 2e5c90d..58e7a85 100644 --- a/src/c/scilab-arduino/cmd_digital_out/u8cmd_digital_outs.c +++ b/src/c/scilab-arduino/cmd_digital_out/u8cmd_digital_outs.c @@ -14,9 +14,9 @@ #include "Arduino.h" -uint8 u8cmd_digital_outs(uint8 board_no, uint8 pin, uint8 value) +void u8cmd_digital_outs(uint8 board_no, uint8 pin, uint8 value) { digitalWrite(pin,value); - return 0; + } diff --git a/src/c/scilab-arduino/cmd_servo_attach/u8cmd_servo_attach.cpp b/src/c/scilab-arduino/cmd_servo_attach/u8cmd_servo_attachs.cpp index a89363b..ae2c68c 100644 --- a/src/c/scilab-arduino/cmd_servo_attach/u8cmd_servo_attach.cpp +++ b/src/c/scilab-arduino/cmd_servo_attach/u8cmd_servo_attachs.cpp @@ -6,7 +6,7 @@ #include "Arduino.h" #include<Servo.h> Servo servo1,servo2; -uint8 u8cmd_servo_attach(uint8 h,uint8 servo_no) +void u8cmd_servo_attach(uint8 h,uint8 servo_no) { // h -> Board no. reserve for future use // servo_no -> pin no.(9 and 10). @@ -21,6 +21,5 @@ uint8 u8cmd_servo_attach(uint8 h,uint8 servo_no) servo2.write(0); } - return 0; } diff --git a/src/c/scilab-arduino/cmd_servo_detach/u8cmd_servo_detach.cpp b/src/c/scilab-arduino/cmd_servo_detach/u8cmd_servo_detachs.cpp index 95faf4c..c8c5beb 100644 --- a/src/c/scilab-arduino/cmd_servo_detach/u8cmd_servo_detach.cpp +++ b/src/c/scilab-arduino/cmd_servo_detach/u8cmd_servo_detachs.cpp @@ -5,7 +5,7 @@ #include "Arduino.h" #include<Servo.h> Servo servo1,servo2; -uint8 u8cmd_servo_detach(uint8 h,uint8 servo_no) +void u8cmd_servo_detach(uint8 h,uint8 servo_no) { // h -> Board no. reserve for future use // servo_no -> pin no.(9 and 10). @@ -18,7 +18,6 @@ uint8 u8cmd_servo_detach(uint8 h,uint8 servo_no) { servo2.detach(); } - - return 0; + } diff --git a/src/c/scilab-arduino/cmd_servo_move/u8cmd_servo_move.cpp b/src/c/scilab-arduino/cmd_servo_move/u8cmd_servo_moves.cpp index e887476..94f3563 100644 --- a/src/c/scilab-arduino/cmd_servo_move/u8cmd_servo_move.cpp +++ b/src/c/scilab-arduino/cmd_servo_move/u8cmd_servo_moves.cpp @@ -6,7 +6,7 @@ #include "Arduino.h" #include<Servo.h> Servo servo1,servo2; -uint8 u8cmd_servo_move(uint8 h,uint8 servo_no,uint8 val) +void u8cmd_servo_move(uint8 h,uint8 servo_no,uint8 val) { // h -> Board no. reserve for future use // servo_no -> pin no.(9 and 10). @@ -22,6 +22,5 @@ uint8 u8cmd_servo_move(uint8 h,uint8 servo_no,uint8 val) servo2.write(val); } } - return 0; } diff --git a/src/c/scilab-arduino/includes/cmd_analog_out.h b/src/c/scilab-arduino/includes/cmd_analog_out.h index a0da68e..5f9e527 100644 --- a/src/c/scilab-arduino/includes/cmd_analog_out.h +++ b/src/c/scilab-arduino/includes/cmd_analog_out.h @@ -19,7 +19,7 @@ extern "C" { #endif -uint8 u8cmd_analog_outs(uint8 board_no, uint8 pin, uint8 value); +void u8cmd_analog_outs(uint8 board_no, uint8 pin, uint8 value); #ifdef __cplusplus } /* extern "C" */ diff --git a/src/c/scilab-arduino/includes/cmd_dcmotor_run.h b/src/c/scilab-arduino/includes/cmd_dcmotor_run.h index 82df60a..4bc1ccc 100644 --- a/src/c/scilab-arduino/includes/cmd_dcmotor_run.h +++ b/src/c/scilab-arduino/includes/cmd_dcmotor_run.h @@ -22,7 +22,7 @@ extern "C" { extern uint8 dcm_pin_1[4], dcm_pin_2[4], dcm_mode[4]; -uint8 u8cmd_dc_motor_runs(uint8 board_no, uint8 motor_no, int16 duty); +void u8cmd_dc_motor_runs(uint8 board_no, uint8 motor_no, int16 duty); #ifdef __cplusplus } /* extern "C" */ diff --git a/src/c/scilab-arduino/includes/cmd_dcmotor_setup.h b/src/c/scilab-arduino/includes/cmd_dcmotor_setup.h index 66fa04e..e7de474 100644 --- a/src/c/scilab-arduino/includes/cmd_dcmotor_setup.h +++ b/src/c/scilab-arduino/includes/cmd_dcmotor_setup.h @@ -22,7 +22,7 @@ extern "C" { extern uint8 dcm_pin_1[4], dcm_pin_2[4], dcm_mode[4]; -uint8 u8cmd_dc_motor_setups(uint8 board_no, uint8 driver_type, uint8 motor_no,\ +void u8cmd_dc_motor_setups(uint8 board_no, uint8 driver_type, uint8 motor_no,\ uint8 pin_1, uint8 pin_2); #ifdef __cplusplus diff --git a/src/c/scilab-arduino/includes/cmd_digital_out.h b/src/c/scilab-arduino/includes/cmd_digital_out.h index ee459d1..a0150ce 100644 --- a/src/c/scilab-arduino/includes/cmd_digital_out.h +++ b/src/c/scilab-arduino/includes/cmd_digital_out.h @@ -20,7 +20,7 @@ extern "C" { #endif -uint8 u8cmd_digital_outs(uint8 board_no, uint8 pin, uint8 value); +void u8cmd_digital_outs(uint8 board_no, uint8 pin, uint8 value); #ifdef __cplusplus } /* extern "C" */ diff --git a/src/c/scilab-arduino/includes/cmd_servo_attach.h b/src/c/scilab-arduino/includes/cmd_servo_attach.h index 5dd3ed6..8707833 100644 --- a/src/c/scilab-arduino/includes/cmd_servo_attach.h +++ b/src/c/scilab-arduino/includes/cmd_servo_attach.h @@ -14,7 +14,7 @@ extern "C" { extern Servo servo1,servo2; -uint8 u8cmd_servo_attach(uint8 h, uint8 servo_no ); +void u8cmd_servo_attach(uint8 h, uint8 servo_no ); #ifdef __cplusplus } /* extern "C" */ diff --git a/src/c/scilab-arduino/includes/cmd_servo_detach.h b/src/c/scilab-arduino/includes/cmd_servo_detach.h index ce74d62..6ac5e2b 100644 --- a/src/c/scilab-arduino/includes/cmd_servo_detach.h +++ b/src/c/scilab-arduino/includes/cmd_servo_detach.h @@ -15,7 +15,7 @@ extern "C" { extern Servo servo1,servo2; -uint8 u8cmd_servo_detach(uint8 h, uint8 servo_no ); +void u8cmd_servo_detach(uint8 h, uint8 servo_no ); #ifdef __cplusplus } /* extern "C" */ diff --git a/src/c/scilab-arduino/includes/cmd_servo_move.h b/src/c/scilab-arduino/includes/cmd_servo_move.h index 9013d3c..7f9bc0d 100644 --- a/src/c/scilab-arduino/includes/cmd_servo_move.h +++ b/src/c/scilab-arduino/includes/cmd_servo_move.h @@ -15,7 +15,7 @@ extern "C" { extern Servo servo1,servo2; -uint8 u8cmd_servo_move(uint8 h, uint8 servo_no,uint8 val); +void u8cmd_servo_move(uint8 h, uint8 servo_no,uint8 val); #ifdef __cplusplus } /* extern "C" */ diff --git a/src/c/scilab-arduino/includes/sleep.h b/src/c/scilab-arduino/includes/sleep.h index 4c8cbc2..8daab69 100644 --- a/src/c/scilab-arduino/includes/sleep.h +++ b/src/c/scilab-arduino/includes/sleep.h @@ -19,7 +19,7 @@ extern "C" { #endif -uint8 u16sleeps(uint16 delay_ms); +void u16sleeps(uint16 delay_ms); #ifdef __cplusplus } /* extern "C" */ diff --git a/src/c/scilab-arduino/interfaces/int_cmd_analog_out.h b/src/c/scilab-arduino/interfaces/int_cmd_analog_out.h index ead26ac..2410523 100644 --- a/src/c/scilab-arduino/interfaces/int_cmd_analog_out.h +++ b/src/c/scilab-arduino/interfaces/int_cmd_analog_out.h @@ -20,10 +20,10 @@ extern "C" { #endif -#define d0d0d0cmd_analog_outu80(in1,in2,in3) u8cmd_analog_outs((uint8)in1,\ +#define d0d0d0cmd_analog_out(in1,in2,in3) u8cmd_analog_outs((uint8)in1,\ (uint8)in2,(uint8)in3) -#define d0d0u80cmd_analog_outu80(in1,in2,in3) u8cmd_analog_outs((uint8)in1,\ +#define d0d0u80cmd_analog_out(in1,in2,in3) u8cmd_analog_outs((uint8)in1,\ (uint8)in2,(uint8)in3) #ifdef __cplusplus diff --git a/src/c/scilab-arduino/interfaces/int_cmd_dcmotor.h b/src/c/scilab-arduino/interfaces/int_cmd_dcmotor.h index b35583d..7f8db41 100644 --- a/src/c/scilab-arduino/interfaces/int_cmd_dcmotor.h +++ b/src/c/scilab-arduino/interfaces/int_cmd_dcmotor.h @@ -20,15 +20,15 @@ extern "C" { #endif -#define d0d0d0d0d0cmd_dcmotor_setupu80(in1,in2,in3,in4,in5)\ +#define d0d0d0d0d0cmd_dcmotor_setup(in1,in2,in3,in4,in5)\ u8cmd_dcmotor_setups((uint8)in1,(uint8)in2,(uint8)in3,\ (uint8)in4,(uint8)in5) -#define d0d0d0cmd_dcmotor_runu80(in1,in2,in3) u8cmd_dcmotor_runs((uint8)in1,\ +#define d0d0d0cmd_dcmotor_run(in1,in2,in3) u8cmd_dcmotor_runs((uint8)in1,\ (uint8)in2, (int16)in3); -#define d0d0u160cmd_dcmotor_runu80(in1,in2,in3) u8cmd_dcmotor_runs((uint8)in1,\ +#define d0d0u160cmd_dcmotor_run(in1,in2,in3) u8cmd_dcmotor_runs((uint8)in1,\ (uint8)in2, (int16)in3); diff --git a/src/c/scilab-arduino/interfaces/int_cmd_digital_out.h b/src/c/scilab-arduino/interfaces/int_cmd_digital_out.h index 4585f12..009ff7d 100644 --- a/src/c/scilab-arduino/interfaces/int_cmd_digital_out.h +++ b/src/c/scilab-arduino/interfaces/int_cmd_digital_out.h @@ -20,11 +20,11 @@ extern "C" { #endif -#define d0d0d0cmd_digital_outu80(in1,in2,in3) u8cmd_digital_outs((uint8)in1,\ +#define d0d0d0cmd_digital_out(in1,in2,in3) u8cmd_digital_outs((uint8)in1,\ (uint8)in2,(uint8)in3) //Required when input from one pin is directed to other output pin. -#define d0d0u80cmd_digital_outu80(in1,in2,in3) u8cmd_digital_outs((uint8)in1,\ +#define d0d0u80cmd_digital_out(in1,in2,in3) u8cmd_digital_outs((uint8)in1,\ (uint8)in2, (uint8)in3) diff --git a/src/c/scilab-arduino/interfaces/int_cmd_servo.h b/src/c/scilab-arduino/interfaces/int_cmd_servo.h index d99a044..3b48273 100644 --- a/src/c/scilab-arduino/interfaces/int_cmd_servo.h +++ b/src/c/scilab-arduino/interfaces/int_cmd_servo.h @@ -13,11 +13,11 @@ extern "C" { #endif -#define d0d0cmd_servo_attachu80(in1,in2) u8cmd_servo_attach((uint8)in1,(uint8)in2); +#define d0d0cmd_servo_attach(in1,in2) u8cmd_servo_attach((uint8)in1,(uint8)in2); -#define d0d0cmd_servo_detachu80(in1,in2) u8cmd_servo_detach((uint8)in1,(uint8)in2); +#define d0d0cmd_servo_detach(in1,in2) u8cmd_servo_detach((uint8)in1,(uint8)in2); -#define d0d0d0cmd_servo_moveu80(in1,in2,in3) u8cmd_servo_move((uint8)in1,(uint8)in2,(uint8)in3); +#define d0d0d0cmd_servo_move(in1,in2,in3) u8cmd_servo_move((uint8)in1,(uint8)in2,(uint8)in3); #ifdef __cplusplus diff --git a/src/c/scilab-arduino/interfaces/int_sleep.h b/src/c/scilab-arduino/interfaces/int_sleep.h index 8e2d082..a0d3545 100644 --- a/src/c/scilab-arduino/interfaces/int_sleep.h +++ b/src/c/scilab-arduino/interfaces/int_sleep.h @@ -20,7 +20,7 @@ extern "C" { #endif -#define d0sleepu80(in1) u16sleeps((uint16)in1) +#define d0sleep(in1) u16sleeps((uint16)in1) #ifdef __cplusplus } /* extern "C" */ diff --git a/src/c/scilab-arduino/sleep/u16sleeps.c b/src/c/scilab-arduino/sleep/u16sleeps.c index 14da0ba..fc59ca8 100644 --- a/src/c/scilab-arduino/sleep/u16sleeps.c +++ b/src/c/scilab-arduino/sleep/u16sleeps.c @@ -12,9 +12,8 @@ #include "sleep.h" -uint8 u16sleeps(uint16 delay_ms) +void u16sleeps(uint16 delay_ms) { delay(delay_ms); - return 0; } |