Skip to content

Instantly share code, notes, and snippets.

View patrickelectric's full-sized avatar
🏡
Working from home

Patrick José Pereira patrickelectric

🏡
Working from home
View GitHub Profile

Contributor Agreement

Entity Contributor Exclusive License Agreement

Thank you for your interest in contributing to Cockpit ("We" or "Us").

The purpose of this contributor agreement ("Agreement") is to clarify and document the rights granted by contributors to Us.

How to use this Contributor Agreement

@patrickelectric
patrickelectric / gist:1aaa4144a68a5af147a1dcaa30b5737c
Created November 1, 2023 18:06
steamdeck-for-developers.md
sudo systemctl enable sshd
sudo systemctl enable avahi-daemon
sudo nano /etc/avahi/avahi-daemon.conf
# make sure that: `publish-workstation=yes`

Contributor Agreement

Entity Contributor Exclusive License Agreement

Thank you for your interest in contributing to BlueOS ("We" or "Us").

The purpose of this contributor agreement ("Agreement") is to clarify and document the rights granted by contributors to Us.

How to use this Contributor Agreement

@patrickelectric
patrickelectric / bindings.h
Created August 7, 2023 15:13
Navigator 0.0.1 C++ bind documentation
#include <cstdarg>
#include <cstdint>
#include <cstdlib>
#include <ostream>
#include <new>
/**
* @brief Set of available options to select ADC's channel.
*/
enum class AdcChannel {
This file has been truncated, but you can view the full file.
[{"id":"28223063343","type":"PushEvent","actor":{"id":1215497,"login":"patrickelectric","display_login":"patrickelectric","gravatar_id":"","url":"https://api.github.com/users/patrickelectric","avatar_url":"https://avatars.githubusercontent.com/u/1215497?"},"repo":{"id":277877505,"name":"bluerobotics/BlueOS-docker","url":"https://api.github.com/repos/bluerobotics/BlueOS-docker"},"payload":{"repository_id":277877505,"push_id":13199180457,"size":1,"distinct_size":1,"ref":"refs/heads/master","head":"537aa6d9f840e5af7b3489d872ef03e691056d98","before":"e203fddc73bb8599a4019fc2104e0a1a5ccc30ae","commits":[{"sha":"537aa6d9f840e5af7b3489d872ef03e691056d98","author":{"email":"[email protected]","name":"Willian Galvani"},"message":"core: frontend: fix installed extensions not being manageable when offline","distinct":true,"url":"https://api.github.com/repos/bluerobotics/BlueOS-docker/commits/537aa6d9f840e5af7b3489d872ef03e691056d98"}]},"public":true,"created_at":"2023-04-05T13:47:24Z","org":{"id":7120633,"login":
@patrickelectric
patrickelectric / blueos.qml
Last active March 6, 2023 13:08
Minimal QML example to fetch video and mavlink data from BlueOS
import QtQuick 2.7
import QtQuick.Controls 2.3
import QtMultimedia 5.8
import QtWebSockets 1.15
Item {
id: parentLayout
width: 640
height: 400
@patrickelectric
patrickelectric / agenda-ney.py
Created February 26, 2023 16:41
Scrap event from ney matogrosso website
import requests
import json
from bs4 import BeautifulSoup
url = 'https://neymatogrosso.com.br/agenda/'
headers = {
"User-Agent": "Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Firefox/60.0"
}
@patrickelectric
patrickelectric / multiple-components.py
Last active November 16, 2024 23:11
Example of using asyncio to run multiple mavlink components
import asyncio
from pymavlink import mavutil
PORT = 6666
CONNECTION_STRING = f'udpout:127.0.0.1:{PORT}'
CONNECTIONS = {}
def get_mavlink_connection(system_id: int, component_id: int):
def create(system_id: int, component_id: int):
return mavutil.mavlink_connection(
@patrickelectric
patrickelectric / pub-sub-ros.md
Last active July 25, 2022 21:56
My personal investigation on the pub/sub frameworks around the world!

ROS

Long and love-rate (more rate than love) relationship, take mostly of this review with a grant of salt.

Great tools, libraries and projects

ROS (started in 2010) have some great tools visualize topics, send and debug messages, check frequencies, and much more. It's also possible to use more advanced tools and solutions like: rviz, gmapping, rtabmap, stereo_image_proc and the list goes on. With ROS, it's possible to take advantage of all drivers that exist for different pieces of hardware. Keep in mind that this is possible, but not easy, usually the drivers need specific configuration, custom settings and may give as output really complex data that needs to be processed or analyzed by another program.

Bureaucratic

ROS uses [catkin](https://github.com