Implemented test using Peter Fleury's c uart library

This commit is contained in:
BlackMark 2019-07-30 18:32:32 +02:00
parent 59a83a304b
commit 48e312d076
3 changed files with 23 additions and 1 deletions

View File

@ -6,6 +6,7 @@
#include "flash/flash.hpp"
#include "io/io.hpp"
#include "uart/uart.h"
#include "uart/uart.hpp"
#include "uart/usart.h"
@ -164,11 +165,26 @@ void optimalUartTest()
_delay_ms(1000);
}
void cUartLibTest()
{
auto ramString = "Hello World from RAM. ";
auto flashString = F("Hello World from flash\r\n");
uart_init(UART_BAUD_SELECT(9600, F_CPU));
sei();
uart_puts(ramString);
uart_puts_p(reinterpret_cast<const char *>(flashString));
_delay_ms(1000);
}
int main()
{
newUartUsage();
// oldUsartUsage();
// optimalUartTest();
// cUartLibTest();
// spiTest();

@ -1 +1 @@
Subproject commit 6ded0e1c8dc9596e86512d269ace36c5bc5a7a5e
Subproject commit 099be106a74689beddab26a630ab423d83200f41

View File

@ -217,6 +217,12 @@
<Compile Include="uart\software.hpp">
<SubType>compile</SubType>
</Compile>
<None Include="uart\uart.cpp">
<SubType>compile</SubType>
</None>
<Compile Include="uart\uart.h">
<SubType>compile</SubType>
</Compile>
<Compile Include="uart\uart.hpp">
<SubType>compile</SubType>
</Compile>