This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <util/delay.h> | |
#include <avr/io.h> | |
#include <avr/interrupt.h> | |
#include <stdlib.h> | |
#include <math.h> | |
#define CS_BANK0 0 | |
#define CS_BANK1 1 | |
#define WR 2 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- ioping.c.orig 2011-06-07 11:23:20.533184637 +0400 | |
+++ ioping.c 2011-06-07 12:02:50.652665892 +0400 | |
@@ -457,11 +457,12 @@ | |
if (this_time > part_max) | |
part_max = this_time; | |
- if (!quiet) | |
- printf("%lld bytes from %s (%s %s): request=%d time=%.1f ms\n", | |
- (long long)ret_size, path, fstype, device, | |
+ if (!quiet) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <stdio.h> | |
#include <unistd.h> | |
#include <stdlib.h> | |
#include <string.h> | |
#include <sysexits.h> | |
#include <sys/time.h> | |
int main(int argc, const char *argv[]) | |
{ | |
if (argc > 2) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <util/delay.h> | |
#include <avr/pgmspace.h> | |
#include <avr/io.h> | |
#include <avr/interrupt.h> | |
#include <stdlib.h> | |
#include "lcd.h" | |
void |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <avr/io.h> | |
#include <avr/pgmspace.h> | |
#include <util/delay.h> | |
#include "lcd.h" | |
#define BUSY_FLAG 0b10000000 | |
void wait(); | |
char read(void) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
static uint32_t | |
_mh(put_slot_x)(struct _mh(t) *h, mh_key_t key) | |
{ | |
uint32_t inc, k, i, p = h->n_buckets, j = 0; | |
k = mh_hash(key); | |
i = k % h->n_buckets; | |
inc = 1 + k % (h->n_buckets - 1); | |
for (;;) { | |
if (mh_exist(h, i)) { | |
if (mh_eq(h->p[i].key, key)) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
static uint32_t | |
_mh(put_slot)(struct _mh(t) *h, mh_key_t key) | |
{ | |
uint32_t inc, k, i, p = h->n_buckets; | |
k = mh_hash(key); | |
i = k % h->n_buckets; | |
inc = 1 + k % (h->n_buckets - 1); | |
for (;;) { | |
if (mh_exist(h, i)) { | |
if (mh_eq(h->p[i].key, key)) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import Graphics.UI.Gtk | |
import Graphics.Rendering.Cairo | |
render = do | |
moveTo 0 0 | |
sequence_ $ replicate 50000 (relLineTo 0.01 0.01) | |
stroke | |
main :: IO () | |
main = do |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Wed May 15 20:18:11 MSK 2013 Yuriy Vostrikov <mon@unformed.ru> | |
* Hide window by moving it offscreen. | |
diff -rN -u old-xmonad/XMonad/Main.hsc new-xmonad/XMonad/Main.hsc | |
--- old-xmonad/XMonad/Main.hsc 2013-05-15 20:19:44.856112375 +0400 | |
+++ new-xmonad/XMonad/Main.hsc 2013-05-15 20:19:44.860112375 +0400 | |
@@ -274,6 +274,7 @@ | |
-- configure a window | |
handle e@(ConfigureRequestEvent {ev_window = w}) = withDisplay $ \dpy -> do | |
ws <- gets windowset | |
+ wm <- gets mapped |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
enableBackingStore dpy win = do | |
unmapWindow dpy win | |
sync dpy False | |
allocaSetWindowAttributes $ \attributes -> do | |
set_backing_store attributes always | |
changeWindowAttributes dpy win cWBackingStore attributes | |
mapWindow dpy win | |
sync dpy False | |
enableBackingStoreHook = |
OlderNewer