embeded/raspberry pi2015. 8. 12. 14:58

gnome2의 이 안락함? ㅋㅋㅋ

캡쳐도 쉽고 좋아좋아 ㅋㅋ


그나저나.. 의외로 조금 먹어서 630MB 정도

300MB 정도 여유 메모리가 생기는데 나쁘진 않은 듯


다만.. 초기에 설치 및 설정에 오래 걸리는건 꽤나 단점..



라즈비안에서 해보니.. LXDE가 가볍긴 가볍구나 싶다. 300MB .. ㄷㄷㄷ

top - 15:07:12 up 3 min,  1 user,  load average: 0.93, 0.48, 0.19

Tasks: 111 total,   1 running, 110 sleeping,   0 stopped,   0 zombie

%Cpu(s):  2.2 us,  1.7 sy,  0.0 ni, 94.1 id,  2.1 wa,  0.0 hi,  0.0 si,  0.0 st

KiB Mem:    884380 total,   309792 used,   574588 free,    18640 buffers

KiB Swap:   102396 total,        0 used,   102396 free,   154808 cached


  PID USER      PR  NI  VIRT  RES  SHR S  %CPU %MEM    TIME+  COMMAND           

 2555 root      20   0 53280  28m  16m S   5.3  3.3   0:14.19 Xorg              

 2810 pi        20   0 98852  20m  17m S   2.6  2.4   0:02.61 lxterminal        

 2695 pi        20   0  128m  26m  22m S   2.3  3.0   0:03.67 lxpanel           

 2830 pi        20   0  391m 128m  67m S   2.0 14.9   1:15.68 epiphany-browse   

 2899 pi        20   0  4496 2416 2060 R   0.7  0.3   0:00.74 top               

    1 root      20   0  2148 1244 1140 S   0.3  0.1   0:00.86 init              

    6 root      20   0     0    0    0 D   0.3  0.0   0:00.63 kworker/u8:0      

 2197 nobody    20   0  2024 1468 1352 S   0.3  0.2   0:00.38 thd               

 2693 pi        20   0 21080  12m 9052 S   0.3  1.4   0:01.62 openbox           

 2703 root      20   0     0    0    0 S   0.3  0.0   0:00.44 kworker/u8:3      

 2909 pi        20   0 89712  18m  15m S   0.3  2.1   0:00.88 leafpad           

    2 root      20   0     0    0    0 S   0.0  0.0   0:00.00 kthreadd          

    3 root      20   0     0    0    0 S   0.0  0.0   0:00.13 ksoftirqd/0       

    4 root      20   0     0    0    0 S   0.0  0.0   0:00.00 kworker/0:0       

    5 root       0 -20     0    0    0 S   0.0  0.0   0:00.00 kworker/0:0H      

    7 root      20   0     0    0    0 S   0.0  0.0   0:00.36 rcu_preempt       

    8 root      20   0     0    0    0 S   0.0  0.0   0:00.00 rcu_sched          

 

Posted by 구차니
Linux/Ubuntu2015. 8. 12. 10:02

일단은 lubuntu(LXDE)가 xubuntu(XFCE)/ubuntu mate(GNOME2) 보다 300메가 정도 메모리를 덜 먹는다.

어짜피 둘다 ubuntu 기반이니 원하는대로 바꾸다 보면 그게 그거일지도 모르겠지만

윈도 매니저 자체는 꽤 차이가 난다.


lubuntu - 700MB


xubuntu - 1GB


mate - 1GB



음.. 순정 unity가 메모리는 가장 적게 먹으나 느려 터졌으니.. LXDE가 나으려나?

2014/06/14 - [Linux/Ubuntu] - Ubuntu 14.04 LTS desktop 64bit edition


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

우분투 시스템 온도 측정  (0) 2015.08.15
우분투 모니터 없이 부팅하기  (0) 2015.08.15
ubuntu mate  (0) 2015.07.28
Ubuntu 12.04 LTS G1610 CPU 지원 종료  (0) 2015.04.10
sudo: unable to resolve host  (0) 2015.03.26
Posted by 구차니
embeded/raspberry pi2015. 8. 11. 11:43

/etc는 squashfs로 인해 ro 상태인데..

kodi 설명을 보면 /etc에 하라고 한다 -_-

그런 이유로 openelec 문서를 찾아보니

/stroage/.config 에 lircd.conf를 복사해 두면 리부팅후 자동으로 키값을 불러온다고 한다.


irrecord /storage/.config/lircd.conf

[링크 : http://wiki.openelec.tv/index.php?title=Guide_To_lirc_rpi_GPIO_Receiver] 


OK는 메뉴 들어가기 + 파일 재생

FASTFORWARD는 빨리 감기(PLAY로 정상 속도)

MENU는 재생시 하단 메뉴(자막 등등 설정)

EXIT는 재생목록으로 설정하니 그럭저럭 쓸 수 있는데..

페이지 업/다운이 먼지 당췌 모르겠네 -_-


키는 정체 불명의 라디오 리모컨을 사용한 것 임.

$ cat lircd.conf


# Please make this file available to others

# by sending it to <lirc@bartelmus.de>

#

# this config file was automatically generated

# using lirc-0.9.1-git(default) on Tue Aug 11 02:51:10 2015

#

# contributed by

#

# brand:                       /storage/lircd.conf

# model no. of remote control:

# devices being controlled by this remote:

#


begin remote


  name  /storage/.config/lircd.conf

  bits           16

  flags SPACE_ENC|CONST_LENGTH

  eps            30

  aeps          100


  header       9085  4524

  one           646  1604

  zero          646   490

  ptrail        646

  pre_data_bits   16

  pre_data       0xFF

  gap          108567

  toggle_bit_mask 0x0


      begin codes

          KEY_UP                   0x7A85

          KEY_DOWN                 0x1AE5

          KEY_LEFT                 0x609F

          KEY_RIGHT                0x20DF

          KEY_OK                   0x9A65

          KEY_PLAY                 0xE01F

          KEY_FASTFORWARD          0x42BD

          KEY_STOP                 0x629D

          KEY_MENU                 0xC03F

          KEY_EXIT                 0x50AF

          KEY_VOLUMEUP             0xA25D

          KEY_VOLUMEDOWN           0x22DD

       end codes


end remote 


Posted by 구차니
개소리 왈왈/컴퓨터2015. 8. 10. 23:14

1테라 WD blue 지름


아내 컴퓨터 에 이거 달고..

아내꺼에 있는 느려 터진


500GB / 1T 삼성하드는

내꺼와 리눅스 서버에 이식해서 써야지 -_ㅠ


내일은 포맷한다고 하루 가겠구만..




'개소리 왈왈 > 컴퓨터' 카테고리의 다른 글

tc1100 분해방법  (0) 2015.11.05
하드 도착!  (0) 2015.11.02
다음 운세 종료 -_-?  (0) 2015.06.04
굿바이 다음 클라우드  (0) 2015.06.02
하드가 슬슬 맛이 가려는구나 ㅠㅠ  (0) 2015.05.28
Posted by 구차니
embeded/raspberry pi2015. 8. 10. 23:07

으흐흐 키워드를 바꾸니 조금 맞는게 나오는듯


결론은.. fb1으로 그냥 써! 인가 -_-?

$ sudo mv /usr/share/X11/xorg.conf.d/99-fbturbo.conf ~

$ sudo nano /usr/share/X11/xorg.conf.d/99-pitft.conf

Section "Device"

  Identifier "Adafruit PiTFT"

  Driver "fbdev"

  Option "fbdev" "/dev/fb1"

EndSection

$ sudo raspi-config

Then pick the Enable Boot to Desktop/Scratch option and choose if you want to boot to the console, desktop, or scratch environment.  


오래 눌러 오른쪽 클릭 지원하는 옵션도 발견!

/etc/X11/xorg.conf.d/99-calibration.conf

Option "EmulateThirdButton" "1"

Option "EmulateThirdButtonTimeout" "750"

Option "EmulateThirdButtonMoveThreshold" "30"

So for example your file will look like:

Section "InputClass"

   Identifier      "calibration"

   MatchProduct    "stmpe-ts"

   Option  "Calibration"   "3800 120 200 3900"

   Option  "SwapAxes"      "1"

   Option "EmulateThirdButton" "1"

   Option "EmulateThirdButtonTimeout" "750"

   Option "EmulateThirdButtonMoveThreshold" "30"

EndSection 


동일 제품인지 모르겠으나.. 아무튼 클럭도 줄수있긴 한데

SPI 클럭 디바이더의 설정으로 인해 아래의 클럭만 설정이 가능하다고 한다.

dtoverlay=pitft28r,rotate=90,speed=62000000,fps=25

Or whatever you like for speed, rotation, and frames-per-second. BUT, here's the thing, the Pi only supports a fixed number of SPI frequencies. So tweaking the number a little won't do anything. The kernel will round the number to the closest value. You will always get frequencies that are 250MHz divided by an even number. Here's the only SPI frequencies this kernel supports

15,625,000 (a.k.a 16000000 = 16 MHz)

17,857,142 (a.k.a. 18000000 = 18 MHz)

20,833,333 (a.k.a 21000000 = 21 MHz)

25,000,000 (= 25 MHz)

31,250,000 (a.k.a 32000000 = 32MHz)

41,666,666 (a.k.a 42000000 = 42MHz)

62,500,000 (a.k.a 62000000 = 62MHz) 


waveshare에서도 적용해보니

창 옮길때는 모르겠으나..

아주 미미하게 메뉴가 나타나는 속도 정도는 조금 빠른 느낌?


[링크 : https://learn.adafruit.com/.../extras#boot-to-x-windows-on-pitft]

[링크 : https://learn.adafruit.com/adafruit-pitft-28-inch-resistive-touchscreen-display-raspberry-pi/faq]

    [링크 : http://raspberrypi.stackexchange.com/questions/14893/force-output-to-different-display-pitft]


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

ubuntu mate on rpi2  (0) 2015.08.12
openelec lirc.conf 설정  (11) 2015.08.11
라즈베리 파이 HDMI/composite 끄는법?  (0) 2015.08.10
라즈베리 파이 timezone 변경  (0) 2015.08.09
MMAL - Multi-Media Abstraction Layer  (0) 2015.08.09
Posted by 구차니
embeded/raspberry pi2015. 8. 10. 23:00

정녕.. 부팅레벨에서 끄는법은 없는건가? ㅠㅠ

config.txt나 cmdline.txt쪽을 봐야 할듯.. ㅠㅠ

일단 목적은.. spi fbtft 쪽을 fb0로 할당하기!


[링크 : http://elinux.org/RPiconfig]

[링크 : https://www.raspberrypi.org/documentation/configuration/config-txt.md]


use videocore GPU command  to switch off or on HDMI service thus saving valuable watts :)


Switch on

“/opt/vc/bin/tvservice -p”


Switch off

“/opt/vc/bin/tvservice -o” 


[링크 : https://glframebuffer.wordpress.com/2013/08/28/raspberrypi-how-to-turn-off-hdmi-from-raspberry-pi/]

    [링크 : https://www.raspberrypi.org/forums/viewtopic.php?f=66&t=55354]

Posted by 구차니
Linux API/linux2015. 8. 9. 23:57

리눅스에서는 librt.so를 이용해서 쓰는 녀석으로

조만간 사라질 gettimeofday를 대체하는 함수이다.


[링크 :  http://sunyzero.tistory.com/161]

[링크 :  http://linux.die.net/man/3/clock_gettime]

'Linux API > linux' 카테고리의 다른 글

select()  (0) 2015.10.26
mmap / ioremap  (0) 2015.10.21
리눅스 모듈 - 세마포어 / 뮤텍스  (0) 2015.10.21
linux kernel module module_init() 매크로  (0) 2015.10.21
리눅스 타이머 예제 setitimer() / sigaction()  (0) 2015.10.13
Posted by 구차니
embeded/raspberry pi2015. 8. 9. 12:13

라즈베리 파이 기본 시간설정은 Etc/UTC인데

이걸 바꾸러면 raspbi-config를 통해 바꾸거나 수작업으로 바꿔도 될 듯

이걸 안바꾸고 rdate를 통해 시간대를 변경하려고 하면

UTC를 기준으로 변경되어 버린다. -_-a


$ cat /etc/timezone

Etc/UTC


$ sudo raspbi-config


$ cat /etc/timezone

Asia/Seoul


[링크 : https://www.raspberrypi.org/forums/viewtopic.php?t=4977&f=5]

Posted by 구차니
embeded/raspberry pi2015. 8. 9. 10:54

MMAL은 VideoCore 용 멀티미디어 컴포넌트 인터페이스 이다.

MMAL (Multi-Media Abstraction Layer) is a framework which is used to provide a host-side, simple and relatively low-level interface to multimedia components running on VideoCore. It also provides a component interface so that new components can be easily created and integrated into the framework.


There is no requirement that all the components be running on VideoCore as MMAL doesn't put any restriction on where components live. The current implementation for instance provides some components which can be run on both host-side or VideoCore (e.g. the splitter component).


[링크 : http://www.jvcref.com/files/PI/documentation/html/] 


문제(?)는 이녀석은 범용은 아니란거

VideoCore란거 자체가.. Broadcom 꺼다 보니.. 결론은 Broadcom용 제품을 효율적으로 쓰려면 이녀석을 써야 한다?

VideoCore is a low-power mobile multimedia processor architecture originally developed by Alphamosaic Ltd and now owned by Broadcom. Its two-dimensional DSP architecture makes it flexible and efficient enough to decode as well as encode a number of multimedia codecs in software, while maintaining low power usage. The semiconductor intellectual property core (SIP core) has been found so far only on Broadcom SoCs.


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


아무튼.. mmal을 바로 쓰는 motion 프로젝트도 존재

[링크 : http://www.rasplay.org/?p=4910]


다운로드 경로가 dropbox라고 되어 있는데 경로가 안보이길래 검색..

[링크 : https://www.dropbox.com/s/0gzxtkxhvwgfocs/motion-mmal.tar.gz]

    [링크 : http://embeddedday.com/projects/raspberry-pi/a-step-further/install-motion-mmal/]

Posted by 구차니
embeded/raspberry pi2015. 8. 9. 10:08

하드웨어 가속을 받아서 그런가 CPU점유율이 실질적으로 0!!

ㄷㄷㄷ

pi@raspberrypi ~ $ raspivid -t 0 -v


raspivid Camera App v1.3.12


Width 1920, Height 1080, filename (null)

bitrate 17000000, framerate 30, time delay 0

H264 Profile high

H264 Quantisation level 0, Inline headers No

H264 Intra refresh type (null), period -1

Wait method : Capture forever

Initial state 'record'



Preview Yes, Full screen Yes

Preview window 0,0,1024,768

Opacity 255

Sharpness 0, Contrast 0, Brightness 50

Saturation 0, ISO 0, Video Stabilisation No, Exposure compensation 0

Exposure Mode 'auto', AWB Mode 'auto', Image Effect 'none'

Metering Mode 'average', Colour Effect Enabled No with U = 128, V = 128

Rotation 0, hflip No, vflip No

ROI x 0.000000, y 0.000000, w 1.000000 h 1.000000

Camera component done

Encoder component done

Starting component connection stage

Connecting camera preview port to preview input port

Starting video preview

Connecting camera stills port to encoder input port

Enabling encoder output port


raspivid 프로세스가 왕창 떠있는데 cpu는 하나도 안먹네.. ㄷㄷㄷ

화면을 흔들던 말던 cpu 점유율은 0에서 움직이질 않는다.

raw를 받아서 fb에 덮어 버리는건가? ㄷㄷㄷ



Posted by 구차니