embeded/raspberry pi2016. 10. 31. 16:38

예전에 eMMC 어댑터를 이용해서 rpi에 연결했을때

깜박이지도 않았는데

SD.CARD.DET 핀 자체가 탐지되지 않으면 SD가 없는걸로 간주하고 배째는게 아닐까 싶은데

(그러니까 핀인식이 안되면 SD 읽을 시도조차 하지 않음?)

나중에 머라도 덧대서 한번 다시 시도는 해봐야 할 듯?



[링크 : https://www.raspberrypi.org/.../Raspberry-Pi-Rev-2.0-Model-AB-Schematics.pdf]

[링크 : http://electronics.stackexchange.com/.../how-can-i-hardware-protect-a-microsd-from-writing-to]


Check the ACT LED to determine if the Pi is booting

The ACT LED is essential in determining if the Pi can actually read from the card. It indicates that it can read from the card by blinking, If the ACT LED doesn't blink quickly in an irregular pattern for at least twenty seconds, this indicates that the Pi cannot read from the SD card, and that booting is not taking place. By the way, It doesn't matter if the ACT LED initially starts on or off. It is only the blinking of the ACT LED that is significant. A dim ACT LED also has no significance beyond the fact that you are using a B. From the model B+ onwards, the LED is driven differently, and it wont be dim.


With no SD card inserted, note how the ACT LED behaves (hint, it won't blink!). Now insert a programmed card and that behaviour should change. If it does not, this indicates that Pi cannot see the necessary files on the SD card. For a demonstration, watch this video of a model B: the ACT LED is the one on the left-hand side. Note that on later models the ACT LED will start on on power up, instead as off like the model B. 


With working firmware, Meaning the PI can read files from the card, the ACT LED will flicker intermittently for 20-30 seconds. The LED is actually driven by the software read from the card using a dedicated GPIO pin turning it on whenever the card is read. It can also blink in a regular "Morse" pattern, which usually indicates an error condition. See the Additional Information section at the end of this post for details.  


[링크 : https://www.raspberrypi.org/forums/viewtopic.php?t=58151]

Posted by 구차니
embeded/odroid2016. 10. 29. 22:47

저번에 X 시작 제대로 안된거

아무래도.. 용량 부족해서

패키지 깔다가 오류 난듯 -_-


원인은.. 언어팩 설치 하면서 gimp랑 libreoffice쪽 언어팩이 용량 왕창 잡아 먹은거..

'embeded > odroid' 카테고리의 다른 글

odroid fb Driver  (0) 2016.11.03
odroid u3 - mali 400  (0) 2016.11.02
X 시작을 못하는 이유..2  (0) 2016.10.25
X 시작을 못하는 이유..?  (0) 2016.10.24
odroid에서 blender 재시도.. 실패 -_-  (0) 2016.10.23
Posted by 구차니
embeded/Cortex-M4 Ti2016. 10. 28. 09:23

4.19MHz에서는 1Mohm 문제 없었는데

32.768kHz에서는 아래와 같이 파형이 완전 차이가 난다.


흰색(ref)가 32.768k + 1Mohm

노란색이 32.768k + 저항없음



결론 : lm3s1607 -> tm4c123 마이그레이션 중 hibernate module 클럭에서 저항은 빠져야 함


+

lm3s1607 데이터 시트상 회로

X1에 평행하게 RL이 존재하는데 저항 용량은 알아서?


tm4c1231e6pm 데이터 시트상 회로

X1에 평행한 RL이 사라졌다.

LM3S devices support a 4.194304-MHz crystal. This crystal is not supported for TM4C devices,
however a 32.768-kHz crystal is supported. In addition, an external load resistor is not required
  

[원본 : spma049a.pdf]

'embeded > Cortex-M4 Ti' 카테고리의 다른 글

tm4c rtc 빨라...  (0) 2016.11.02
tm4c hibernate module 초기화 관련..  (0) 2016.11.01
tm4c FIFO 길이  (0) 2016.10.26
tm4c hibernate module oscillator 관련  (0) 2016.10.26
tm4c 비교표  (0) 2016.10.26
Posted by 구차니
embeded/Cortex-M4 Ti2016. 10. 26. 18:10

기본값은

RX 0x02

TX 0x10


라이브러리에서 확인하면

#define UART_FIFO_TX4_8         0x00000002  // Transmit interrupt at 1/2 Full

#define UART_FIFO_RX4_8         0x00000010  // Receive interrupt at 1/2 Full


1/2이 차면 한번씩 인터럽트를 발생시키게 되어 있다.

Posted by 구차니
embeded/Cortex-M4 Ti2016. 10. 26. 17:17




main clk

0~2.6V


hibernate clk

0.5~1.2v


문제 없어야 하는거 아닌가?

~HIB도 계속 high도 도대체 머가 문제지.. ㅠㅠ


+


[링크 : http://www.ti.com/lit/an/spma065/spma065.pdf]


the problem is resolved. the 1Mresistor is just the problem. thanks very much! regarding this problem, your answer is the best answer i have see in this forum.

[링크 : https://e2e.ti.com/support/microcontrollers/tiva_arm/f/908/t/385581]


+

아마도.. lm3s1607에서 4.1MHz 클럭을 쓰면서 1Mohm 저항을 달아서 섰는데

그걸 그대로 사용해서 그런걸지도?


+

2016.11.01

1M 저항 달아서 발진이 억눌리면서 안된 문제였음 -_-

'embeded > Cortex-M4 Ti' 카테고리의 다른 글

32.768kHz 크리스탈과 1Mohm 저항 유무에 따른 파형 차이  (0) 2016.10.28
tm4c FIFO 길이  (0) 2016.10.26
tm4c 비교표  (0) 2016.10.26
tm4c HibernateEnableExpClk() 차이점  (0) 2016.10.22
tm4c ..어라? hibernate...  (0) 2016.10.20
Posted by 구차니
embeded/Cortex-M4 Ti2016. 10. 26. 14:29

희한하네..


암튼 ek-tm4c123 쪽 보다는 

dk-tm4c123 쪽이 더 비싸고 좋고(어?)

예제도 많은듯

[링크 : https://github.com/yuvadm/tiva-c/tree/master/boards/dk-tm4c123g]

[링크 : https://github.com/yuvadm/tiva-c]




[링크 : http://www.ti.com/lit/sg/spmt285d/spmt285d.pdf]

'embeded > Cortex-M4 Ti' 카테고리의 다른 글

tm4c FIFO 길이  (0) 2016.10.26
tm4c hibernate module oscillator 관련  (0) 2016.10.26
tm4c HibernateEnableExpClk() 차이점  (0) 2016.10.22
tm4c ..어라? hibernate...  (0) 2016.10.20
tm4c123 rtc hibernate module  (0) 2016.09.28
Posted by 구차니
embeded/odroid2016. 10. 25. 21:24

root로 로그인 하니 되서

/root/.Xauthority 를 /home/odroid 에 복사하니 되긴하는데..

기본 작업관리자라던가 전부 뜨지 않고


openbox로 구동되긴 했는지

휠 클릭은 작업공간 변경(workspace)

우클릭에서는 각종 프로그램들을 구동할 수는 있게 되어 있다.


도대체 머가 문제지.. ㅠㅠ



+

lxsession을 실행하니 원래 비슷하게 나오네..

어디선가 세션을 실행못해서 그런가?


Xwin -> openbox -> lxsession

X윈도 -> 윈도매니저 -> 세션매니저

순서로 구동이 되는건가?

'embeded > odroid' 카테고리의 다른 글

odroid u3 - mali 400  (0) 2016.11.02
odroid eMMC 8GB 작구나...  (0) 2016.10.29
X 시작을 못하는 이유..?  (0) 2016.10.24
odroid에서 blender 재시도.. 실패 -_-  (0) 2016.10.23
odorid u3 emmc+sd 설치 순서  (0) 2016.10.22
Posted by 구차니
embeded/odroid2016. 10. 24. 09:20

DDX 교체하고 나서 odroid로 암호까지 쳐도

autologin 되어있어도 못들어 가는 문제가 생기는 바람에

밀어야 하나 고쳐봐야 하나 고민..


고치는걸로 오기 발동중인데.. 확 밀어 버려? -_-


.Xauthority in the home folder of the user odroid?

[링크 : http://forum.odroid.com/viewtopic.php?f=8&t=4250]

Posted by 구차니
embeded/odroid2016. 10. 23. 20:54

일단 다시 검색해서 해보려는데 영안되는건 마찬가지네..

[링크 : http://forum.odroid.com/viewtopic.php?f=99&t=6611]


$ blender

Color management: using fallback mode for management

connect failed: No such file or directory

libGL error: MESA-LOADER: malformed or no PCI ID

libGL error: dlopen /usr/lib/arm-linux-gnueabihf/dri/exynos_dri.so failed (/usr/lib/arm-linux-gnueabihf/dri/exynos_dri.so: cannot open shared object file: No such file or directory)

libGL error: dlopen ${ORIGIN}/dri/exynos_dri.so failed (${ORIGIN}/dri/exynos_dri.so: cannot open shared object file: No such file or directory)

libGL error: dlopen /usr/lib/dri/exynos_dri.so failed (/usr/lib/dri/exynos_dri.so: cannot open shared object file: No such file or directory)

libGL error: unable to load driver: exynos_dri.so

libGL error: driver pointer missing

libGL error: failed to load driver: exynos

Writing: /tmp/blender.crash.txt

Segmentation fault 


/usr/lib/arm-linux-gnueabihf$ ll libdrm_exynos.*

-rw-r--r-- 1 root root 12118 may 12 03:41 libdrm_exynos.a

lrwxrwxrwx 1 root root    22 may 12 03:40 libdrm_exynos.so -> libdrm_exynos.so.1.0.0

lrwxrwxrwx 1 root root    22 may 12 03:40 libdrm_exynos.so.1 -> libdrm_exynos.so.1.0.0

-rw-r--r-- 1 root root 13732 may 12 03:41 libdrm_exynos.so.1.0.0 


drm은 존재하나 dri는 존재하지 않는다!?!?

/usr/lib/arm-linux-gnueabihf/dri$ ll

total 21116

drwxr-xr-x  2 root root    4096 oct  8 21:28 ./

drwxr-xr-x 94 root root   94208 oct 23 21:11 ../

-rw-r--r--  1 root root   13884 abr 16  2014 dummy_drv_video.so

-rw-r--r--  1 root root 2632560 ene 13  2016 nouveau_dri.so

-rw-r--r--  4 root root 2482560 ene 13  2016 nouveau_vieux_dri.so

-rw-r--r--  4 root root 2482560 ene 13  2016 r200_dri.so

-rw-r--r--  1 root root 2186172 ene 13  2016 r300_dri.so

-rw-r--r--  1 root root 2550644 ene 13  2016 r600_dri.so

-rw-r--r--  4 root root 2482560 ene 13  2016 radeon_dri.so

-rw-r--r--  1 root root 2086952 ene 13  2016 radeonsi_dri.so

-rw-r--r--  4 root root 2482560 ene 13  2016 swrast_dri.so

-rw-r--r--  1 root root 2096024 ene 13  2016 vmwgfx_dri.so 


odroid-utiltity.sh 실행중에 업데이트 되는 녀석이 있는데

얘는 X11 DDX 인가. .먼가 그거 업데이트 하는 녀석

$ armsoc.sh

bash: /usr/local/bin/armsoc.sh: Permission denied 


$ cat /usr/local/bin/armsoc.sh

#!/bin/bash


rebuild_armsoc() { 

get_board 

if [ "$BOARD" = "odroidxu" ]; then

armsoc_err_not_supported

return

fi

if [ "$BOARD" = "odroidc" ]; then

apt-get -y update

apt-get -y dist-upgrade

msgbox "All updates performed. You don't need to run any other updates."

return

fi

do_5422_1504_apt_update

if [ "$DISTRO" = "ubuntu" ]; then

armsoc_rebuild_ubuntu

elif [ "$DISTRO" = "debian" ]; then

armsoc_rebuild_debian

else

armsoc_err_not_supported

fi

}


armsoc_rebuild_ubuntu() { 

if [ "$BOARD" = "odroidxu3" ]; then

msgbox "ODROID-XU3 isn't supported yet"

return

fi

root=/tmp/armsoc-update

buildlog=/root/armsoc-update-$DATE.txt

mkdir -p $root

cd $root

# Install dependencies.

apt-get -y build-dep xserver-xorg-video-armsoc

# Download the blobs

dlf builder.mdrjr.net/tools/u3/4412_r5p0_x11.tar.xz "Downloading Mali Binaries" $root/mali.tar.xz

# Download armsoc DDX from github

dlf https://github.com/mdrjr/xf86-video-armsoc/archive/r4p0.zip "Downloading ARMSOC DDX Sources from Github" $root/ddx.zip

echo "Building Mali DDX and Installing Binaries. Please wait"

echo "Saving build logs to $buildlog"

# Unpack

xz -d mali.tar.xz &>> $buildlog

tar xf mali.tar &>> $buildlog

unzip -qq ddx.zip &>> $buildlog

# Build DDX

cd xf86-video-armsoc-r4p0

./autogen.sh --with-drmmode=exynos --prefix=/usr &>> $buildlog

make -j4 &>> $buildlog

make install &>> $buildlog

cd ..

# Install new Binaries

cd mali

cp -aRP lib* /usr/lib

cp -aRP lib* /usr/lib/arm-linux-gnueabihf/mali-egl

ldconfig

cp config/xorg.conf /etc/X11/xorg.conf

sync

msgbox "Mali is now updated. If something fails or isn't working report on the forums with the following file: $buildlog"

}


armsoc_rebuild_debian() { 

if [ "$BOARD" = "odroidxu3" ]; then

msgbox "ODROID-XU3 isn't supported yet"

return

fi

root=/tmp/armsoc-update

buildlog=/root/armsoc-update-$DATE.txt

mkdir -p $root

cd $root

echo "Debian requires some extra packages to build. We are installing it.. Please wait."

# debian requires some extra packages to build the DDX. So.. lets install it

apt-get -y build-dep xserver-xorg-video-modesetting xserver-xorg-video-nouveau &>> $buildlog

apt-get -y install build-essential git xz-utils xserver-xorg-dev libudev-dev &>> $buildlog

# Download the blobs

dlf builder.mdrjr.net/tools/u3/4412_r5p0_x11.tar.xz "Downloading Mali Binaries" $root/mali.tar.xz

# Download armsoc DDX from github

dlf https://github.com/mdrjr/xf86-video-armsoc/archive/r4p0.zip "Downloading ARMSOC DDX Sources from Github" $root/ddx.zip

echo "Building Mali DDX and Installing Binaries. Please wait"

echo "Saving build logs to $buildlog"

# Unpack

xz -d mali.tar.xz &>> $buildlog

tar xf mali.tar &>> $buildlog

unzip -qq ddx.zip &>> $buildlog

# Build DDX

cd xf86-video-armsoc-r4p0

./autogen.sh --with-drmmode=exynos --prefix=/usr &>> $buildlog

make -j4 &>> $buildlog

make install &>> $buildlog

cd ..

# Install new Binaries

cd mali

cp -aRP lib* /usr/lib

ldconfig

cp config/xorg.conf /etc/X11/xorg.conf

cd /tmp && rm -fr $root

sync

msgbox "Mali is now updated. If something fails or isn't working report on the forums with the following file: $buildlog"

}


armsoc_err_not_supported() {

msgbox "ARMSOC: Your distro isn't supported. Report this on the forums -> Distro $DISTRO and board $BOARD"

}


DDX 깔고 나니 먼가 추가되긴 한데...

/usr/lib/arm-linux-gnueabihf/mali-egl$ ll

total 1172

drwxr-xr-x  2 root root    4096 oct 23 22:19 ./

drwxr-xr-x 94 root root   94208 oct 23 21:11 ../

-rw-r--r--  1 root root      38 may  8  2014 ld.so.conf

lrwxrwxrwx  1 root root      11 feb 18  2015 libEGL.so -> libEGL.so.1*

lrwxrwxrwx  1 root root      13 feb 18  2015 libEGL.so.1 -> libEGL.so.1.4*

lrwxrwxrwx  1 root root      10 feb 18  2015 libEGL.so.1.4 -> libMali.so*

lrwxrwxrwx  1 root root      17 feb 18  2015 libGLESv1_CM.so -> libGLESv1_CM.so.1*

lrwxrwxrwx  1 root root      19 feb 18  2015 libGLESv1_CM.so.1 -> libGLESv1_CM.so.1.1*

lrwxrwxrwx  1 root root      10 feb 18  2015 libGLESv1_CM.so.1.1 -> libMali.so*

lrwxrwxrwx  1 root root      14 feb 18  2015 libGLESv2.so -> libGLESv2.so.2*

lrwxrwxrwx  1 root root      16 feb 18  2015 libGLESv2.so.2 -> libGLESv2.so.2.0*

lrwxrwxrwx  1 root root      10 feb 18  2015 libGLESv2.so.2.0 -> libMali.so*

-rwxr-xr-x  1 root root 1066735 feb 18  2015 libMali.so*

-rw-r--r--  1 root root   22232 feb 22  2013 libUMP.so


Open Source Mali GPUs Linux EXA/DRI2 and X11 Display Drivers

[링크 : http://malideveloper.arm.com/.../open-source-mali-gpus-linux-exadri2-and-x11-display-drivers/...]



log$ grep "EE" Xorg.0.log

[   593.576] (EE) AIGLX error: dlopen of /usr/lib/arm-linux-gnueabihf/dri/armsoc_dri.so failed (/usr/lib/arm-linux-gnueabihf/dri/armsoc_dri.so: cannot open shared object file: No such file or directory)

[   593.576] (EE) AIGLX: reverting to software rendering 


아놔.. 이거 하고 나니 이제 odroid 계정으로 xwin을 구동할수도 없네 -_-

머야?!?!

'embeded > odroid' 카테고리의 다른 글

X 시작을 못하는 이유..2  (0) 2016.10.25
X 시작을 못하는 이유..?  (0) 2016.10.24
odorid u3 emmc+sd 설치 순서  (0) 2016.10.22
odroid u3 릴리즈 노트의 중요한... 내용?  (0) 2016.10.22
넌 또 왜 난리니 ㅠㅠ  (0) 2016.10.21
Posted by 구차니
embeded/Cortex-M4 Ti2016. 10. 22. 14:27

음.. lm3s랑 tm4c driverlib을 보다 보니..


tm4c

static void

_HibernateWriteComplete(void)

{

    //

    // Spin until the write complete bit is set.

    //

    while(!(HWREG(HIB_CTL) & HIB_CTL_WRC))

    {

    }

}


void

HibernateEnableExpClk(uint32_t ui32HibClk)

{

    //

    // Turn on the clock enable bit.

    //

    HWREG(HIB_CTL) |= HIB_CTL_CLK32EN;


    //

    // Wait for write complete following register load (above).

    //

    _HibernateWriteComplete();


코드 분위기를 보아하니.. HibernateEnableExpClk()는 쓰지 말고, 얘를 쓰면 될 듯?

void

HibernateClockConfig(uint32_t ui32Config)

{

    uint32_t ui32HIBCtl;


    ASSERT((ui32Config & ~(HIBERNATE_OSC_HIGHDRIVE | HIBERNATE_OSC_LOWDRIVE |

                           HIBERNATE_OSC_DISABLE)) == 0);


    ui32HIBCtl = HWREG(HIB_CTL);


    //

    // Clear the current configuration bits.

    //

    ui32HIBCtl &= ~(HIBERNATE_OSC_HIGHDRIVE | HIBERNATE_OSC_LOWDRIVE |

                    HIBERNATE_OSC_LFIOSC | HIBERNATE_OSC_DISABLE);


    //

    // Set the new configuration bits.

    //

    ui32HIBCtl |= ui32Config & (HIBERNATE_OSC_HIGHDRIVE |

                                HIBERNATE_OSC_LOWDRIVE |

                                HIBERNATE_OSC_LFIOSC |

                                HIBERNATE_OSC_DISABLE);


    //

    // Must be sure that the 32KHz clock is enabled if the hibernate is about

    // to switch to it.

    //

    if(ui32Config & HIBERNATE_OSC_LFIOSC)

    {

        ui32HIBCtl |= HIB_CTL_CLK32EN;

    }


    //

    // Set the hibernation clocking configuration.

    //

    HWREG(HIB_CTL) = ui32HIBCtl;


    //

    // Wait for write completion

    //

    _HibernateWriteComplete();


    //

    // Write the output clock configuration for devices that support

    // controlling the output clocks from the hibernate module.

    //

    if(HIBERNATE_CLOCK_OUTPUT)

    {

        HWREG(HIB_CC) = ui32Config & (HIBERNATE_OUT_SYSCLK |

                                      HIBERNATE_OUT_ALT1CLK);

    }


lm3s

void

HibernateEnableExpClk(unsigned long ulHibClk)

{

    //

    // Turn on the clock enable bit.

    //

    HWREG(HIB_CTL) |= HIB_CTL_CLK32EN;


    //

    // For Fury-class devices, compute the number of delay loops that must be

    // used to achieve the desired delay for writes to the hibernation

    // registers.  This value will be used in calls to SysCtlDelay().

    //

    if(CLASS_IS_FURY)

    {

        g_ulWriteDelay = (((ulHibClk / 1000) * DELAY_USECS) /

                          (1000L * LOOP_CYCLES));

        g_ulWriteDelay++;

    }

}


tm4c 레지스터

WRC는 WR Complete 확인용인데 여기서 벗어나질 못하네



CLK32EN은.. tm4c 되면서 클럭이 무조건 32k로 바뀌었으니..



+

크리스탈이 발진 안하면 루프를 못 빠져 나오나?


The only time that I know of if the code loops like this is if the 32768Hz clock is not getting started. if this is a custom board can you make sure that the 32768Hz crystal is well mounted/soldered?

[링크 : https://e2e.ti.com/support/microcontrollers/tiva_arm/f/908/t/393107]

'embeded > Cortex-M4 Ti' 카테고리의 다른 글

tm4c hibernate module oscillator 관련  (0) 2016.10.26
tm4c 비교표  (0) 2016.10.26
tm4c ..어라? hibernate...  (0) 2016.10.20
tm4c123 rtc hibernate module  (0) 2016.09.28
tm4c uart fifo/buffer 문제  (0) 2016.09.28
Posted by 구차니