Skip to content

Instantly share code, notes, and snippets.

Avatar

yboujraf yboujraf

View GitHub Profile
@yboujraf
yboujraf / udp.js
Created Dec 20, 2019 — forked from sid24rane/udp.js
Simple UDP Client and Server in Node.js ==> ( Echo Server )
View udp.js
var udp = require('dgram');
// --------------------creating a udp server --------------------
// creating a udp server
var server = udp.createSocket('udp4');
// emits when any error occurs
server.on('error',function(error){
console.log('Error: ' + error);
@jperkin
jperkin / rpi-cpuinfo-dt.md
Last active Sep 11, 2020
raspberry pi cpuinfo vs device-tree
View rpi-cpuinfo-dt.md

Raspberry Pi cpuinfo vs device-tree

My attempt at gathering information on how to detect exactly which Raspberry Pi model we are running on for https://github.com/jperkin/node-rpio. The goal is to come up with an optimal way of detecting the host across a wide range of hardware and OS.

Data

Name (Rev) cpuinfo /proc/device-tree/model device-tree/soc/ranges OS
B (1.0) 0002 Raspberry Pi Model B 7e000000 20000000 01000000 7
B (1.0) 0002 Raspberry Pi Model B Rev 1 7e000000 20000000 02000000 10
@arthurattwell
arthurattwell / pandoc-docx-md.bat
Last active Aug 20, 2020
Script to convert docx to markdown with Pandoc
View pandoc-docx-md.bat
:: pandoc-docx-md.bat
::
:: Don't show these commands to the user
@ECHO off
:: Set the title of the window
TITLE Convert docx to markdown with Pandoc
:: Select file marker
:selectfile
:: Clear any preexisting filename variables
SET filename=
View capture_raw_frames.c
/*
* V4L2 video capture example
*
* This program can be used and distributed without restrictions.
*
* This program is provided with the V4L2 API
* see http://linuxtv.org/docs.php for more information
*/
#include <stdio.h>
You can’t perform that action at this time.