File tree Expand file tree Collapse file tree 3 files changed +17
-5
lines changed Expand file tree Collapse file tree 3 files changed +17
-5
lines changed Original file line number Diff line number Diff line change 1
1
#include < platform-timer.hh>
2
2
3
- uint64_t get_time () {
3
+ extern " C " uint64_t get_time () {
4
4
StandardClint::init ();
5
5
return StandardClint::time ();
6
6
}
7
+
8
+ // extern "C" void set_next(uint64_t next_time) {
9
+ // StandardClint::init();
10
+ // StandardClint::setnext(next_time);
11
+ // }
12
+
13
+ // extern "C" void clear() {
14
+ // StandardClient::clear();
15
+ // }
Original file line number Diff line number Diff line change
1
+ #include "py/obj.h"
2
+
3
+ #define CLOCK_FREQ_KHZ (50000)
4
+ #define MS_TO_CLOCK_CYCLES (x ) (x * CLOCK_FREQ_KHZ) // clock 50mHz
5
+
6
+ extern "C" uint64_t get_time ();
Original file line number Diff line number Diff line change 1
1
#include < platform-uart.hh>
2
2
3
- extern uint64_t get_time ();
4
-
5
- #define CLOCK_FREQ_KHZ (50000 )
6
- #define MS_TO_CLOCK_CYCLES (x ) (x * CLOCK_FREQ_KHZ) // clock 50mHz
3
+ #include " timer.h"
7
4
8
5
extern " C" uint8_t uart_get_rx_level (volatile OpenTitanUart<115'200 > *block) {
9
6
return (block->fifoStatus >> 16 ) & 0xff ;
You can’t perform that action at this time.
0 commit comments