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
$ gcc -DUSE_MMAP=0 tmp/rss.c && ./a.out | |
rss 360448 | |
============== | |
rss 360448 | |
rss 1429504 | |
rss 552960 | |
============== | |
rss 552960 | |
rss 1359872 | |
rss 1359872 |
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
#!/usr/bin/env expect | |
# Description: | |
# This tool aims to achieve the "auto-start script" upon device reboot or power lost, | |
# since there's no ready auto-start hook at post-init stage for UVC | |
# Installation: | |
# Install "expect", "netcat" and "sshpass" first if your Linux distribution don't have it ready | |
# $ sudo apt-get install expect sshpass netcat |
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
#!/usr/bin/env expect | |
# Description: | |
# This tool aims to achieve the "auto-start script" upon device reboot or power lost, | |
# since there's no ready auto-start hook at post-init stage for UVC | |
# Installation: | |
# Install "expect", "netcat" and "sshpass" first if your Linux distribution don't have it ready | |
# $ sudo apt-get install expect sshpass netcat |
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
<head> | |
<!-- | |
Enable RTMP feature by | |
Step 1. ssh into camera | |
Step 2. paste below command into terminal | |
echo createService ip=0.0.0.0 port=1935 protocol=inboundRtmp | nc 127.0.0.1 1112 -w 1 -i 1 | |
Then replace it with corresponding IP address of your UVC | |
<source src="rtmp://192.168.1.20:1935/live/s0" type='rtmp/mp4'> | |
--> |
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
HTTPPort 8888 | |
HTTPBindAddress 0.0.0.0 | |
MaxHTTPConnections 2000 | |
MaxClients 1000 | |
MaxBandwidth 1000000 | |
CustomLog - | |
<Feed feed1.ffm> | |
File /tmp/feed1.ffm | |
FileMaxSize 20M |
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
if (self.CavalryLogger) { | |
CavalryLogger.start_js(["xTY7O"]); | |
} | |
__d('FileHasher', ['WebWorker', 'fileSliceName', 'emptyFunction', 'FileHashWorkerResource'], function a(b, c, d, e, f, g) { | |
if (c.__markCompiled) c.__markCompiled(); | |
h.isSupported = function() { | |
'use strict'; | |
return c('WebWorker').isSupported(); | |
}; |
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
/* | |
* $ gcc countbit.c -o countbit.out | |
* $ ./countbit.out | |
* =============================================================== | |
* <PROFILING> Start : [ProfilingStart] (1414405319.256769) | |
* <PROFILING> End : [ProfilingEnd] (1414405339.508215) g_uiDiff = 20251,446 | |
* =============================================================== | |
* =============================================================== | |
* <PROFILING> Start : [ProfilingStart] (1414405339.508239) | |
* <PROFILING> End : [ProfilingEnd] (1414405355.221734) g_uiDiff = 15713,495 |
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 <stdlib.h> | |
#include <sys/time.h> | |
struct timeval g_tvStart, g_tvEnd; | |
unsigned int g_uiDiff; | |
void ProfilingStart() | |
{ | |
g_uiDiff = 0; |
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
#!/bin/bash | |
# Modify below 2 variables if needed | |
ALBUM_NUM=50 | |
ALBUM_FOLDER="./SambaGhost-data/album/" | |
cd ${ALBUM_FOLDER} | |
for (( i = 1; i <= ${ALBUM_NUM}; i++ )); do | |
echo "==> Create folder ${i}" |
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
<script type='text/javascript'> | |
//<![CDATA[ | |
var times= 0; | |
function commentPhotoDo() { | |
var tag; | |
for(var i = 0; i < commentPhotoIds.length; i++){ | |
tag = document.createElement('script'); | |
tag.type = 'text/javascript'; | |
tag.src = 'http://chenkaie.110mb.com/avatar.php?maxheight=60&url='+encodeURIComponent(commentPhotoIds[i].url)+'&id='+encodeURIComponent(commentPhotoIds[i].id)+'&defaultimage='+encodeURIComponent('http://bloggerhacks.googlecode.com/files/No_Photo.PNG'); | |
//tag.src = 'http://bloggerhacks.googlecode.com/files/No_Photo.PNG)'; |
NewerOlder