]> begriffs open source - freertos/blob - FreeRTOS-Plus/Source/CyaSSL/IDE/MDK5-ARM/Projects/CryptBenchmark/main.c
Update CyaSSL to latest version.
[freertos] / FreeRTOS-Plus / Source / CyaSSL / IDE / MDK5-ARM / Projects / CryptBenchmark / main.c
1 /* main.c
2  *
3  * Copyright (C) 2006-2014 wolfSSL Inc.
4  *
5  * This file is part of CyaSSL.
6  *
7  * CyaSSL is free software; you can redistribute it and/or modify
8  * it under the terms of the GNU General Public License as published by
9  * the Free Software Foundation; either version 2 of the License, or
10  * (at your option) any later version.
11  *
12  * CyaSSL is distributed in the hope that it will be useful,
13  * but WITHOUT ANY WARRANTY; without even the implied warranty of
14  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
15  * GNU General Public License for more details.
16  *
17  * You should have received a copy of the GNU General Public License
18  * along with this program; if not, write to the Free Software
19  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
20  */
21  
22 #ifdef HAVE_CONFIG_H
23     #include <config.h>
24 #endif
25
26 #include <cyassl/ctaocrypt/visibility.h>
27 #include <cyassl/ctaocrypt/logging.h>
28
29 #include "cmsis_os.h"
30 #include "rl_fs.h" 
31  
32 #include <stdio.h>
33
34 /*-----------------------------------------------------------------------------
35  *        Initialize a Flash Memory Card
36  *----------------------------------------------------------------------------*/
37 static void init_filesystem (void) {
38   int32_t retv;
39
40   retv = finit ("M0:");
41   if (retv == 0) {
42     retv = fmount ("M0:");
43     if (retv == 0) {
44       printf ("Drive M0 ready!\n");
45     }
46     else {
47       printf ("Drive M0 mount failed!\n");
48     }
49   }
50   else {
51     printf ("Drive M0 initialization failed!\n");
52   }
53 }
54 extern void benchmark_test(void * arg) ;
55 extern void init_time(void) ;
56
57 /*-----------------------------------------------------------------------------
58  *       mian entry 
59  *----------------------------------------------------------------------------*/
60
61 int main() 
62 {
63     void * arg = NULL ;
64
65     init_filesystem ();
66
67     printf("=== Start: Crypt Benchmark ===\n") ;
68         benchmark_test(arg) ;
69     printf("=== End: Crypt Benchmark  ===\n") ;   
70     
71 }