好久没有更新blog了。
一个主要的原因是,我开始用evernote了。blog对于我的一大作用是,整理保存自己的实际操作和收获。用了evernote后,保存、搜索变得方便多了,整理也不那么急迫了。
其次,之前用vpn很不方便。
关键还是人懒。
现在情况有点变化。
evernote的记录逐渐多起来了。改用gae后fq方便且快速多了。
我是不是该继续写点什么了呢?
wyc online
珍惜快乐,感恩生活.
Thursday, May 9, 2013
Thursday, May 17, 2012
热靴闪光灯测试片
新进了佳能的热靴闪光灯430Ex2。看完说明书后还没有什么感觉,不好意思拿出去给人拍照。担心让人久等,脸部肌肉僵硬,浪费感情,耽误行程,错过班车......,罪过就大了。或者没有顾客,也是一件自讨没趣的事情。
只好在房间里苦练基本功,先交代一下室内光源都很昏暗,分别来自房间的3面:
1,电视机屏幕
3,床头的壁灯
灯光藏在木雕背后。一时拍不下来,可以想象一下把下面2张照片做个HDR的效果。

可以辨别出背带和裤子皱纹等暗部细节,同时整个画面的曝光也很自然。没有因为要提亮暗部的细节,导致其他地方过曝。
灯罩上的花纹清晰可见。
白色较准确。就是这样有点显旧。
只好在房间里苦练基本功,先交代一下室内光源都很昏暗,分别来自房间的3面:
1,电视机屏幕
2,走廊路灯
3,床头的壁灯
灯光藏在木雕背后。一时拍不下来,可以想象一下把下面2张照片做个HDR的效果。
在上述昏暗的光源下,经过闪光灯补光后得到下面这些照片,效果还比较满意:
1,对焦准确,图像清晰。
2,曝光准确,反映了昏暗的现场环境,也展现了丰富的细节。
因为是单项测试片,构图就放在一边不谈了。
- 镜面和灯罩
- 画框
我花了最长的时间才拍到这张照片。先前无论把闪光灯指向天花板、放下广角散光板、调低曝光指数,画框上的玻璃总是会有反光。最后我把闪光灯彻底指向远处毫不相干的窗帘,无意中才得到这个比较满意的效果,完全看不到玻璃的反射光。估计当时闪光灯是把整个房间都照亮了。
- 黑包和黑色外裤
可以辨别出背带和裤子皱纹等暗部细节,同时整个画面的曝光也很自然。没有因为要提亮暗部的细节,导致其他地方过曝。
- 远处同事的黑色背包
- 沙发
- 床头台灯
灯罩上的花纹清晰可见。
- 书桌上的水瓶
- 冰箱
白色较准确。就是这样有点显旧。
- 近处的空调开关
- 近处的床头柜
拍了一晚上,还是没有什么定量的可以重复使用的心得,完全要靠多次尝试。新增一个闪光灯环节,就增加了n多个调节的因素,这里还没有考虑离机的引闪。还是要靠多看多连,估计用多了会有一些感觉吧。
第2天,在强烈阳光下外拍,想做些逆光下补光的效果,结果没有1张的效果令人满意。于是我识趣的把闪光灯放回了包里。呵呵。
Thursday, April 19, 2012
find drivers/mtd 目录
在看Linux MTD 介绍_嵌入式Android_Linux开发。其中说到: Flash芯片驱动遵循CFI接口标准,其驱动程序位于drivers/mtd/chips子目录下。
有点犯懒,不想到android上去看,就用手头的deban来对照。deban的根目录下没有drivers目录。问了才知道,在/lib/modules/<kernel-version>/kernel/drivers下。
wang@route:/lib/modules/2.6.32-5-686/kernel/drivers/mtd/chips$ ls
cfi_cmdset_0001.ko cfi_probe.ko gen_probe.ko map_ram.ko cfi_cmdset_0002.ko cfi_util.ko jedec_probe.ko map_rom.ko cfi_cmdset_0020.ko chipreg.ko map_absent.ko
find -name drivers
一大堆输出。
2,要找的是目录
find -name drivers -type d
有很多异常输出find: `./proc/4322/fd': Permission denied find: `./proc/4322/fdinfo': Permission denied find: `./proc/4322/ns': Permission denied
3,去掉异常输出
find -name drivers -type d 2> /dev/null
一定不在usr/src目录下
./usr/src/linux-source-2.6.32/arch/sh/drivers
./usr/src/linux-source-2.6.32/arch/cris/arch-v32/drivers ./usr/src/linux-source-2.6.32/arch/cris/arch-v10/drivers
4,去掉usr目录
find -name "drivers" -type d 2> /dev/null | grep -v "/usr"
/sys/module/shpchp/drivers/sys/module/i2c_core/drivers /sys/module/parport_pc/drivers /sys/module/i2c_i801/drivers /sys/module/drm/drivers /sys/module/snd_intel8x0/drivers /lib/modules/3.2.0-0.bpo.2-686-pae/kernel/drivers /lib/modules/3.2.0-0.bpo.2-686-pae/kernel/drivers/staging/comedi/drivers /lib/modules/3.2.0-0.bpo.2-686-pae/kernel/sound/drivers /lib/modules/2.6.32-5-686/kernel/drivers /lib/modules/2.6.32-5-686/kernel/drivers/staging/comedi/drivers /lib/modules/2.6.32-5-686/kernel/sound/drivers 其实,我还是不知道drivers在哪里,至少范围大大缩小了
以后再说吧。
其实android的driver目录也不在根目录下的。
参考资料:linux 查找目录或文件
|
Thursday, April 5, 2012
试用Light Meter Tools
在weibo上看到@猛禽说起android手机上的测光软件。我试用了一下Light Meter Tools效果还可以。
测试相机:
canon 400D + ef 50 1.4。
测试过程:
1,测光软件下,设定光圈和曝光速度,计算出iso。
2,参考测光软件的参数,在相机的手动模式调节出相似的参数后,进行拍摄。
测试小结和后续:
1,评估照片曝光基本正确。测光软件具有一定的实用性。
2,下次到现场验证一下测光软件的实用性。貌似没有区域测光的功能。
3,还没有完全理解测光软件中的一些参数,明天请教大虾后再完善这篇文章。
4,这个软件的试用版本只有29天的有效期。
Friday, March 16, 2012
打开openwrt路由器的wan端口
打开openwrt路由器的wan端口以后,不需要接入路由器的内网就可以执行管理操作。
在 /etc/config/firewall 里加了两条规则而已:
在 /etc/config/firewall 里加了两条规则而已:
#Allow ssh on wan
config rule
option 'target' 'ACCEPT'
option 'src' 'wan'
option 'proto' 'tcp'
option 'dest_port' '22'
#Allow web UI on wan
config rule
option 'target' 'ACCEPT'
option 'src' 'wan'
option 'proto' 'tcp'
option 'dest_port' '80'
config rule
option 'target' 'ACCEPT'
option 'src' 'wan'
option 'proto' 'tcp'
option 'dest_port' '22'
#Allow web UI on wan
config rule
option 'target' 'ACCEPT'
option 'src' 'wan'
option 'proto' 'tcp'
option 'dest_port' '80'
这事情不是我做的,所以也备忘一下。
升级openwrt路由器
这是我的路由器的wiki,忘了从哪里转到这里来的,备忘一下。
Linksys WRT54G, WRT54GL and WRT54GS
Upgrading OpenWrt
Using mtd OR sysupgrade
If you have already installed OpenWrt and like to reflash for e.g. upgrading to a new OpenWrt version. It is important that you put the firmware image into the ramdisk (/tmp) before you start flashing.
cd /tmp/ wget http://downloads.openwrt.org/backfire/10.03.1/brcm47xx/openwrt-brcm47xx-squashfs.trx # The file must be the trx file. mtd write /tmp/openwrt-brcm47xx-squashfs.trx linux && reboot
OR
cd /tmp/ wget http://downloads.openwrt.org/backfire/10.03.1/brcm47xx/openwrt-brcm47xx-squashfs.trx # The file must be the trx file. sysupgrade /tmp/openwrt-brcm47xx-squashfs.trx
Feel free to explore the rest of sysupgrade options by typing 'sysupgrade' in the terminal.
Thursday, March 15, 2012
[ 更新 ] 定时重起OpenWrt路由器
有个路由器老是上不了网,每次要跑过去断电重起,很麻烦。
大侠已经刷把它刷成了OpenWrt Backfire 10.03。这就好办了。
先想用pc从lan登入上去,还不知道怎么设置?据说有安全问题。
看到路由器的admin页面上有schedule功能,就像让他定时重起。
现在设置好了,还不知道效果怎么样,明天再来看log。
我是第一次设置crontab,惭愧惭愧。这就整理一下:
1,配置工具
30 5 * * * root reboot # 这里不需要写用户
否则报错:Mar 16 05:30:01 opr cron.err crond[1080]: USER root pid 2230 cmd root reboot
4,开机运行
/etc/rc.d/S50cron # 在rc.d下创建symbol link指向启动
lrwxrwxrwx 1 root root 14 Mar 16 09:08 S50cron -> ../init.d/cron
root@opr:/etc/rc.d# ls
K50dropbear S05netconfig S59luci_dhcp_migrate
K90network S10boot S60dnsmasq
K95luci_fixtime S40network S95done
K98boot S45firewall S96led
K99umount S50cron S97watchdog
S02nvram S50dropbear S99sysctl
S05luci_fixtime S50uhttpd
5,真正的服务程序在这里
/usr/sbin/crond # 又是1个链接,指向busybox
lrwxrwxrwx 1 root root 17 Apr 6 2010 crond -> ../../bin/busybox
参考资料:Scheduling Jobs With cron on OpenWrt
大侠已经刷把它刷成了OpenWrt Backfire 10.03。这就好办了。
先想用pc从lan登入上去,还不知道怎么设置?据说有安全问题。
看到路由器的admin页面上有schedule功能,就像让他定时重起。
现在设置好了,还不知道效果怎么样,明天再来看log。
我是第一次设置crontab,惭愧惭愧。这就整理一下:
1,配置工具
/usr/bin/crontab # 是1个指向busybox的链接,又是busybox,真是好东西。
lrwxrwxrwx 1 root root 17 Apr 6 2010 crontab -> ../../bin/busybox
2,配置文件
/etc/crontabs/root
30 5 * * * /sbin/reboot # 每天5点30分重起。最好带上路径
30 5 * * * /sbin/reboot # 每天5点30分重起。最好带上路径
否则报错:Mar 16 05:30:01 opr cron.err crond[1080]: USER root pid 2230 cmd root reboot
3,启动脚本
/etc/init.d/cron
-rwxr-xr-x 1 root root 342 Apr 6 2010 cron
#!/bin/sh /etc/rc.common
# Copyright (C) 2006 OpenWrt.org
START=50
start () {
loglevel=$(/sbin/uci get "system.@system[0].cronloglevel" 2>/dev/null)
[ -z "$(ls /etc/crontabs/)" ] && exit 1
mkdir -p /var/spool/cron
ln -s /etc/crontabs /var/spool/cron/ 2>/dev/null
crond -c /etc/crontabs -l ${loglevel:-5}
}
stop() {
killall -9 crond
}
#!/bin/sh /etc/rc.common
# Copyright (C) 2006 OpenWrt.org
START=50
start () {
loglevel=$(/sbin/uci get "system.@system[0].cronloglevel" 2>/dev/null)
[ -z "$(ls /etc/crontabs/)" ] && exit 1
mkdir -p /var/spool/cron
ln -s /etc/crontabs /var/spool/cron/ 2>/dev/null
crond -c /etc/crontabs -l ${loglevel:-5}
}
stop() {
killall -9 crond
}
cron # 显示帮助
4,开机运行
/etc/rc.d/S50cron # 在rc.d下创建symbol link指向启动
lrwxrwxrwx 1 root root 14 Mar 16 09:08 S50cron -> ../init.d/cron
root@opr:/etc/rc.d# ls
K50dropbear S05netconfig S59luci_dhcp_migrate
K90network S10boot S60dnsmasq
K95luci_fixtime S40network S95done
K98boot S45firewall S96led
K99umount S50cron S97watchdog
S02nvram S50dropbear S99sysctl
S05luci_fixtime S50uhttpd
5,真正的服务程序在这里
/usr/sbin/crond # 又是1个链接,指向busybox
lrwxrwxrwx 1 root root 17 Apr 6 2010 crond -> ../../bin/busybox
Subscribe to:
Comments (Atom)


