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 "MeMegaPi.h" | |
#include "Arduino.h" | |
#include "SoftwareSerial.h" | |
// Define the pins/outputs that map to the individual motors | |
#define WHEEL_LF = PORT2B // Set to the pin for LEFT FRONT wheel | |
#define WHEEL_RF = PORT1A // Set to the pin for RIGHT FRONT wheel | |
#define WHEEL_LR = PORT2A // Set to the pin for LEFT REAR wheel | |
#define WHEEL_RR = PORT1B // Set to the pin for RIGHT REAR wheel |
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
console.log('Client-side code running'); | |
const button = document.getElementById('myButton'); | |
button.addEventListener('click', function(e) { | |
console.log('button was clicked'); | |
fetch('/clicked', {method: 'POST'}) | |
.then(function(response) { | |
if(response.ok) { | |
console.log('click was recorded'); |
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
# -*- coding: utf-8 -*- | |
import sys | |
# Convert latitude and longitude to Maidenhead grid locators. | |
# | |
# Arguments are in signed decimal latitude and longitude. For example, | |
# the location of my QTH Palo Alto, CA is: 37.429167, -122.138056 or | |
# in degrees, minutes, and seconds: 37° 24' 49" N 122° 6' 26" W | |
# |