Skip to content

Instantly share code, notes, and snippets.

Avatar
🤖
Making robots! 🇦🇷

Emiliano Borghi eborghi10

🤖
Making robots! 🇦🇷
View GitHub Profile
@eborghi10
eborghi10 / howto-recover-google-authenticator-keys.txt
Created Oct 4, 2021 — forked from jbinto/howto-recover-google-authenticator-keys.txt
Recovering Google Authenticator keys from Android device for backup
View howto-recover-google-authenticator-keys.txt
### Last tested February 7 2014 on a Galaxy S3 (d2att) running Cyanogenmod 11 nightly, with Google Authenticator 2.49.
### Device with Google Authenticator must have root.
### Computer requires Android Developer Tools and SQLite 3.
### Connect your device in USB debugging mode.
$ cd /tmp
$ adb root
$ adb pull /data/data/com.google.android.apps.authenticator2/databases/databases
@eborghi10
eborghi10 / points.cpp
Created Sep 9, 2021 — forked from cseas/points.cpp
Simple C++ OpenGL program to draw points on a 2D canvas
View points.cpp
#include<GL/glut.h>
void display() {
glClear(GL_COLOR_BUFFER_BIT);
glColor3f(1.0, 0.0, 0.0);
glBegin(GL_POINTS);
glVertex2f(10.0, 10.0);
glVertex2f(150.0, 80.0);
glVertex2f(100.0, 20.0);
@eborghi10
eborghi10 / turbovnc_virtualgl.md
Last active Jun 14, 2021
[Nvidia Jetson Nano] TurboVNC + VirtualGL
View turbovnc_virtualgl.md
  • Download and install compiled binaries
wget http://demotomohiro.github.io/hardware/jetson_tk1/pkg/libjpeg-turbo_1.4.0_armhf.deb
wget http://demotomohiro.github.io/hardware/jetson_tk1/pkg/virtualgl_2.4_armhf.deb
wget http://demotomohiro.github.io/hardware/jetson_tk1/pkg/turbovnc_1.2.3_armhf.deb
sudo dpkg -i libjpeg-turbo_1.4.0_armhf.deb
sudo dpkg -i virtualgl_2.4_armhf.deb
sudo dpkg -i turbovnc_1.2.3_armhf.deb
sudo vi /etc/X11/xorg.conf
@eborghi10
eborghi10 / caught_exception.py
Created Apr 9, 2021
ROSInterruptException example
View caught_exception.py
#!/usr/bin/env python
import rospy
name = "caught_exception"
rospy.init_node(name)
r = rospy.Rate(1.)
start = rospy.Time.now()
while not rospy.is_shutdown():
rospy.logwarn(name)
@eborghi10
eborghi10 / .tmux.conf
Created Mar 1, 2021
Tmux configuration file
View .tmux.conf
# 0 is too far from ` ;)
set -g base-index 1
# Automatically set window title
set-window-option -g automatic-rename on
set-option -g set-titles on
set -g history-limit 10000
# split panes using | and -
@eborghi10
eborghi10 / .bashrc
Created Nov 20, 2020
Nice Git prompt
View .bashrc
# Nice git prompt
PS1='\[\033[0;32m\]\[\033[0m\033[0;32m\]\u\[\033[0;36m\] @ \[\033[0;36m\]\h \w\[\033[0;32m\]$(__git_ps1)\n\[\033[0;32m\]└─\[\033[0m\033[0;32m\] \$\[\033[0m\033[0;32m\] ▶\[\033[0m\] '
@eborghi10
eborghi10 / move_square.py
Created Jun 10, 2020 — forked from gurbain/move_square.py
This script allows to move and draw a square on the ground with the turtlebot in three different ways
View move_square.py
import math
import rospy as ros
import sys
import time
from geometry_msgs.msg import Twist, Pose
from nav_msgs.msg import Odometry
from tf.transformations import euler_from_quaternion, quaternion_from_euler
View kinematics.launch
<launch>
<!-- Spawn Gazebo -->
<include file="$(find ca_gazebo)/launch/create_empty_world.launch"/>
<!-- Change real-time factor of Gazebo to 2x-->
<node pkg="ca_gazebo" type="set_properties" name="gazebo_physics_properties" output="screen">
<param name="real_time_factor" value="2"/>
</node>
<!-- Run the node to move the robot -->
<node pkg="ca_tools" type="kinematics.py" name="kinematics" output="screen"/>
</launch>
@eborghi10
eborghi10 / tf_example.py
Created Apr 12, 2020
Tf example with numpy
View tf_example.py
#!/usr/bin/env python
import numpy as np
# Define the position of the frame B w.r.t. A
a_T_b = np.array([[2, -1, 1]]).transpose()
# Define the orientation of the frame B w.r.t. A
theta = np.radians(-90)
c, s = np.cos(theta), np.sin(theta)
a_R_b = np.array(((c, -s), (s, c), (0, 0)))
# Homogeneous matrix between A and B
@eborghi10
eborghi10 / ejecutable.launch
Last active May 2, 2020
Nodo de ejemplo para la clase de Robótica del año 2020 (Introducción a ROS)
View ejecutable.launch
<launch>
<node name="mi_nodo_utn" pkg="mi_nuevo_paquete" type="mi_nodo.py" />
<include file="$(find ca_gazebo)/launch/create_empty_world.launch"/>
</launch>