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.
Revision 1:f67201cad9f7, committed 2020-01-12
- Comitter:
- robertbuc
- Date:
- Sun Jan 12 21:59:18 2020 +0000
- Parent:
- 0:b4e3ba4a7bd3
- Commit message:
- digitalio
Changed in this revision
| E6__FAIL_Lekt1_Bankomat_Digitalio.cpp | Show diff for this revision Revisions of this file |
--- a/E6__FAIL_Lekt1_Bankomat_Digitalio.cpp Sun Jan 12 21:58:09 2020 +0000
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,45 +0,0 @@
-/*
-6. [Bankomat] Erzeuge eine Bankomat Nachahmung mit folgenden Funktionen:
-
-random() // erzeugen eines zufälligen 4-stelligen Pins
-showPin() // zeigt den Pin-Code an den Leds an
-int checkPin() // Überprüft eine Eingabe mit dem Pin und gibt 1 zurück wenn gleich, sonst 0
-
-*/
-#include "mbed.h"
-
-//BusOut leds(D0,D3,D6,D9,D11,D12,A1,A5);
-BusOut leds(D0,D3,D6,D9);
-
-int random();
-void showpin();
-int checkpin(int wert);
-
-int main()
-{
-
- while(1)
- {
-
- random();
-
-
- }
-}
-
-int random()
-{
-
-
- int a=0;
- int e=1;
- double r = e - a + 1;
- printf("%d, %d\n",a,e);
- return a + (int)(r * rand()/(RAND_MAX+1.0));
-
-
-
-
-
-
-}
\ No newline at end of file