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
from ximea import xiapi | |
import time | |
#create instance for first connected camera | |
cam = xiapi.Camera() | |
#start communication | |
#to open specific device, use: | |
#cam.open_device_by_SN('41305651') | |
#(open by serial number) |
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 cv2 | |
import os | |
import time | |
def main(): | |
# Camera settings | |
width, height, fps = 640, 360, 260 | |
frame_count_to_capture = fps # Number of frames for 1 second | |
temp_image_folder = "temp_images" | |
os.makedirs(temp_image_folder, exist_ok=True) |
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
#!/bin/bash | |
# File to store the CPU temperature logs | |
LOG_FILE="cpu_temp_log.csv" | |
# Function to get CPU temperature | |
get_cpu_temp() { | |
# Using sensors command to get CPU temp from the specified sensor | |
sensors | grep 'temp1:' | awk '{print $2}' | tr -d '+C' | |
} |
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
#include <Arduino.h> | |
#include <U8g2lib.h> | |
#include <Wire.h> | |
// screen lib setup | |
U8G2_SSD1306_128X32_UNIVISION_F_HW_I2C u8g2(U8G2_R0, /* reset=*/U8X8_PIN_NONE, /* clock=*/SCL, /* data=*/SDA); // pin remapping with ESP8266 HW I2C | |
#define boost_en 13 | |
#define L1F A4 | |
#define L2F A5 |
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
/* | |
Digalog | |
{"relay1":0,"relay2":1,"UUID":"tornado-airplane","pot1":[80,985],"pot2":[50,353],"pot3":[50]} | |
*/ | |
#include <ArduinoJson.h> | |
#include <FlashStorage_SAMD.h> | |
// UUID placeholder | |
String UUID = "tornado-airplane"; |
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
// Tyler's Lamp | |
#include <Adafruit_DotStar.h> | |
#include <SPI.h> | |
#define NUMPIXELS 62 // Number of LEDs in strip | |
// Here's how to control the LEDs from any two pins: | |
#define DATAPIN 6 | |
#define CLOCKPIN 2 |
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
// LAMP 198 | |
#include <Adafruit_DotStar.h> | |
#include <SPI.h> | |
#define NUMPIXELS 60 // Number of LEDs in strip | |
// Here's how to control the LEDs from any two pins: | |
#define DATAPIN 2 | |
#define CLOCKPIN 6 |
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
// Simple strand test for Adafruit Dot Star RGB LED strip. | |
// This is a basic diagnostic tool, NOT a graphics demo...helps confirm | |
// correct wiring and tests each pixel's ability to display red, green | |
// and blue and to forward data down the line. By limiting the number | |
// and color of LEDs, it's reasonably safe to power a couple meters off | |
// the Arduino's 5V pin. DON'T try that with other code! | |
#include <Adafruit_DotStar.h> | |
// Because conditional #includes don't work w/Arduino sketches... | |
#include <SPI.h> |
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
// Simple strand test for Adafruit Dot Star RGB LED strip. | |
// This is a basic diagnostic tool, NOT a graphics demo...helps confirm | |
// correct wiring and tests each pixel's ability to display red, green | |
// and blue and to forward data down the line. By limiting the number | |
// and color of LEDs, it's reasonably safe to power a couple meters off | |
// the Arduino's 5V pin. DON'T try that with other code! | |
#include <Adafruit_DotStar.h> | |
// Because conditional #includes don't work w/Arduino sketches... | |
#include <SPI.h> // COMMENT OUT THIS LINE FOR GEMMA OR TRINKET |
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
// Stage Curtain Control System | |
// | |
// A Hall Effect Sensor is used to count the rotations of the drive motor. Two relays are used to power the motor on in either direction. | |
// Input is provided by an Up, and Down button operating on 12v DC. | |
// Input may be added later using WiFi, or Schedules. | |
// | |
// Author: Jason Hejna ([email protected]) | |
// Author: Mukesh Ramani | |
//void count_motor_rotation(void); |
NewerOlder