Skip to content

Instantly share code, notes, and snippets.

@ag88
ag88 / RTClock.cpp
Last active March 11, 2021 09:55
stm32duino libmaple f4 backup registers
/******************************************************************************
* The MIT License
*
* Copyright (c) 2010 LeafLabs LLC.
*
* Permission is hereby granted, free of charge, to any person
* obtaining a copy of this software and associated documentation
* files (the "Software"), to deal in the Software without
* restriction, including without limitation the rights to use, copy,
* modify, merge, publish, distribute, sublicense, and/or sell copies
@ag88
ag88 / gist:7da790bb0c2473a08aeeba2cd883bf49
Last active November 27, 2020 14:35
deploy tomcat webapp.war from command line using curl
curl --request PUT --upload-file webapp.war --basic --user user:password \
http://hostname:port/manager/text/deploy?path=/web_path\&update=true
@ag88
ag88 / stm32usb-serial-esp8266.ino
Last active December 16, 2019 10:05
stm32duino (libmaple core) usb-serial with connectivity to ESP8266
/* distribution: MIT lic*/
#include "Arduino.h"
#include <usb_serial.h>
#include <HardwareSerial.h>
#include <libmaple/usart.h>
#include <libmaple/usb_cdcacm.h>
void docmd();
bool chkcmd();
void setserial();
@ag88
ag88 / ARMDebianUbuntu.md
Last active May 27, 2025 12:26 — forked from Liryna/ARMDebianUbuntu.md
Emulating ARM on Debian/Ubuntu

You might want to read this to get an introduction to armel vs armhf.

If the below is too much, you can try Ubuntu-ARMv7-Qemu but note it contains non-free blobs.

Running ARM programs under linux (without starting QEMU VM!)

First, cross-compile user programs with GCC-ARM toolchain. Then install qemu-arm-static so that you can run ARM executables directly on linux

@ag88
ag88 / Makefile
Last active December 23, 2019 05:31
libmaple Makefile v0 alpha
# version 0 (alpha)
#
# This make file for libmaple core is possibly *dangerous*
# i.e. it compiles the sources (in src and STM32F1) directory
# and overwrite all the stuff in $(out_dir)
# $(out_dir) is the binary directory where the object files are dumped there
#
# make clean *deletes* the *$(out_dir)* (coded here as bin )
#
# this is a relative path makefile