Skip to content

Instantly share code, notes, and snippets.

View ektor5's full-sized avatar

Ettore Chimenti ektor5

View GitHub Profile
@ektor5
ektor5 / stepper_udoo.sh
Last active January 20, 2016 15:21
Little script that make a RGB led glow on UDOO with ReadASCIIString example
#!/bin/bash
# Little script that make a RGB led glow
# on UDOO with ReadASCIIString example
#
# Ek5 @ 2016
DEV=ttymxc3
STEP=17 # could be 1,3,5,15,17,51,255
OS1=51 # offset 1
/*
Reading a serial ASCII-encoded string.
This sketch demonstrates the Serial parseInt() function.
It looks for an ASCII string of comma-separated values.
It parses them into ints, and uses those to fade an RGB LED.
created 13 Apr 2012
by Tom Igoe
#!/bin/bash
# Little script that make a RGB led glow
# on UDOO with ReadASCIIString example
#
# Ek5 @ 2016
DEV=${3:-ttyMCC}
STEP=${2:-15} # could be 1,3,5,15,17,51,255
OS1=0 # offset 1
#!/bin/bash
threads=8
dtb=( imx6{q,dl}-udoo{-{15,7}lvds,}.dtb )
export KCFLAGS="-O2 -march=armv7-a -mtune=cortex-a9 -mfpu=vfpv3-d16 -pipe -fomit-frame-pointer"
export ARCH=arm
export CROSS_COMPILE=/usr/bin/arm-linux-gnueabihf-
export KBUILD_DEBARCH=armhf
export KBUILD_IMAGE=zImage
alias print_iec="numfmt --to=iec"
total() {
xargs du -b | cut -f 1 |
( while read dim; do let S+=$dim ; done ; echo $S )
}
declare -A D
#!/bin/sh
set -e
# quick example script to get acc/mag values from Pololu cmp01b
# enable accelerometer
i2cset -f -y 3 0x19 0x20 23
# enable magnetometer
i2cset -f -y 3 0x1e 0x02 0
// Sketch based on http://www.hobbytronics.co.uk/arduino-external-eeprom
// Full check on every EEPROM cell
// Tried on UDOO Neo
//
// Ek5
#include <Wire.h>
#define disk1 0x50 //Address of 24LC256 eeprom chip
int dim = 32768; //Capacity in bytes
@ektor5
ektor5 / accmag_serial.ino
Created May 2, 2016 16:30
UDOO Neo Sketch with less Serial.print()
#include <Wire.h>
#include <FXOS8700CQ.h>
FXOS8700CQ sensor = FXOS8700CQ(0x1E);
void setup() {
Serial.begin(9600);
Wire1.begin();
// Initialize the FXOS8700CQ
#!/bin/bash
#
# UDOO X86: Curie Master Reset Script
# Copyright UDOO Team 2017
#
# Author: Ettore Chimenti
# Author: Luca Pisani
#
# Ver 0.1
#!/bin/bash
#
# UDOO X86: Curie Master Reset Script
# Copyright UDOO Team 2017
#
# Author: Ettore Chimenti
# Author: Luca Pisani
#
# Ver 0.1