This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
void bsp_rtc_wdt_enable(uint32_t time_ms) | |
{ | |
rtc_wdt_protect_off(); | |
rtc_wdt_disable(); | |
rtc_wdt_set_length_of_reset_signal(RTC_WDT_SYS_RESET_SIG, RTC_WDT_LENGTH_3_2us); | |
rtc_wdt_set_stage(RTC_WDT_STAGE0, RTC_WDT_STAGE_ACTION_RESET_RTC); | |
rtc_wdt_set_time(RTC_WDT_STAGE0, 150000, time_ms); // Running off internal RC oscillator at 150 KHz | |
rtc_wdt_enable(); | |
rtc_wdt_protect_on(); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
license: mit |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
license: mit |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# name: Ctrl-D exits | |
# type: bool | |
# Ctrl-D exits the process when it is pressed on an empty line. | |
ctrld_exits = 1 | |
# name: Ctrl-C raises exception | |
# type: bool | |
# When Ctrl-C is pressed Clink will pass it thourgh to the parent by raising the | |
# appropriate exception. | |
passthrough_ctrlc = 1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'benchmark/ips' | |
require 'daybreak' | |
require 'dbm' | |
require 'fileutils' | |
require 'sqlite3_hash' | |
require 'xxhash' | |
class DaybreakDb | |
def initialize(db_file) | |
@db_file = db_file |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <iomanip> | |
#include <iostream> | |
#include <vector> | |
#include <termcolor.hpp> | |
void HexDump(const std::vector<uint8_t>& bytes, std::ostream& stream) | |
{ | |
char buff[17]; | |
size_t i = 0; |