Skip to content

Instantly share code, notes, and snippets.

View woosal1337's full-sized avatar
🦇
1337

Vusal Ismayilov woosal1337

🦇
1337
View GitHub Profile
@woosal1337
woosal1337 / resolv.conf block modification
Created September 22, 2021 14:23
resolv.conf block modification on every time the network or the device is restarted
block the automatic modifications to file resolv.conf file:
sudo chattr -f +i /etc/resolv.conf
undo:
sudo chattr -f -i /etc/resolv.conf
@woosal1337
woosal1337 / lspci -v
Created August 30, 2021 00:07
lspci -v output
00:00.0 Host bridge: Intel Corporation 8th Gen Core Processor Host Bridge/DRAM Registers (rev 07)
DeviceName: Intel Dual Band Wireless-AC 9560 802.11 AC 2x2 WiFi + BT 5 Combo Adapter
Subsystem: Hewlett-Packard Company Device 846a
Flags: bus master, fast devsel, latency 0
Capabilities: <access denied>
Kernel driver in use: skl_uncore
00:01.0 PCI bridge: Intel Corporation 6th-10th Gen Core Processor PCIe Controller (x16) (rev 07) (prog-if 00 [Normal decode])
Flags: bus master, fast devsel, latency 0, IRQ 121
Bus: primary=00, secondary=01, subordinate=01, sec-latency=0
@woosal1337
woosal1337 / bundle-installation
Created August 21, 2021 21:37
mavros, opencv, cuda/cudnn, mavsdk bundle installation guide, all-in-one.
1) [CUDA/cuDNN installation](https://gist.github.com/woosal1337/54a113dcd46bdba241c119928003351f) (optional for faster processing and higher fps rate on opencv a.k.a video transmission and image processing)
2) [OpenCV installation](https://gist.github.com/woosal1337/eef9cd11a29d50a09851502b22a3e064) (build for faster processing and higher fps rate on opencv a.k.a video transmission and image processing)
3) [PX4 installation]()
4) MAVSDK (c++ & python optional)
5) ROS (Noetic for Ubuntu 20.04LTS p.s the same goes for the Ubuntu 18.04, however the Noetic switches to the Melodic)
6) first `catkin` project
7) run the projects with custom scripts
### guide
@woosal1337
woosal1337 / ros-noetic-installation
Created August 21, 2021 21:36
ros noetic installation guide for ubuntu 20.04lts
```
sudo sh -c 'echo "deb http://packages.ros.org/ros/ubuntu $(lsb_release -sc) main" > /etc/apt/sources.list.d/ros-latest.list'
```
```
curl -s https://raw.githubusercontent.com/ros/rosdistro/master/ros.asc | sudo apt-key add -
```
```
sudo apt update
```
git clone https://github.com/PX4/PX4-Autopilot.git --recursive
```
```
bash ./PX4-Autopilot/Tools/setup/ubuntu.sh
```
make sure to reboot the device before launching px4
@woosal1337
woosal1337 / opencv-installation
Created August 20, 2021 09:33
🙏 Full OpenCV Installation Guide
general prerequisites:
```
$ sudo apt install build-essential cmake pkg-config unzip yasm git checkinstall
$ sudo apt install libjpeg-dev libpng-dev libtiff-dev
$ sudo apt install libavcodec-dev libavformat-dev libswscale-dev libavresample-dev
$ sudo apt install libgstreamer1.0-dev libgstreamer-plugins-base1.0-dev
$ sudo apt install libxvidcore-dev x264 libx264-dev libfaac-dev libmp3lame-dev libtheora-dev
$ sudo apt install libfaac-dev libmp3lame-dev libvorbis-dev
$ sudo apt install libopencore-amrnb-dev libopencore-amrwb-dev
@woosal1337
woosal1337 / mavros-launch
Created August 19, 2021 08:59
Custom MAVROS Scripts&Gazebo Launch Codes.
`cd PX4-Autopilot/`
`roslaunch px4 mavros_posix_sitl.launch`
# Run to define the environmental variables:
```
source Tools/setup_gazebo.bash /home/woosal/PX4-Autopilot /home/woosal/PX4-Autopilot/build/px4_sitl_default
export ROS_PACKAGE_PATH=$ROS_PACKAGE_PATH:/home/woosal/PX4-Autopilot
export ROS_PACKAGE_PATH=$ROS_PACKAGE_PATH:/home/woosal/PX4-Autopilot/Tools/sitl_gazebo
```
@woosal1337
woosal1337 / books
Created August 18, 2021 21:23
📚 books regarding programming that i read, or have read go here
Robert C. Martin - Clean Code (2008)
@woosal1337
woosal1337 / init.vim
Created August 6, 2021 12:58
My NeoVim Configuration File
" plugins
let need_to_install_plugins = 0
if empty(glob('~/.vim/autoload/plug.vim'))
silent !curl -fLo ~/.vim/autoload/plug.vim --create-dirs
\ https://raw.githubusercontent.com/junegunn/vim-plug/master/plug.vim
let need_to_install_plugins = 1
endif
call plug#begin()
Plug 'tpope/vim-sensible'
@woosal1337
woosal1337 / Replace-bash-with-tmux
Created August 6, 2021 11:36
Replacing the default `bash` terminal `tmux`
[[ $TERM != "screen" ]] && exec tmux