Added basic interface test

This commit is contained in:
BlackMark 2020-02-01 23:41:55 +01:00
parent 060da11a75
commit 4f79d1d1d8
5 changed files with 30 additions and 10 deletions

3
.gitmodules vendored
View File

@ -1,3 +1,6 @@
[submodule "adc/adc"]
path = adc/adc
url = git@git.blackmark.me:avr/adc.git
[submodule "adc/io"]
path = adc/io
url = git@git.blackmark.me:avr/io.git

@ -1 +1 @@
Subproject commit c741dc98a177834296b4bf877bfe92efdf912d72
Subproject commit 2f54f9217fdbc92658a03babeae14f3e97954887

View File

@ -179,12 +179,16 @@
<Compile Include="adc\adc.hpp">
<SubType>compile</SubType>
</Compile>
<Compile Include="adc\hardware.hpp">
<SubType>compile</SubType>
</Compile>
<Compile Include="main.cpp">
<SubType>compile</SubType>
</Compile>
</ItemGroup>
<ItemGroup>
<Folder Include="adc" />
<Folder Include="io" />
</ItemGroup>
<Import Project="$(AVRSTUDIO_EXE_PATH)\\Vs\\Compiler.targets" />
</Project>

1
adc/io Submodule

@ -0,0 +1 @@
Subproject commit 80de36ee7ee3e6b0842d5eaee81d54062cb496b2

View File

@ -1,6 +1,18 @@
#include "adc/adc.hpp"
void adcTest()
{
using namespace adc;
using adc_conf = Config<>;
Adc<adc_conf, io::P::C5> adcPin;
adcPin.read();
}
int main()
{
adcTest();
return 0;
}