Skip to content

Commit

Permalink
WIP scaffolding
Browse files Browse the repository at this point in the history
  • Loading branch information
thebentern authored and caveman99 committed Apr 24, 2023
1 parent 6e26f95 commit 1eff8fd
Show file tree
Hide file tree
Showing 3 changed files with 53 additions and 0 deletions.
14 changes: 14 additions & 0 deletions arch/apollo3/apollo3.ini
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
[apollo3_base]
platform_packages = platform_packages=framework-arduinoapollo3@https://github.com/sparkfun/Arduino_Apollo3#v2.2.0
board = RAK11722
framework = arduino
build_type = debug
build_flags =
${arduino_base.build_flags}
-Isrc/platform/apollo3 -g
build_src_filter =
${arduino_base.build_src_filter} -<platform/esp32/> -<nimble/> -<mesh/api/> -<mesh/http/> -<modules/esp32> -<mesh/eth/> -<mqtt/> -<graphics> -<input> -<buzz> -<modules/Telemetry> -<platform/nrf52> -<platform/portduino> -<platform/rp2040> -<platform/stm32wl>
lib_deps =
${env.lib_deps}
lib_ignore =
mathertel/OneButton@^2.0.3
15 changes: 15 additions & 0 deletions src/platform/apollo3/architecture.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
#pragma once

#define ARCH_APOLLO3

//
// defaults for ARCH_APOLLO3 architecture
//

//
// set HW_VENDOR
//

#ifndef HW_VENDOR
#define HW_VENDOR HardwareModel_PRIVATE_HW
#endif
24 changes: 24 additions & 0 deletions src/platform/apollo3/main-apollo3.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
#include "RTC.h"
#include "configuration.h"

void setBluetoothEnable(bool on) {}

void playStartMelody() {}

void updateBatteryLevel(uint8_t level) {}

void getMacAddr(uint8_t *dmac)
{
for (int i = 0; i < 6; i++)
dmac[i] = i;
}

void cpuDeepSleep(uint64_t msecToWake) {}

/* pacify libc_nano */
extern "C" {
int _gettimeofday(struct timeval *tv, void *tzvp)
{
return -1;
}
}

0 comments on commit 1eff8fd

Please sign in to comment.