[PD-cvs] externals/hardware/arduino/Pd_firmware Pd_firmware.pde, 1.14, 1.15
Hans-Christoph Steiner
eighthave at users.sourceforge.net
Mon Sep 4 00:38:42 CEST 2006
Update of /cvsroot/pure-data/externals/hardware/arduino/Pd_firmware
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv23444/Pd_firmware
Modified Files:
Pd_firmware.pde
Log Message:
arduino-test.pd
Index: Pd_firmware.pde
===================================================================
RCS file: /cvsroot/pure-data/externals/hardware/arduino/Pd_firmware/Pd_firmware.pde,v
retrieving revision 1.14
retrieving revision 1.15
diff -C2 -d -r1.14 -r1.15
*** Pd_firmware.pde 27 Aug 2006 03:36:47 -0000 1.14
--- Pd_firmware.pde 3 Sep 2006 22:38:40 -0000 1.15
***************
*** 37,41 ****
/*
* TODO: get digitalInput working
! * TODO: add pulseIn functionality
* TODO: add software PWM for servos, etc (servo.h or pulse.h)
* TODO: redesign protocol to accomodate boards with more I/Os
--- 37,42 ----
/*
* TODO: get digitalInput working
! * TODO: add pulseIn/pulseOut functionality
! * TODO: save settings to EEPROM
* TODO: add software PWM for servos, etc (servo.h or pulse.h)
* TODO: redesign protocol to accomodate boards with more I/Os
***************
*** 113,117 ****
/* two byte PWM data format
* ----------------------
! * 0 get ready for digital input bytes (ENABLE_SOFTWARE_PWM/ENABLE_PWM)
* 1 pin #
* 2 duty cycle expressed as 1 byte (255 = 100%)
--- 114,118 ----
/* two byte PWM data format
* ----------------------
! * 0 get ready for digital input bytes (ENABLE_PWM)
* 1 pin #
* 2 duty cycle expressed as 1 byte (255 = 100%)
***************
*** 218,233 ****
pinMode(pin,OUTPUT);
}
else if( (mode == PWM) && (pin >= 9) && (pin <= 11) ) {
digitalPinStatus = digitalPinStatus | (1 << pin);
pwmStatus = pwmStatus | (1 << pin);
- softPwmStatus = softPwmStatus &~ (1 << pin);
pinMode(pin,OUTPUT);
}
- else if(mode == SOFTPWM) {
- digitalPinStatus = digitalPinStatus | (1 << pin);
- pwmStatus = pwmStatus &~ (1 << pin);
- softPwmStatus = softPwmStatus | (1 << pin);
- pinMode(pin,OUTPUT);
- }
}
--- 219,228 ----
pinMode(pin,OUTPUT);
}
+ // this will apply to all digital pins once softPWM is implemented
else if( (mode == PWM) && (pin >= 9) && (pin <= 11) ) {
digitalPinStatus = digitalPinStatus | (1 << pin);
pwmStatus = pwmStatus | (1 << pin);
pinMode(pin,OUTPUT);
}
}
***************
*** 294,298 ****
setPinMode(storedInputData[0],INPUT);
break;
! case ENABLE_SOFTWARE_PWM:
setPinMode(storedInputData[1],SOFTPWM);
setSoftPwm(storedInputData[1], storedInputData[0]);
--- 289,293 ----
setPinMode(storedInputData[0],INPUT);
break;
! /* case ENABLE_SOFTWARE_PWM:
setPinMode(storedInputData[1],SOFTPWM);
setSoftPwm(storedInputData[1], storedInputData[0]);
***************
*** 304,307 ****
--- 299,303 ----
setSoftPwmFreq(storedInputData[0]);
break;
+ */
}
executeMultiByteCommand = 0;
More information about the Pd-cvs
mailing list