Skip to content

Instantly share code, notes, and snippets.

View frett27's full-sized avatar

Patrice Freydiere frett27

View GitHub Profile

Le problème XY (XY Problem) peut survenir lorsqu'une personne demande de l'aide sur la résolution d'un problème à d'autres personnes.

C'est un blocage mental aboutissant généralement à de grosses pertes de temps et d'énergie que cela soit pour la personne demandant de l'aide que pour ceux qui en proposent.

Généralement le schéma est le suivant :

  • L'utilisateur veut faire X.
  • L'utilisateur ne sait pas comment faire X mais pense qu'il pourra obtenir une solution s'il commence par faire Y.
  • L'utilisateur ne sait aussi pas faire Y.
  • L'utilisateur demande de l'aide pour faire Y.
@frett27
frett27 / README.md
Created January 7, 2023 12:03 — forked from ralfstx/README.md
Cross-compiling for ARM with musl

Cross-compiling for ARM with musl

I'm using the target arm-linux-musleabihf for ARM v6 (Raspberry Zero is v6) with musl and hard float.

Build a cross compiler

Following instructions from Rust (and C) Cross Compilation for the Raspberry Pi.

Create an output directory:

@frett27
frett27 / winvm.md
Created August 15, 2021 09:09 — forked from rpavlik/winvm.md
Windows Dev VM in libvirt

One time

  • Build rhsrvany using a windows toolchain like i686-w64-mingw32, and put the resulting rhsrvany.exe and pnp_wait.exe in /usr/share/virt-tools
    • git clone https://github.com/rwmjones/rhsrvany.git
    • cd rhsrvany
    • autoreconf -i -f
    • ./configure --build=i686-w64-mingw32
    • make
  • sudo mkdir -p /usr/share/virt-tools
@frett27
frett27 / socket_task.c
Created October 20, 2020 19:58 — forked from Micrified/socket_task.c
A task that manages sockets
#include "socket_task.h"
/*
*******************************************************************************
* Symbolic Constants *
*******************************************************************************
*/
@frett27
frett27 / ARMonQEMUforDebianUbuntu.md
Created December 15, 2019 15:26 — forked from luk6xff/ARMonQEMUforDebianUbuntu.md
Emulating ARM with QEMU on Debian/Ubuntu

You might want to read this to get an introduction to armel vs armhf.

If the below is too much, you can try Ubuntu-ARMv7-Qemu but note it contains non-free blobs.

Running ARM programs under linux (without starting QEMU VM!)

First, cross-compile user programs with GCC-ARM toolchain. Then install qemu-arm-static so that you can run ARM executables directly on linux

If there's no qemu-arm-static in the package list, install qemu-user-static instead

@frett27
frett27 / vm.sh
Created March 6, 2019 12:14 — forked from afair/vm.sh
VM command to wrap virtualbox vboxmanage commands
#!/bin/bash
# install - http://www.unixmen.com/install-oracle-virtualbox-and-manage-it-using-phpvirtualbox-on-ubuntu-15-10-headless-server/
# remoting - http://www.virtualbox.org/manual/ch07.html
# vboxmanage - http://www.virtualbox.org/manual/ch08.html
if [ "$1" = "" ]; then
echo "Usage: vm command vmname args..."
exit
fi
@frett27
frett27 / docker-cleanup-resources.md
Created August 2, 2018 07:10 — forked from bastman/docker-cleanup-resources.md
docker cleanup guide: containers, images, volumes, networks

Docker - How to cleanup (unused) resources

Once in a while, you may need to cleanup resources (containers, volumes, images, networks) ...

delete volumes

// see: https://github.com/chadoe/docker-cleanup-volumes

$ docker volume rm $(docker volume ls -qf dangling=true)

$ docker volume ls -qf dangling=true | xargs -r docker volume rm

@frett27
frett27 / esp32_promisc.c
Created June 18, 2017 19:01 — forked from brainstorm/esp32_promisc.c
esp32 promiscuous mode and packet injection experiments
// Espressif ESP32 promiscuous mode and packet injection experiments
// by brainstorm at nopcode org
#include "freertos/FreeRTOS.h"
#include "esp_wifi.h"
#include "esp_wifi_internal.h"
#include "lwip/err.h"
#include "esp_system.h"
#include "esp_event.h"
#include "esp_event_loop.h"