OLD | NEW |
1 // Copyright (c) 2015, the Fletch project authors. Please see the AUTHORS file | 1 // Copyright (c) 2015, the Dartino project authors. Please see the AUTHORS file |
2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
3 // BSD-style license that can be found in the LICENSE.md file. | 3 // BSD-style license that can be found in the LICENSE.md file. |
4 | 4 |
5 import 'dart:typed_data'; | 5 import 'dart:typed_data'; |
6 | 6 |
7 import 'package:stm32f746g_disco/uart.dart'; | 7 import 'package:stm32f746g_disco/uart.dart'; |
8 import 'package:stm32f746g_disco/stm32f746g_disco.dart'; | 8 import 'package:stm32f746g_disco/stm32f746g_disco.dart'; |
9 | 9 |
10 main() { | 10 main() { |
11 const int CR = 13; | 11 const int CR = 13; |
(...skipping 13 matching lines...) Expand all Loading... |
25 uart.writeByte(byte); | 25 uart.writeByte(byte); |
26 if (byte == CR) { | 26 if (byte == CR) { |
27 uart.writeByte(LF); | 27 uart.writeByte(LF); |
28 } | 28 } |
29 } | 29 } |
30 } else { | 30 } else { |
31 uart.write(data.buffer); | 31 uart.write(data.buffer); |
32 } | 32 } |
33 } | 33 } |
34 } | 34 } |
OLD | NEW |