This file contains hidden or 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
| // Define pins for the LEDs | |
| #define LED_PIN0 0 | |
| #define LED_PIN1 1 | |
| void setup() { | |
| pinMode(LED_PIN0, OUTPUT); | |
| pinMode(LED_PIN1, OUTPUT); | |
| } |
This file contains hidden or 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
| // the setup function runs once when you press reset or power the board | |
| void setup() { | |
| // initialize built in LED pin as an output. | |
| pinMode(LED_BUILTIN, OUTPUT); | |
| // initialize USB serial converter so we have a port created | |
| Serial.begin(); | |
| } | |
| // the loop function runs over and over again forever | |
| void loop() { |
This file contains hidden or 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
| //unknown days | |
| //AKleindolph 2025 (with ChatGPT) | |
| #include <avr/sleep.h> | |
| #include <avr/wdt.h> | |
| // Define pins for the LEDs | |
| #define LED_PIN0 0 | |
| #define LED_PIN1 1 |
This file contains hidden or 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
| // the setup function runs once when you press reset or power the board | |
| void setup() { | |
| pinMode(0, OUTPUT); | |
| } | |
| // the loop function runs over and over again forever | |
| void loop() { | |
| digitalWrite(0, HIGH); // turn the LED on (HIGH is the voltage level) | |
| delay(100); // wait | |
| digitalWrite(0, LOW); // turn the LED off by making the voltage LOW |
This file contains hidden or 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
| # Hide the cursor | |
| pygame.mouse.set_visible(False) |
This file contains hidden or 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
| import pygame | |
| import sys | |
| # Initialize Pygame | |
| pygame.init() | |
| # Set display resolution | |
| screen_width = 1024 # Change this to your screen's width | |
| screen_height = 600 # Change this to your screen's height |
This file contains hidden or 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
| while running: | |
| for event in pygame.event.get(): | |
| if event.type == pygame.QUIT: | |
| running = False | |
| elif event.type == pygame.KEYDOWN and event.key == pygame.K_ESCAPE: | |
| running = False |
This file contains hidden or 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
| import datetime | |
| import pytz | |
| def currentTime(timezone): | |
| try: | |
| #what goes here? | |
| return #what goes here? | |
| except: | |
| return #what goes here? | |
This file contains hidden or 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
| import json | |
| import requests | |
| from requests import get | |
| app_id = 'your id' | |
| app_key = 'your app key' | |
| url = 'https://api.edamam.com/api/recipes/v2?type=public&q=chicken&app_id='+app_id+'&app_key='+app_key+'&cuisineType=American' | |
| one_food = get(url).json() | |
| print (one_food['hits'][0]['recipe']['label']) |
This file contains hidden or 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
| import time | |
| import board | |
| import ssl | |
| import socketpool | |
| import wifi | |
| import microcontroller | |
| import adafruit_minimqtt.adafruit_minimqtt as MQTT | |
| import adafruit_ahtx0 | |
| from adafruit_seesaw.seesaw import Seesaw |
NewerOlder