Skip to content

Instantly share code, notes, and snippets.

View Jxck-S's full-sized avatar
🏠
Working from home

Jack Sweeney Jxck-S

🏠
Working from home
  • Student
  • Orlando Florida
View GitHub Profile
@Jxck-S
Jxck-S / coordinate_tools.py
Created February 14, 2024 20:37
Python Coordinate Tools.
def standardize_longitude(longitude):
while longitude < -180:
longitude += 360
while longitude > 180:
longitude -= 360
return longitude
def standardize_latitude(latitude):
while latitude < -90:
@Jxck-S
Jxck-S / tmobile_phone_num_gen.py
Created January 23, 2024 14:16
Generate TMobile Phone Numbers and Verify for, reasons you may need to know a TMobile number...
import requests
import json
import random
def generate_random_number_string(length):
numbers = '0123456789'
return ''.join(random.choice(numbers) for _ in range(length))
phone_number = "13529993108"
print("--------------------------------------")
@Jxck-S
Jxck-S / the9central_vlan_scan.json
Created November 9, 2023 02:57
The 9 at Central in Orlando FL, VLAN scan.
{
"detected_networks": [
{
"vlan_id": "default",
"ip_address": "100.110.152.81",
"domain": "w-194.orld.fl.wtsky.net"
},
{
"vlan_id": 6,
"rx_bytes": 23426,
@Jxck-S
Jxck-S / AAInflight.py
Created March 8, 2022 04:02
AAInflight Mini Status Program
import requests
import time
from geopy.distance import geodesic
last_coords = None
speed = None
time_btwn_change = 1
check_freq = 10
#https://server.ad.logic-prod.viasat.io/afr.php?zoneid=95&parameters=%7B%22origin%22:%22KMCO%22,%22destination%22:%22KDFW%22%7D&fid=N132AN-KMCO-KDFW-2022-03-05T01:56:12Z&fleetType=&isUSDomestic=true&guid=6f3003e9-9c27-11ec-927e-06df78a0305b&subtag=&source=https:%2F%2Fwww.aainflight.com%2F&origin=https:%2F%2Fwww.aainflight.com&li=0
#https://www.aainflight.com/iptv/channelList
#https://www.aainflight.com/iptv/programGuide/grid?channelId=12%2C13%2C14%2C15%2C16%2C17%2C19%2C24%2C26%2C27%2C34%2C35&startDateTime=20220305T0300Z&endDateTime=20220305T0700Z
@Jxck-S
Jxck-S / nostr_relays.csv
Last active July 12, 2023 05:08
A list of popular/free nostr relays that my plane-notify program can use for posting.
URL FAILS
wss://nostr.mutinywallet.com 0
wss://relay.snort.social 0
wss://nostr.wine 0
wss://nos.lol 0
wss://relay.damus.io 0
@Jxck-S
Jxck-S / aircraft_type_fuel_consumption_rate.json
Last active July 5, 2023 09:08
Fuel consumption rates by ICAO type of aircraft
{
"EA50": {
"name": "Eclipse 550",
"galph": 76,
"category": "VLJ"
},
"LJ31": {
"name": "Learjet 31",
"galph": 202,
"category": "Light"
@Jxck-S
Jxck-S / VirginAtlanticIFELogger.py
Created July 3, 2023 19:50
Logs flight data from the IFE API's on a Virgin Atlantic Flight
import requests, json, time
from datetime import datetime
l_flight = {'info': {}, 'updates': []}
log_keys = ['groundSpeedKnots',
'headWindSpeedKnots',
'mach',
'pitch',
'roll',
'airSpeedKnots',
'altitudeFeet',
@Jxck-S
Jxck-S / VIR136.json
Created July 3, 2023 19:48
Logging of inflight data from Virgin Atlantic Flight on Board from the IFE API. VIR136 on G-VLIB
{
"info": {
"departBaggageId": "MCO",
"departureId": "KMCO",
"departureLat": 28.429443359375,
"departureLon": -81.3088912963867,
"destBaggageId": "LHR",
"destinationId": "EGLL",
"destinationLat": 51.4667015075684,
"destinationLon": -0.449999988079071,
@Jxck-S
Jxck-S / nostr_post.py
Last active May 15, 2023 15:25
Post to nostr from Python, with helpful info on how to post a photo
import json
import ssl
import time
from nostr.event import Event
from nostr.relay_manager import RelayManager
from nostr.message_type import ClientMessageType
from nostr.key import PrivateKey
def nostr_post(note, private_key, image_url=None):
if image_url:
@Jxck-S
Jxck-S / s3_upload.py
Created May 9, 2023 01:18
Upload a file/image to AWS S3 bucket, meant for use with nostr for image hosting.
import boto3
def upload(file_name, bucket, aws_access_key, aws_access_key_sec):
s3 = boto3.client('s3', aws_access_key_id=aws_access_key, aws_secret_access_key=aws_access_key_sec)
s3.upload_file(file_name, bucket, file_name)
url = f"https://{bucket}.s3.amazonaws.com/{file_name}"
return url