내가 원하는 레이아웃이 있는데

그걸 만들려고 지금까지 몇달 걸렸던가 ㄷㄷㄷ


얘는 쉬운데..

top;

menu; float

content; float

라면...

얘는 답이 안나온다.. -_-?!?!?


위와 같은 방법으로 하면

이런식으로 깨어지기만 하니까?


결론은.. div로 싸고 싸고 또 싸고 ㅋ

absolute를 하는 것도 방법이지만 고정 위치이고 여러가지 이유로 웬지 끌리지 않으니


menu ; float

container ; float

    top

    content

식으로 하면 깔끔하게 해결!



[링크 : http://yongja.tistory.com/48]

[링크 : http://mkyoon.com/56]

'Programming > javascript & HTML' 카테고리의 다른 글

반응형 웹... w3cshool 링크  (0) 2016.01.11
ul li 메뉴 .. 2?  (0) 2016.01.11
setTimeout()와 setInterval()  (0) 2016.01.07
html5 live video streaming...  (0) 2015.11.23
div span 블럭구조 및 원형테두리  (0) 2015.09.23
Posted by 구차니

"코스피 1,700선까지 갈수도" 최악 시나리오 나왔다

[링크 : http://media.daum.net/economic/finance/newsview?newsid=20160108081617062]



막상 확인해보니.. 1700이면 참..

최악 시나리오 치고 꿈이 소소하구나.. 싶네

Posted by 구차니

30~50만원 사용시 10% 할인이고

한번 할인 받으려면 5만원 이상 구매 해야 하는데

30~50만원 구간에서는 주간 만원(온라인) / 주말 만원(오프) 할인으로

역산해보면

10만원 결제 하면 만원 할인되고 주간이나 주말 하나 한번에 끝!


다시 생각해보면

주말에 10만원어치 한번

주중에 10만원어치 한번

이렇게 20쓰면 할인 금액을 다 쓰게 된다.

고로.. 최소 금액인 30을 채우기 위해서는 할인 받지 못하는 10만원을 또 써야 하고


체감(?) 할인율은

30에 2만원으로 6.67% 대 인가..




손해보고 장사할리는 없지만 먼가.. 커보이면서도 막상 계산해보니 크지 않은 기분이네...


2/30 = 0.067

3/50 = 0.06

4/70 = 0.057

5/90 = 0.056

엥? 왜 점점 쓰는게 커지면 할인율이 낮아져?


[링크 : http://www.lottemart.com/event/detail.do?categoryId=C0070872&SITELOC=JC004]

'개소리 왈왈 > 직딩의 비애' 카테고리의 다른 글

사진 인화 준비..  (0) 2016.02.11
소득공제 제공동의  (0) 2016.02.02
2015년 끝  (0) 2015.12.31
무료..  (0) 2015.12.26
... 멀 해야 하지?  (0) 2015.12.07
Posted by 구차니

서버에서 시간을 받아와서 웹 브라우저 상에서 

setTimeout()으로 구현된 예제를 보고 있노라니..

pc의 시간과 다르게 가서 고민..


생각해보니까

setTimeout은 1회성으로

내부 루틴에서 처리할거 처리하고 지정을 지정하면

조금씩 조금씩 시간이 밀려 날 걸로 예상이 된다.


그런 이유로 setInterval이 조금은 더 정확한 시간간격으로 수행이 가능하지 않을까? 라고 예상


[링크 : http://www.w3schools.com/js/js_timing.asp]



[링크 : http://honjoo.tistory.com/32]

[링크 : http://charlie0301.blogspot.com/2014/11/javascript-timer.html]


<body onload="setInterval(function(){ function1(); function2();}, 500);">

[링크 : http://stackoverflow.com/questions/6660755/can-a-body-tag-hold-multiply-onload-setinterval]



----

setInterval 버전

<body onload="setInterval(function(){realtimeClock();},1000);">


<script type="text/javascript">

var systime = 20;


function realtimeClock()

{

var cTime = new Date((systime++)*1000); // EN672 System Time

svrTime.innerHTML = getTimeStamp(cTime);

}


function getTimeStamp(d)

{

var s = leadingZeros(d.getFullYear(), 4) + '-' +

leadingZeros(d.getMonth() + 1, 2) + '-' +

leadingZeros(d.getDate(), 2) + ' ' +

leadingZeros(d.getHours(), 2) + ':' +

leadingZeros(d.getMinutes(), 2) + ':' +

leadingZeros(d.getSeconds(), 2);

return s;

}


function leadingZeros(n, digits)

{

var zero = '';

n = n.toString();

if (n.length < digits)

{

for (i = 0; i < digits - n.length; i++)

zero += '0';

}

return zero + n;

}

</script>


<div id="svrTime"></div>


</body> 


setTimeout 버전

<body onload="realtimeClock();">


<script type="text/javascript">

var systime = 20;


function realtimeClock()

{

var cTime = new Date((systime++)*1000); // EN672 System Time

svrTime.innerHTML = getTimeStamp(cTime);

setTimeout("realtimeClock()", 1000);

}


function getTimeStamp(d)

{

var s = leadingZeros(d.getFullYear(), 4) + '-' +

leadingZeros(d.getMonth() + 1, 2) + '-' +

leadingZeros(d.getDate(), 2) + ' ' +

leadingZeros(d.getHours(), 2) + ':' +

leadingZeros(d.getMinutes(), 2) + ':' +

leadingZeros(d.getSeconds(), 2);

return s;

}


function leadingZeros(n, digits)

{

var zero = '';

n = n.toString();

if (n.length < digits)

{

for (i = 0; i < digits - n.length; i++)

zero += '0';

}

return zero + n;

}

</script>


<div id="svrTime"></div>


</body> 


완전하진 않지만 대충.. refresh 해서

setInterval은 2초 늦고 setTimeout은 1초 정도 늦게 시작 했으나


setTimeout은 30분이 지난 시점에서 상당히 벗어나 있음

'Programming > javascript & HTML' 카테고리의 다른 글

ul li 메뉴 .. 2?  (0) 2016.01.11
div 쪼금 이해 될락말락...  (0) 2016.01.08
html5 live video streaming...  (0) 2015.11.23
div span 블럭구조 및 원형테두리  (0) 2015.09.23
ul / li로 메뉴 꾸미기  (0) 2015.09.16
Posted by 구차니
회사일/uclinux & rtos2016. 1. 6. 15:49


아직까지는 찾지를 못함..

직접 구현해야 하려나?


mjpeg 카메라 영상인데...

[링크 : http://141.89.114.98/demo/edu640x480v.html] mjpeg 예제


안드로이드(갤S2 LTE HD)는 그냥 다운로드..(재생불가)

IE 11 (edge)재생불가

IE 10 이하 재생불가


아이패드는 재생

크롬 재생

VLC 재생


It is natively supported by the QuickTime Player, the PlayStation console, and web browsers such as Safari, Google Chrome, and Mozilla Firefox.

[링크 : https://en.wikipedia.org/wiki/Motion_JPEG]


M-JPEG over HTTP

HTTP streaming separates each image into individual HTTP replies on a specified marker. RTP streaming creates packets of a sequence of JPEG images that can be received by clients such as QuickTime or VLC.


In response to a GET request for a MJPEG file or stream, the server streams the sequence of JPEG frames over HTTP. A special mime-type content type multipart/x-mixed-replace;boundary=<boundary-name> informs the client to expect several parts (frames) as an answer delimited by <boundary-name>. This boundary name is expressly disclosed within the MIME-type declaration itself. The TCP connection is not closed as long as the client wants to receive new frames and the server wants to provide new frames. Two basic implementations of a M-JPEG streaming server are cambozola and MJPG-Streamer. The more robust ffmpeg-server also provides M-JPEG streaming support.

[링크 : https://en.wikipedia.org/wiki/Motion_JPEG#M-JPEG_over_HTTP]


VLC로 raw 덤프해서 보니...

--myboundary

Content-type: image/jpeg

이렇게 시작하고 그 아래로는 깨지는걸 봐서는 그냥 jpeg 프레임인듯..



심심..(?)해서 저기 MIME 관련 헤더들 삭제하고 jpeg으로 저장하니

아래와 같이 똮!



저장을 좀 오래 하니

--myboundary

Content-type: image/jpeg

가 반복적으로 나타난다.


video/x-jpegMotion-JPEG video.   There are currently no specific properties defined or needed for this type. Note that video/x-jpeg only applies to Motion-JPEG pictures (YUY2 colourspace). RGB colourspace JPEG images are referred to as image/jpeg (JPEG image).

[링크 : http://gstreamer.freedesktop.org/.../section-types-definitions.html#table-video-types]

    [링크 : http://stackoverflow.com/.../correct-mime-type-for-multipart-mjpeg-stream-over-http]




HTTP/1.0 200 OK

Server: en.code-bude.net example server

Cache-Control: no-cache

Cache-Control: private

Content-Type: multipart/x-mixed-replace;boundary=--boundary

 

--boundary

Content-Type: image/jpeg

Content-Length: [length of the image bytes]

 

[write jpeg bytes]

 

--boundary

Content-Type: image/jpeg

Content-Length: [length of the image bytes]

 

[write jpeg bytes]

 

[...] 


[링크 : http://en.code-bude.net/tag/how-does-mjpeg-work/]



mjpeg streamer

[링크 : http://www.acmesystems.it/video_streaming]

'회사일 > uclinux & rtos' 카테고리의 다른 글

freeRTOS + lwip or freeRTOS+TCP  (0) 2016.01.06
비선점형 마이컴 OS - csrtos  (0) 2015.11.12
uclinux / linux 벤치마킹  (0) 2015.11.11
µC/OS-II  (0) 2015.11.11
uclinux  (0) 2015.11.10
Posted by 구차니
회사일/uclinux & rtos2016. 1. 6. 15:16

두개에 대한 벤치마크는 안보이지만...

어느걸 택하던 상관없다 일려나?(좋은 의미던 나쁜 의미던..)


lwIP


lwIP is also a good stack when used in its intended, memory constrained, environment. It has a higher throughput than uIP, but also has a larger ROM and RAM footprint. Although the footprint is larger than uIP it is still smaller than most commercial TCP/IP offerings. In particular, lwIP saves RAM by making large data buffers by chaining smaller buffers together.

Most (if not all) the FreeRTOS demos listed here make use of quite an old lwIP version. There are however contributed demos available in the FreeRTOS Interactive forums that use a more up to date lwIP code base. Further lwIP related uploads would be gratefully received.


On the negative side, lwIP is undeniably quite complex to use at first, but time invested in its use will pay dividends in future projects. lwIP is also a moving target because it is constantly being developed and updated (which is not necessarily a negative thing).


[링크 : http://www.freertos.org/embeddedtcp.html]

[링크 : http://lwip.wikia.com/wiki/LwIP_Application_Developers_Manual]

[링크 : http://lwip.wikia.com/wiki/LwIP_Wiki]

freeRTOS+TCP 패키지

[링크 : http://www.freertos.org/FreeRTOS-Plus/FreeRTOS_Plus_TCP/index.html]

'회사일 > uclinux & rtos' 카테고리의 다른 글

lwip RTSP over HTTP 가능성?  (0) 2016.01.06
비선점형 마이컴 OS - csrtos  (0) 2015.11.12
uclinux / linux 벤치마킹  (0) 2015.11.11
µC/OS-II  (0) 2015.11.11
uclinux  (0) 2015.11.10
Posted by 구차니
하드웨어/Storage2016. 1. 5. 13:29

음.. 5000번 포트 돌리고

외부에서 접속하게 하니 나쁘진 않은데..

자막이 안되네? ㅠㅠ


일단 동영상 / jpg 파일은 꽤 편리하게 보인다.

(안드로이드건-갤S2 LTE- 아이패드건 자막은 안된다)

zip은 메뉴가 떠서 아쉽지만...



[링크 : https://itunes.apple.com/us/app/ds-file/id416751772?mt=8]

[링크 : https://play.google.com/store/apps/details?id=com.synology.DSfile&hl=ko]

'하드웨어 > Storage' 카테고리의 다른 글

ipad용 ds file srt 자막 보기  (0) 2016.02.05
raid01 raid10  (0) 2016.01.31
synology undelete 시도 T.T  (0) 2015.12.27
synology port  (0) 2015.12.22
synology DS213j SVN server 설치  (0) 2015.10.19
Posted by 구차니
embeded/raspberry pi2016. 1. 5. 09:43

에뮬레이터 배포판(?)


[링크 : http://blog.petrockblock.com/retropie/]

[링크 : http://blog.petrockblock.com/retropie/retropie-downloads/]

'embeded > raspberry pi' 카테고리의 다른 글

지름신 강림! - 라즈베리 2b(본체만)  (0) 2016.03.10
라즈베리 3B?  (0) 2016.03.06
openELEC 6.0.0 릴리즈  (0) 2016.01.03
라즈베리 2b lirc + openELEC 설정  (0) 2015.12.12
라즈베리 파이 zero...???  (0) 2015.11.27
Posted by 구차니
Linux/Ubuntu2016. 1. 4. 17:55

network-manager가 기본이긴 하나..

wpa2가 안된다고하니 wicd를 써보라는 지인의 조언...


[링크 : https://help.ubuntu.com/community/WICD]

[링크 : http://wicd.sourceforge.net/]

-> [링크 : https://launchpad.net/wicd]



+

UI만 바뀌지 그게 그거인 기분..

어짜피 안 잡힐놈은 안 잡히는건 동일한건가..

'Linux > Ubuntu' 카테고리의 다른 글

LXDE 에서는... XDMCP 미지원?  (0) 2016.02.04
xdrp  (0) 2016.02.02
리눅스 콘솔 한글 출력?  (0) 2016.01.04
debian openbox 단축키  (0) 2016.01.04
lubuntu xtem scrollbar  (0) 2016.01.02
Posted by 구차니
Linux/Ubuntu2016. 1. 4. 17:30

될려나.. 나중에 해봐야지


LANG="ko_KR.eucKR"

SUPPORTED="en_US.UTF-8:en_US:en:ko_KR.eucKR:ko_KR:ko"

SYSFONT="lat0-sun16"

SYSFONTACM="8859-15"

[링크 : http://compeople.tistory.com/68]


/etc/sysconfig/i18n

LANG="en_US.UTF-8" 

SUPPORTED="en_US.UTF-8:en_US:en" 

SYSFONT="latarcyrheb-sun16"

[링크 : https://www.centos.org/docs/5/html/5.1/Deployment_Guide/s2-sysconfig-i18n.html]


LANG="ko_KR.UTF-8"

SYSFONT="latarcyrheb-sun16"

[링크 : http://iwithjoy.tistory.com/entry/CentOS-ssh-접속-한글깨짐-수정]



+

$ ls -al /usr/share/consolefonts


$ vi /etc/default/console-setup

# Valid font faces are: VGA (sizes 8, 14 and 16), Terminus (sizes

# 12x6, 14, 16, 20x10, 24x12, 28x14 and 32x16), TerminusBold (sizes

# 14, 16, 20x10, 24x12, 28x14 and 32x16), TerminusBoldVGA (sizes 14

# and 16) and Fixed (sizes 13, 14, 15, 16 and 18).  Only when

# CODESET=Ethiopian: Goha (sizes 12, 14 and 16) and

# GohaClassic (sizes 12, 14 and 16).

# Set FONTFACE and FONTSIZE to empty strings if you want setupcon to

# set up the keyboard but to leave the console font unchanged.

FONTFACE="Fixed"

FONTSIZE="16"


# You can also directly specify nonstandard font or console map to load.

# Use space as separator if you want to load more than one font.

# You can use FONT_MAP in order to specify the Unicode map of the font

# in case the font doesn't have it embedded.


# FONT='lat9w-08.psf.gz brl-8x8.psf'

# FONT_MAP=/usr/share/consoletrans/lat9u.uni

# CONSOLE_MAP=/usr/local/share/consoletrans/my_special_encoding.acm


# You can also specify a screen size that setupcon will enforce.  This can not

# exceed what the current screen resolution can display according to the size of

# the loaded font.

#

# SCREEN_WIDTH=80

# SCREEN_HEIGHT=25



$ consolechars
The program 'consolechars' is currently not installed.  To run 'consolechars' please ask your administrator to install the package 'console-tools'


[링크 : http://unix.stackexchange.com/questions/30855/how-to-list-console-and-kernel-fonts]


'Linux > Ubuntu' 카테고리의 다른 글

xdrp  (0) 2016.02.02
wicd / network-manager ?  (0) 2016.01.04
debian openbox 단축키  (0) 2016.01.04
lubuntu xtem scrollbar  (0) 2016.01.02
으악 lubuntu 였지 ㅋㅋㅋ  (0) 2015.12.30
Posted by 구차니