Change i2c library
This commit is contained in:
parent
e9d3a95239
commit
f00a154e59
3
.gitmodules
vendored
3
.gitmodules
vendored
@ -13,3 +13,6 @@
|
||||
[submodule "ds3231/type"]
|
||||
path = ds3231/type
|
||||
url = git@git.blackmark.me:avr/type.git
|
||||
[submodule "ds3231/i2c"]
|
||||
path = ds3231/i2c
|
||||
url = git@git.blackmark.me:avr/i2c.git
|
||||
|
@ -1 +1 @@
|
||||
Subproject commit 04af54e7c8029f05a999f85afa0bcc194f654fed
|
||||
Subproject commit 27680097203f1482ba61a9cceef689305d7eadc4
|
@ -83,6 +83,17 @@
|
||||
</custom>
|
||||
<AAFDebugger>
|
||||
<AAFDebugFiles>
|
||||
<DebugFile>
|
||||
<path>\Debug\ds3231.lss</path>
|
||||
<AAFSetting>
|
||||
<Label>Lss Files</Label>
|
||||
<Extention>.lss</Extention>
|
||||
<Regex>^\s*(?<address>[a-f0-9]*):\s*.*$</Regex>
|
||||
<DebugEnabled>true</DebugEnabled>
|
||||
<RegexGroups>address</RegexGroups>
|
||||
<DebuggerExpression>$pc</DebuggerExpression>
|
||||
</AAFSetting>
|
||||
</DebugFile>
|
||||
</AAFDebugFiles>
|
||||
</AAFDebugger>
|
||||
</PropertyGroup>
|
||||
@ -213,21 +224,15 @@
|
||||
<Compile Include="ds3231\rtc.h">
|
||||
<SubType>compile</SubType>
|
||||
</Compile>
|
||||
<Compile Include="ds3231\twi-lowlevel.cpp">
|
||||
<SubType>compile</SubType>
|
||||
</Compile>
|
||||
<Compile Include="ds3231\twi-lowlevel.h">
|
||||
<SubType>compile</SubType>
|
||||
</Compile>
|
||||
<Compile Include="ds3231\twi.cpp">
|
||||
<SubType>compile</SubType>
|
||||
</Compile>
|
||||
<Compile Include="ds3231\twi.h">
|
||||
<SubType>compile</SubType>
|
||||
</Compile>
|
||||
<Compile Include="flash\flash.hpp">
|
||||
<SubType>compile</SubType>
|
||||
</Compile>
|
||||
<Compile Include="i2c\hardware.hpp">
|
||||
<SubType>compile</SubType>
|
||||
</Compile>
|
||||
<Compile Include="i2c\i2c.hpp">
|
||||
<SubType>compile</SubType>
|
||||
</Compile>
|
||||
<Compile Include="io\io.hpp">
|
||||
<SubType>compile</SubType>
|
||||
</Compile>
|
||||
@ -266,6 +271,7 @@
|
||||
<Folder Include="ds3231" />
|
||||
<Folder Include="io" />
|
||||
<Folder Include="flash" />
|
||||
<Folder Include="i2c" />
|
||||
<Folder Include="uart" />
|
||||
<Folder Include="type" />
|
||||
</ItemGroup>
|
||||
|
1
ds3231/i2c
Submodule
1
ds3231/i2c
Submodule
@ -0,0 +1 @@
|
||||
Subproject commit ff131d92a1b8e92efc2ae24306d7b7cac3cfb28a
|
@ -1,14 +1,16 @@
|
||||
#include "clock.hpp"
|
||||
|
||||
#include <avr/interrupt.h>
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
#include <time.h>
|
||||
|
||||
#include "systime.h"
|
||||
#include <avr/interrupt.h>
|
||||
|
||||
#include "uart/uart.hpp"
|
||||
|
||||
#include "systime.h"
|
||||
|
||||
using uart_t = uart::Uart0<>;
|
||||
|
||||
REGISTER_UART0_INT_VECTORS(uart_t);
|
||||
|
@ -22,7 +22,6 @@ int SysTime::euDST( const time_t *pTime, int32_t *pZ )
|
||||
//////////////////////////////////////////////////////////////////////////
|
||||
bool SysTime::init()
|
||||
{
|
||||
twi_init_master();
|
||||
rtc_init();
|
||||
|
||||
if( !rtc_is_ds3231() )
|
||||
|
@ -9,7 +9,6 @@
|
||||
|
||||
#include <time.h>
|
||||
|
||||
#include "ds3231/twi.h"
|
||||
#include "ds3231/rtc.h"
|
||||
|
||||
class SysTime
|
||||
|
Loading…
Reference in New Issue
Block a user