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.
Diff: main.cpp
- Revision:
- 5:1ce3ec1e5f8b
- Parent:
- 4:0c327b37ddc1
--- a/main.cpp Sun Apr 06 20:19:56 2014 +0000
+++ b/main.cpp Sun Apr 13 19:45:35 2014 +0000
@@ -3,22 +3,15 @@
SPI spi(p5,p6,p7);
AD7390 Test(spi,p10,p11);
-DigitalOut Led(LED1);
int main(){
- Test.Init();
+ Test.Init(10000000);
while (true){
Test.Reset();
- Test.WriteL(2.5,3.3);
- Led = 1;
- wait(5);
- Test.Reset();
- Led = 0;
- Test.WriteL(1.5,3.3);
- Led = 1;
- wait(5);
- Led = 0;
-
+ for (float V = 0; V !=3.3; V=V+0.005){
+ Test.WriteL(V,3.3);
+ wait(0.02);
+ }
}
}