Skip to content

Instantly share code, notes, and snippets.

View jck's full-sized avatar

Keerthan Jaic jck

  • London, UK
View GitHub Profile
@jck
jck / PKGBUILD
Last active December 16, 2015 21:59
gcc-msp430
# Contributor: Rick W. Chen <stuffcorpse at archlinux dot us>
pkgname=gcc-msp430
pkgver=4.6.3
pkgrel=4
pkgdesc="GNU toolchain for the TI MSP430 processor"
arch=('i686' 'x86_64')
url="http://sourceforge.net/projects/mspgcc/"
license=('GPL')
makedepends=('gcc46' 'binutils-msp430')
@jck
jck / PKGBUILD
Last active December 16, 2015 21:59 — forked from anonymous/PKGBUILD.txt
binutils-msp430
# Contributor: Rick W. Chen <stuffcorpse at archlinux dot us>
pkgname=binutils-msp430
pkgver=20120406
pkgrel=1
pkgdesc="A set of programs to assemble and manipulate binary and object files for the MSP430 architecture"
arch=('i686' 'x86_64')
url="http://sourceforge.net/projects/mspgcc/"
license=('GPL')
depends=('zlib')
@jck
jck / PKGBUILD
Created May 2, 2013 18:38
msp430-libc
# Contributor: Rick W. Chen <stuffcorpse at archlinux dot us>
pkgname=msp430-libc
pkgver=20120224
pkgrel=2
pkgdesc="C runtime library for the MSP430 family of microcontrollers"
arch=('i686' 'x86_64')
url="http://mspgcc4.sourceforge.net/"
license=('custom')
depends=('gcc-msp430')
@jck
jck / PKGBUILD
Created May 2, 2013 18:40
msp430mcu
# Contributor: Rick W. Chen <stuffcorpse at archlinux dot us>
pkgname=msp430mcu
pkgver=20120406
pkgrel=2
pkgdesc="C headers and binutils linker scripts for microcontrollers in the MSP430 family"
arch=(any)
url="http://mspgcc4.sourceforge.net/"
license=('GPL')
makedepends=('python2')
from myhdl import *
def ab(in1,out1):
one=[Signal(intbv(0)[2:]) for k in range(2)]
@always_comb
def comb1():
one[0].next[0]=in1 #conv_run requires: one[0][0].next=in1
@always_comb
@jck
jck / sim.py
Created July 13, 2015 19:01
Experiment to implement MyHDL style simulations using python 3.5 and asyncio
import asyncio
import heapq
class StopSim(BaseException):
"""Raised to stop the simulation"""
class SimEventLoop(asyncio.AbstractEventLoop):
def __init__(self):
self._time = 0
@jck
jck / jc.py
Created July 22, 2015 09:48
MyHDL nonlocal
from myhdl import *
ACTIVE = 0
DirType = enum('RIGHT', 'LEFT')
def jc2(goLeft, goRight, stop, clk, q):
""" A bi-directional 4-bit Johnson counter with stop control.
I/O pins:
from myhdl import block, delay, always_seq, instance, intbv, Signal, StopSimulation
@block
def inc(clk, rst, en, count):
@always_seq(clk.posedge, rst)
def logic():
if en:
count.next = count + 1
return logic
/sys/devices/system/cpu/cpu0/cpufreq/scaling_governor interactive
/sys/devices/system/cpu/cpu0/cpufreq/interactive/go_hispeed_load 99
/sys/devices/system/cpu/cpu0/cpufreq/interactive/above_hispeed_delay 0
/sys/devices/system/cpu/cpu0/cpufreq/interactive/timer_rate 60000
/sys/devices/system/cpu/cpu0/cpufreq/interactive/hispeed_freq 1248000
/sys/devices/system/cpu/cpu0/cpufreq/interactive/timer_slack 480000
/sys/devices/system/cpu/cpu0/cpufreq/interactive/target_loads 80 460800:68 600000:82 672000:72 787200:92 864000:83 960000:99 1248000:75 1440000:99
/sys/devices/system/cpu/cpu0/cpufreq/interactive/min_sample_time 0
/sys/devices/system/cpu/cpu0/cpufreq/interactive/boost 0
/sys/devices/system/cpu/cpu0/cpufreq/interactive/align_windows 1

Keybase proof

I hereby claim:

  • I am jck on github.
  • I am jck (https://keybase.io/jck) on keybase.
  • I have a public key whose fingerprint is 557D E03F 5E58 7F49 06D4 528F C3FE 95C6 3C5F 8232

To claim this, I am signing this object: