Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependencies: HBridgeDCMotor RateLimiter mbed
Revision 0:92564f74c7d2, committed 2015-12-11
- Comitter:
- tbjazic
- Date:
- Fri Dec 11 13:17:35 2015 +0000
- Commit message:
- Simple test of a L298N breakout board with two DC motors and a FRDM-K64F microcontroller board.
Changed in this revision
diff -r 000000000000 -r 92564f74c7d2 HBridgeDCMotor.lib --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/HBridgeDCMotor.lib Fri Dec 11 13:17:35 2015 +0000 @@ -0,0 +1,1 @@ +http://developer.mbed.org/teams/TVZ-Mechatronics-Team/code/HBridgeDCMotor/#1675a4c00925
diff -r 000000000000 -r 92564f74c7d2 RateLimiter.lib --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/RateLimiter.lib Fri Dec 11 13:17:35 2015 +0000 @@ -0,0 +1,1 @@ +http://developer.mbed.org/teams/TVZ-Mechatronics-Team/code/RateLimiter/#d735360f91f9
diff -r 000000000000 -r 92564f74c7d2 main.cpp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/main.cpp Fri Dec 11 13:17:35 2015 +0000 @@ -0,0 +1,19 @@ +#include "mbed.h" +#include "HBridgeDCMotor.h" + +HBridgeDCMotor m1(PTC10, PTC11); +HBridgeDCMotor m2(D6, D7); + +int main() { + float sampleTime = 50e-3, switchingFrequency = 25e3, rampTime = 3; + m1.configure(sampleTime, switchingFrequency, rampTime, rampTime); + m2.configure(sampleTime, switchingFrequency, rampTime, rampTime); + while(true) { + m1.setDutyCycle(1); + m2.setDutyCycle(1); + wait(10); + m1.setDutyCycle(-1); + m2.setDutyCycle(-1); + wait(10); + } +} \ No newline at end of file
diff -r 000000000000 -r 92564f74c7d2 mbed.bld --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/mbed.bld Fri Dec 11 13:17:35 2015 +0000 @@ -0,0 +1,1 @@ +http://mbed.org/users/mbed_official/code/mbed/builds/4fc01daae5a5 \ No newline at end of file