이론 관련/전기 전자2024. 8. 28. 16:25

CPOL은 CLK에 연관된것으로 클럭이 없을때 high면 1, low면 0

CPHA는 데이터를 읽을때 CLK의 edge를 보는 것으로 rising edge에서 읽으면 1, falling edge에서 읽으면 0

[링크 : https://blog.naver.com/specialist0/220645228159]

 

cpol과 cpha가 2가지 씩 이니 총 4가지 방식이 존재하고, 그걸 설정해서 통신하면 된다.

Most microcontroller SPI peripherals can operate with the ADS1118. The interface operates in SPI mode 1
where CPOL = 0 and CPHA = 1. In SPI mode 1, SCLK idles low and data are launched or changed only on
SCLK rising edges; data are latched or read by the master and slave on SCLK falling edges. Details of the SPI
communication protocol employed by the ADS1118 can be found in the Timing Requirements: Serial Interface
section.

[링크 : https://www.ti.com/lit/ds/symlink/ads1118.pdf]

 

'이론 관련 > 전기 전자' 카테고리의 다른 글

edge detector  (0) 2024.11.15
택 스위치(TACTILE SWITCH)  (0) 2024.09.03
NPN TR.... 2?  (0) 2024.08.20
BJT - bipolar junction transistor  (0) 2024.08.13
clock is gated  (0) 2024.07.19
Posted by 구차니

관절하나 계산법

[링크 : https://blog.naver.com/junghs1040/222347693715]

 

kinetics 인줄 알았는데 kinematics 군..

[링크 : https://kr.mathworks.com/discovery/inverse-kinematics.html]

 

kinematics - 힘은 고려하지 않고 움직임의 형태만 고려

[링크 : https://m.blog.naver.com/droneaje/222146288663]

Posted by 구차니

선풍기 타이머 하고 잤는데

꺼지니 더워서 깨고

그래서 다시 켜놓고 잤더니

추워서 깨고

아오.. 그렇다고 낮잠을 잘 수 있는 체질이 아니게 되어버리니 미쳐 버리겠네

'개소리 왈왈 > 육아관련 주저리' 카테고리의 다른 글

개털밈 2  (0) 2024.09.01
개털밈  (0) 2024.08.31
영풍문고 다녀옴  (0) 2024.08.24
개피곤 개더워  (0) 2024.08.22
개피곤 개더움  (0) 2024.08.19
Posted by 구차니
embeded/raspberry pi2024. 8. 27. 16:13

결국은 systemd에 등록인데..

python 프로그램의 경우 pip -g로 인스톨 해서 전역으로 하지 않으면

대부분(?) 에러가 나던데.. 그건 언급이 없네

 

cd /lib/systemd/system/
sudo nano hello.service
The service definition must be on the /lib/systemd/system folder. Our service is going to be called "hello.service":

[Unit]
Description=Hello World
After=multi-user.target

[Service]
Type=simple
ExecStart=/usr/bin/python /home/pi/hello_world.py
Restart=on-abort

[Install]
WantedBy=multi-user.target

Here we are creating a very simple service that runs our hello_world script and if by any means is aborted is going to be restarted automatically. You can check more on service's options in the next wiki: https://wiki.archlinux.org/index.php/systemd.

Now that we have our service we need to activate it:

sudo chmod 644 /lib/systemd/system/hello.service
chmod +x /home/pi/hello_world.py
sudo systemctl daemon-reload
sudo systemctl enable hello.service
sudo systemctl start hello.service

[링크 : https://gist.github.com/emxsys/a507f3cad928e66f6410e7ac28e2990f]

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

라즈베리 파이 gui 재시작(lxde)  (0) 2024.09.19
라즈베리 파이 gui 자동실행  (0) 2024.09.19
pgadmin4 를 rpi에 설치하기 성공  (0) 2024.07.29
pgadmin3 안되잖아?!  (0) 2024.07.26
rpi pico ADC 범위  (0) 2024.07.16
Posted by 구차니
프로그램 사용/rtl-sdr2024. 8. 26. 14:44

gqrx를 설치해서 원격으로 음악이나 들으려고 했더니

연결 거부되었다고 에러가 나서 검색.

 

$ gqrx 
"Pulseaudio error: 연결 거부됨"
$ pax11publish -r

$ gqrx 
gr-osmosdr 0.2.0.0 (0.2.0) gnuradio 3.10.1.1

[링크 : https://unix.stackexchange.com/questions/193208/program-run-in-ssh-accessing-pulseaudio-on-the-machine-where-it-runs]

 

-r 곱션을 찾아보니 remove의 r인 것 같은데.

$ pax11publish -help
pax11publish [-D display] [-S server] [-O sink] [-I source] [-c file]  [-d|-e|-i|-r]

 -d    X11 디스플레이에 연결된 최신 PulseAudio 데이터 표시 (기본값)
 -e    X11 디스플레이에 로컬 PulseAudio 데이터를 내보내기
 -i    X11 디스플레이에서 로컬 환경 변수 및 쿠키 파일에 PulseAudio 데이터 가져오기.
 -r    X11 디스플레이에서 PulseAudio 데이터 삭제

 

이걸 한다고 해서 SSH client 쪽으로 소리가 나는 것도 아니고.. 애매하네

$ man pax11publish
pax11publish(1)             General Commands Manual            pax11publish(1)

NAME
       pax11publish - PulseAudio X11 Credential Utility

SYNOPSIS
       pax11publish -h
       pax11publish [options] [-d]
       pax11publish [options] -e
       pax11publish [options] -i
       pax11publish [options] -r

DESCRIPTION
       The pax11publish utility can be used to dump or manipulate the PulseAu‐
       dio server credentials that can be stored as properties on the X11 root
       window.

       Please  note  that  the  loadable module module-x11-publish exports the
       same information directly from the PulseAudio sound server, and  should
       in most cases be used in preference over this tool.

       Use the following command to dump the raw PulseAudio-specific data that
       is stored in your X11 root window:

       xprop -root | grep ^PULSE_

OPTIONS
       -h     Show help.

       -d     Read the PulseAudio server credentials currently set on the  X11
              root  window  and dump them in a human readable form. This reads
              the  PULSE_SERVER,  PULSE_SINK,  PULSE_SOURCE  and  PULSE_COOKIE
              properties.

       -i     Similar  to  -d, however dumps them in a Bourne shell compatible
              format so they may be used together with the eval shell  command
              to set the $PULSE_SERVER, $PULSE_SINK, $PULSE_SOURCE environment
              variables. Also reads the authentication cookie  from  the  root
              window and stores it in ~/.config/pulse/cookie.

       -e     Export  the  currently  locally  used sound server, sink, source
              configuration to the X11 root window. This takes the  data  from
              the  $PULSE_SERVER, $PULSE_SINK, $PULSE_SOURCE environment vari‐
              ables  and  combines   them   with   the   data   from   ~/.con‐
              fig/pulse/client.conf  (or  /etc/pulse/client.conf  if that file
              does not exist). If specific options are passed on  the  command
              line (-S, -O, -I, -c, see below), they take precedence. Also up‐
              loads the local authentication cookie ~/.config/pulse/cookie  to
              the X11 server.

       -r     Removes  the  configured  PulseAudio  configuration from the X11
              root window.

       -D DISPLAY
              Connect to the specified X11 display, instead of the default one
              configured in $DISPLAY.

       -S SERVER
              Only valid for -e: export the specified PulseAudio server as de‐
              fault to the X11 display instead of the one configured via local
              configuration.

       -O SINK
              Only  valid for -e: export the specified sink as default sink to
              the X11 display instead of the one configured via local configu‐
              ration.

       -I SOURCE
              Only valid for -e: export the specified source as default to the
              X11 display instead of the one configured via  local  configura‐
              tion.

       -c FILE
              Only  valid  for -e: export the PulseAudio authentication cookie
              stored in the specified file to the X11 display instead  of  the
              one stored in ~/.config/pulse/cookie.

AUTHORS
       The   PulseAudio   Developers   <pulseaudio-discuss  (at)  lists  (dot)
       freedesktop (dot) org>; PulseAudio is  available  from  http://pulseau‐
       dio.org/

SEE ALSO
       pulseaudio(1), xprop(1)

Manuals                              User                      pax11publish(1)

 

Posted by 구차니
개소리 왈왈/컴퓨터2024. 8. 25. 23:37

2세대 부품을 왕창 써서

아내 친구네 컴퓨터 2대 수리해주고 보냄

덕분에 맛있는 족발 냠냠!

 

견적 봐주면서 컴퓨존 보니 80이면 사는데

난 왜 80의 여유돈이 없는걸까.. ㅠㅠ

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

컴퓨터 옆(?)그레이드  (2) 2024.10.09
계륵이들 처리  (0) 2024.09.22
모니터 분해  (4) 2024.08.10
모니터 사형선고  (0) 2024.08.08
모니터 고장!  (2) 2024.08.06
Posted by 구차니

애들 대리고 다녀옴

싸우고 싸우고 싸우고 싸우는 걸로 끝 -_-

 

그래도 이런 곳도 있다는건 알려주고 싶었는데

지하철로 그정도 거리를 다녀올 만큼 장족의 발전이라고 해야하려나?

'개소리 왈왈 > 육아관련 주저리' 카테고리의 다른 글

개털밈  (0) 2024.08.31
잠 좀 자자 ㅠㅠ  (0) 2024.08.27
개피곤 개더워  (0) 2024.08.22
개피곤 개더움  (0) 2024.08.19
tv 파괴 2차  (0) 2024.08.18
Posted by 구차니
프로그램 사용/Blender2024. 8. 23. 17:44

다운로드 받은걸 가져와서 회전하려니까

이상한 곳에서 회전되는데 도무지 삭제가 되지 않는 커서도 아닌 무언가가 있어서 찾아보니

origin 인듯.

 

아무튼 오리진을 도형(?)의 중심으로 옮기는건 우클릭 - Set Origin - Origin to Geometry 해주면 된다.

Type
Geometry to Origin
    Moves the model to the origin and this way the origin of the object will also be at the center of the object.
Origin to Geometry
    Moves the origin to the center of the object.
Origin to 3D Cursor
    Moves the origin of the model to the position of the 3D cursor.
Origin to Center of Mass
    Moves the origin to the calculated center of mass of model (assuming the mesh has a uniform density).
Center
    Median Point Center, Bounding Box Center

[링크 : https://docs.blender.org/manual/en/latest/scene_layout/object/origin.html]

 

커서는 마음대로 옮길수 있으니 커서로 오리진을 이동시키는 듯.

[링크 : https://snow8village.tistory.com/56]

'프로그램 사용 > Blender' 카테고리의 다른 글

blender render - cycle, eevee  (0) 2024.08.30
blender shader editor (4.2 bloom)  (0) 2024.08.29
blender 4.x 구동 실패  (0) 2024.08.20
blender snap(붙이기)  (0) 2024.08.16
블렌더 축이동 제한하기  (0) 2024.08.14
Posted by 구차니
분류가 모호한 글2024. 8. 23. 10:23

'분류가 모호한 글' 카테고리의 다른 글

buildroot rootfs overlay  (0) 2023.06.16
FMCW, MMIC  (0) 2022.03.22
베르세르크 작가 미우라 켄타로 사망  (2) 2021.05.22
good bye 척 예거  (2) 2020.12.09
FMCW  (0) 2018.07.19
Posted by 구차니

개 산책 나갔다가 비와서 돌아오고

하루종일 먼가 피곤한데다가

처서 매직도 크지 않아서 그나마 30도 까진 안가는걸 위안 삼아야 하나?

'개소리 왈왈 > 육아관련 주저리' 카테고리의 다른 글

잠 좀 자자 ㅠㅠ  (0) 2024.08.27
영풍문고 다녀옴  (0) 2024.08.24
개피곤 개더움  (0) 2024.08.19
tv 파괴 2차  (0) 2024.08.18
다이소 구리스  (0) 2024.08.17
Posted by 구차니