Skip to content

Instantly share code, notes, and snippets.


Dennis E. Mungai Brainiarc7

View GitHub Profile
Brainiarc7 /
Created Dec 6, 2019 — forked from ArseniyShestakov/
My compiler alternatives
# Cleanup old alternatives
update-alternatives --remove-all cc
update-alternatives --remove-all c++
update-alternatives --remove-all gcc
update-alternatives --remove-all g++
update-alternatives --remove-all clang
update-alternatives --remove-all clang++
update-alternatives --remove-all icc
update-alternatives --remove-all icc++
Brainiarc7 /
Last active Jan 19, 2020
These gists document installing and configuring Ubuntu 18.04LTS on the EVOC P775TM1-R

Installing Linux on the EVOC P775TM1-R:

For starters,

If you are dual booting, install Windows first, and partition from there with a tool such as Minitool. You'll only need two partitions, one for root and optionally, a small one for swap (say, 8GB). Partition them as appropriate, and when done, reboot into the UEFI menu and ensure that:

(a). Secure boot is disabled (otherwise you won't be able to load up proprietary drivers needed for the Nvidia GPU).

(b). Confirm that you're booting in UEFI mode ONLY. This is the default. CSM should remain disabled. Here's why.

Brainiarc7 / h264_nvenc
Created Jul 22, 2019 — forked from nico-lab/h264_nvenc.txt
ffmpeg -h encoder=h264_nvenc
View h264_nvenc
Encoder h264_nvenc [NVIDIA NVENC H.264 encoder]:
General capabilities: delay hardware
Threading capabilities: none
Supported pixel formats: yuv420p nv12 p010le yuv444p p016le yuv444p16le bgr0 rgb0 cuda d3d11
h264_nvenc AVOptions:
-preset <int> E..V..... Set the encoding preset (from 0 to 11) (default medium)
default E..V.....
slow E..V..... hq 2 passes
medium E..V..... hq 1 pass
fast E..V..... hp 1 pass
View amdgpu_compute_mode_linux.php
#!/usr/bin/env php
declare(strict_types = 1);
if (posix_geteuid () !== 0) {
die ( "error: this script requires root privileges, re-run it as root." );
$amdgpu_dir = '/sys/bus/pci/drivers/amdgpu';
$dirs = array_filter ( array_map ( 'trim', glob ( $amdgpu_dir.DIRECTORY_SEPARATOR.'*', GLOB_NOSORT | GLOB_ONLYDIR | GLOB_MARK ) ), function (string $str) {
return (is_writable ( $str."power_dpm_force_performance_level" ) && is_writable ( $str.'pp_compute_power_profile' ));
} );
Brainiarc7 / boot.bif
Created Jun 27, 2019 — forked from KeitetsuWorks/boot.bif
BIF File for Zynq UltraScale+ MPSoC
View boot.bif
[fsbl_config] a53_x64
[bootloader] <fsbl.elf>
[pmufw_image] <pmufw.elf>
[destination_device=pl] <bitstream>
[destination_cpu=a53-0, exception_level=el-3, trustzone] <bl31.elf>
[destination_cpu=a53-0, exception_level=el-2] <u-boot.elf>
  1. Installing NVIDIA Drivers
ubuntu-drivers devices
sudo ubuntu-drivers autoinstall
  1. From last command see nvidia-driver-number and use it in the command below and then reboot 📺 ✔️
Brainiarc7 /
Created Jun 9, 2019 — forked from tmehlinger/
gstreamer RTP to RTMP
# tested on Ubuntu 16.04
apt-get install -y \
gstreamer1.0-libav \
gstreamer1.0-plugins-bad \
gstreamer1.0-plugins-base \
gstreamer1.0-plugins-good \
Brainiarc7 /
Created Apr 22, 2019 — forked from salaros/
My tweaks for Ubuntu + Dell Inspiron 5567
#!/usr/bin/env bash
# Require root to run
if [ "$EUID" -ne 0 ]; then
echo "Please run as root"
exit 0
# [PlayOnLinux] - disables protection against the usage of Ptrace
Brainiarc7 /
Created Dec 14, 2018 — forked from savvot/
Extract only keyframes (I-frames) from video to images with console ffmpeg
ffmpeg -ss <start_time> -i video.mp4 -t <duration> -q:v 2 -vf select="eq(pict_type\,PICT_TYPE_I)" -vsync 0 frame%03d.jpg
Brainiarc7 / powercfg-win10-more-settings.cmd
Created Nov 12, 2018 — forked from Nt-gm79sp/powercfg-win10-more-settings.cmd
Show/hide hidden settings in Win10 Power Options
View powercfg-win10-more-settings.cmd
@echo on
REM checked for Windows 10
REM fork from
REM you may want full list
REM Hard disk burst ignore time
powercfg -attributes 0012ee47-9041-4b5d-9b77-535fba8b1442 80e3c60e-bb94-4ad8-bbe0-0d3195efc663 %attrib%