»Ë»Ñ Á¤º¸

[ºñ±Ûº»ºí·¢] SHT75¼¾¼­ »ç¿ëÀ» À§ÇÑ ¿ìºÐÅõ Ä¿³Î ÄÄÆÄÀÏ (ÁøÇà)

¿ì¼± Á¦°¡ óÀ½¿¡ »ý°¢Çß´ø °ÍÀº ºñ±Ûº» ºí·¢(BeagleBone Black)¿¡¼­ ¼¾½Ã¸®¿Â(Sensirion)»çÀÇ SHT-75(SHT75) ¿Â½Àµµ ¼¾¼­¸¦ Á÷Á¢ ¿¬°áÇÏ¿© Áý¾ÈÀÇ ¿Â½Àµµ °ªÀ» ÃøÁ¤Çؼ­ DB¿¡ ·Î±ëÇϰųª À¥À» ÅëÇØ ¿ÜºÎ¿¡¼­µµ ¸ð´ÏÅ͸µÀÌ °¡´ÉÇϵµ·Ï Çϴ ½Ã½ºÅÛÀ̾ú½À´Ï´Ù.

 

Á¦°¡ »ç¿ëÇÏ·Á´Â ¼¾¼­´Â ¾Æ·¡¿Í °°Àº ¸ð½ÀÀÔ´Ï´Ù.

Âü°í : http://www.sensirion.com/en/products/humidity-temperature/humidity-sensor-sht75/

 

ÀÌ ¼¾¼­¸¦ »ç¿ëÇÏ°Ô µÈ ÀÌÀ¯´Â ¾Æ·¡ Ç¥¿Í °°ÀÌ ´Ù¸¥ ¼¾¼­¿¡ ºñÇØ Á¤È®µµ ¿ÀÂ÷¹üÀ§°¡ »ó´çÈ÷ À۱⠶§¹®¿¡

ºñ±³Àû Á¤È®ÇÑ ¿Â½Àµµ ÃøÁ¤ÀÌ °¡´ÉÇϱ⠶§¹®ÀÔ´Ï´Ù.

 SHT75´Â ½Àµµ +-1.8, ¿ÂÅä +- 0.3ÀÇ ¿ÀÂ÷¹üÀ§¸¦ °¡Áý´Ï´Ù.

 

¿ì¼± ¿¬°áÀ» À§ÇÑ ÇÉ Á¤º¸¸¦ ¾Ë¾Æº¸±â À§ÇØ µ¥ÀÌÅͽÃÆ®¸¦ »ìÆìºÃ½À´Ï´Ù.

 

µ¥ÀÌÅͽÃÆ®¿¡´Â À§ ±×¸²°ú °°ÀÌ ¿¬°áÇϵµ·Ï µÇ¾î ÀÖ½À´Ï´Ù.

Data¿Í Clock ÇÉÀ» ¸¶ÀÌÄÄ°ú ¿¬°áÇÏ°í, ³ª¸ÓÁö µÎ °³´Â GND¿Í VDD¿¡ ¿¬°áÇÕ´Ï´Ù.

µ¥ÀÌÅͶóÀο¡´Â 10Kohm ¿ÜºÎ Ç®¾÷ ÀúÇ×À» ¿¬°áÇ϶ó°í µÇ¾î ÀÖ½À´Ï´Ù.

 

¼¾¼­ ÇÉÀº ¼¾¼­¸¦ Á¤¸éÀ¸·Î ºÃÀ» ¶§ ¿À¸¥ÂʺÎÅÍ 1, 2, 3, 4 ¿´À¸¸ç, °¢ ÇÉÀÇ ¿ªÇÒÀº ¾Æ·¡¿Í °°½À´Ï´Ù.

 

Áß°£ µÎ ¶óÀÎÀÌ Àü¿øÀÌ°í, ¾çÂÊ 2¶óÀÎÀÌ Åë½Å¿ë ȸ¼± ÀÔ´Ï´Ù.

 

¼¾¼­¸¦ º¸È£Çϱâ À§ÇØ Àü¿ë ¼¾¼­Ä¸(SF-7)À» »ç¿ëÇÏ¿´°í, ÄÉÀÌºí¿¡ Ç®¾÷ÀúÇ×À» ¿¬°áÇؼ­ ¾Æ·¡ ±×¸²°ú °°ÀÌ ¼¾¼­ ¸ðµâÀ» °£¼ÒÈ­Çß½À´Ï´Ù.

 

SHT7X¿ë Àü¿ë ¼¾¼­Ä¸(SF-7, http://icbanq.com/shop/product_detail.asp?prod_code=P000138869)¿¡ ¼¾¼­¸¦ ³³¶«ÇÏ°í, ÄÉÀ̺íÀ» ¿¬°áÇÑ ¸ð½À.

 

SHT-75 ¼¾¼­ÀÇ ¸ð½ÀÀÔ´Ï´Ù. (ÈÞ´ëÆù Ä«¸Þ¶ó·Î ÃÔ¿µÇÏ¿© ¿µ»óÀÌ ±ú²ýÇÏÁö ¸øÇÑ Á¡ ¾çÇعٶø´Ï´Ù.) 

 

 

ºÓÀº»ö »ç°¢Çü ºÎºÐ¿¡ 10kohm Ç®¾÷ ÀúÇ×À» VDD¿Í DATA¶óÀÎ »çÀÌ¿¡ ¿¬°áÇÏ¿´½À´Ï´Ù.

 

¿Ï¼ºµÈ ¼¾¼­ ¸ðµâÀ» ºñ±Ûº»¿¡ ±×¸²Ã³·³ GPIO Æ÷Æ®¿¡ ¿¬°áÇÕ´Ï´Ù(Á¤È®È÷ ÀåÂøµÈ »çÁø ¾Æ´Ô, ¿¬°á ¿¹½Ã).

¿µ¾î¿¡ ¾àÇØ µ¥ÀÌÅͽÃÆ®¸¦ ¿ÏÀüÈ÷ ÀоÁö´Â ¸øÇßÁö¸¸ TWI(I2C)Åë½ÅÀ¸·Î ÀÛµ¿µÈ´Ù°í ¾²¿© ÀÖ´Â °Í °°¾Æ I2CÆ÷Æ®¸¦ ÀÌ¿ëÇϱâ·Î ÇÏ¿´½À´Ï´Ù.

 

¸ÕÀú ºñ±Ûº»ÀÇ I2C ÇÉÀ» Á¶»çÇØ º¸´Ï ¾Æ·¡¿Í °°ÀÌ ÇÒ´çµÇ¾î ÀÖ¾ú½À´Ï´Ù.

 

P9_18 : I2C1_SDA

P9_17 : I2C1_SCL

 

P9_19 : I2C2_SCL

P9_20 : I2C2_SDA

 

Àú µÎ ¼¼Æ® Áß Çϳª¸¦ »ç¿ëÇϱâ·Î ÇÏ¿´½À´Ï´Ù.

Àü¿øÀº 3.3º¼Æ® ÇÉ¿¡¼­ ´ç°Ü¿À±â·Î Çß½À´Ï´Ù. ±×¶ó¿îµå´Â ±×¶ó¿îµåÇÉ¿¡ ¿¬°áÇÏ°í¿ä..

 

ºñ±ÛÆù ÇÉ Á¤º¸´Â ¾Æ·¡ ±×¸²°ú °°½À´Ï´Ù.

P9ÀÇ 17, 18¹ø ÇÉÀÌ I2C1Æ÷Æ® ¶ó°í ÇÏ¿´´Âµ¥ ºñ±Ûº»ºí·¢ ȨÆäÀÌÁö¿¡¼­ °¡Á® ¿Â ¾Æ·¡ À̹ÌÁö¿¡´Â ÇØ´çÇÉÀ» ±×³É GPIO4,5¹ø Æ÷Æ®·Î Ç¥½ÃÇÏ°í Àֳ׿ä..

VDD 3.3V¿Í GND´Â 3¹ø 1¹ø ÇÉÀ» »ç¿ëÇϱâ·Î Çß½À´Ï´Ù.

Åë½Å¶óÀÎÀº 17,18 ¶Ç´Â 19, 20 ¹øÀ» »ç¿ëÇϱâ·Î Çß½À´Ï´Ù.

 

 

°ü·Ã ÀÛ¾÷À» ¸ÕÀú ÇϽŠºÐÀÌ ÀÖ´ÂÁö ¾Ë¾Æº¸±â À§ÇØ °Ë»ö¿£Áø¿¡ °Ë»öÀ» ÇØ º¸¾ÒÀ¸³ª ±¹³» °Ë»ö¿£Áø¿¡´Â ÀÚ·á°¡ Àü¹«ÇÏ¿© ±¸±Û¿¡ °Ë»öÀ» ÇØ º¸¾Ò½À´Ï´Ù.

 

°Ë»ö °á°ú µ¿»çÀÇ SHT21 ¿ë µå¶óÀ̹ö ¸ðµâÀÌ ÀÌ¹Ì ¸®´ª½º ±âº» Ä¿³Î¿¡ Æ÷ÇԵǾî ÀÖ´Ù´Â °ÍÀ» ¾Ë¾Ò½À´Ï´Ù.

ÇÏÁö¸¸ SHT75´Â SHT21°ú´Â ¸í·É¾î°¡ ȣȯµÇÁö ¾Ê¾Æ ÇØ´ç µå¶óÀ̹ö¸¦ »ç¿ëÇÒ ¼ö ¾ø´Ù´Â °Íµµ ÇÔ²² ¾²¿© ÀÖ¾ú½À´Ï´Ù. ´ë½Å SHT15¿ë µå¶óÀ̹ö°¡ SHT75¿Í ȣȯÀÌ µÇ°í, ÇØ´ç µå¶óÀ̹öÀÇ ¼Ò½º´Â Ä¿³Î¼Ò½º¿Í ÇÔ²² Á¦°øÀÌ µÇÁö¸¸ Ä¿³Î ÄÄÆÄÀÏ ½Ã ±âº»ÀûÀ¸·Î Æ÷ÇԵǾî ÄÄÆÄÀϵÇÁö´Â ¾Ê´Â´Ù´Â »ç½ÇÀ» ¾Ë°Ô µÇ¾ú½À´Ï´Ù.

 

±×·¡¼­ Ä¿³Î ÄÄÆÄÀÏÀ» Çϱâ·Î ÇÏ¿´½À´Ï´Ù.

¸ÕÀú SDÄ«µå¿¡ ¿ìºÐÅõ 12,04¹öÀüÀ» ¼³Ä¡ÇÏ°í ½ÃÀÛÇÏ¿´À¸³ª, ÇØ´ç ³»¿ëÀº ÀÌ¹Ì ´Ù¸¥ºÐµé²²¼­ Àß ¼³¸íÇØÁÖ¼ÌÀ¸¹Ç·Î ¿ìºÐÅõ°¡ ¸ÕÀú ¼³Ä¡µÇ¾î ÀÖ´Ù´Â °¡Á¤ÇÏ¿¡ ¼³¸í µå¸³´Ï´Ù.

 

Á¦°¡ ¼³Ä¡¿¡ Âü°íÇÑ URLÀº ´ÙÀ½°ú °°½À´Ï´Ù.

Ubuntu On BeagleBone Black : http://circuitco.com/support/index.php?title=Ubuntu_On_BeagleBone_Black

 

SDÄ«µå¿¡ ¿ìºÐÅõ¸¦ ¼³Ä¡ÇÏ°í ³ª¸é ±âº»ÆÄƼ¼ÇÀÌ 2±â°¡±îÁö ¹Û¿¡ ÀνÄÀ» ¸øÇÕ´Ï´Ù.

ÀÌ°ÍÀ» Àüü ¿ë·®À» »ç¿ë °¡´ÉÇϵµ·Ï È®ÀåÇØÁÖ¾î¾ß ÇÕ´Ï´Ù.

Âü°í URLÀº ´ÙÀ½°ú °°½À´Ï´Ù.

 

Expanding File System Partition On A microSD : http://circuitco.com/support/index.php?title=Expanding_File_System_Partition_On_A_microSD

 

À§ÀÇ »çÀÌÆ®¸¦ ÅëÇØ ÆÄƼ¼Ç È®Àå±îÁö ÇÏ½Ã°í ³ª¸é Ä¿³ÎÀ» ÄÄÆÄÀÏ ÇÒ ¼ö ÀÖ½À´Ï´Ù.

 

Âü°í·Î SDÄ«µå´Â 8±â°¡ ÀÌ»óÀ» »ç¿ëÇÏ½Ã±æ ¹Ù¶ø´Ï´Ù.

Á¦°¡ ÃÖÃÊ ½Ãµµ ¶§ 4±â°¡ SDÄ«µå¸¦ »ç¿ëÇÏ¿´´Âµ¥, Ä¿³Î ÄÄÆÄÀÏ ½ÇÆÐÇÏ¿´½À´Ï´Ù. Ä¿³Î ¼Ò½º ´Ù¿î·Îµå ¹× ÄÄÆÄÀÏ¿¡ ¼Ò¿äµÇ´Â ¿ë·®ÀÌ 4±â°¡°¡ ³ÑÀ» °¡´É¼ºÀÌ ÀÖ½À´Ï´Ù.

 

Ä¿³Î ÄÄÆÄÀÏ¿¡ Âü°íÇÑ ±ÛÀº ¾Æ·¡ URL¿¡ ÀÖ½À´Ï´Ù.

http://cafe.naver.com/nixtek1/219

¼Ò½º¸¦ ¹Þ°í ÄÄÆÄÀÏ ÇÏ´Â °úÁ¤À» ½ºÅ©¸³Æ®·Î ó¸®ÇسõÀº°Ô À־ °£´ÜÇÏ°Ô ÄÄÆÄÀÏ ÇÒ ¼ö ÀÖ´Â ¹æ¹ýÀÔ´Ï´Ù.

´Ù¸¸ ¸¶Áö¸· ºÎºÐ¿¡ ¾à°£ ¸ðÈ£ÇÑ ºÎºÐÀÌ ÀÖ¾î, Àú¿Í °°Àº ¹®Á¦°¡ ¹ß»ýÇϽô ºÐµé¿¡°Ô µµ¿òÀÌ µÇ°íÀÚ Ä¿³Î ÄÄÆÄÀÏÀÇ Àü °úÁ¤À» ´Ù½Ã »ìÆ캾´Ï´Ù.

±×¸®°í ¼Ò½º¿¡´Â ÀÖÁö¸¸ ±âº» ÄÄÆÄÀÏ¿¡´Â Æ÷ÇÔµÇÁö ¾Ê´Â ¸ðµâÀ» ¼±ÅÃÇÏ´Â ¹æ¹ýµµ ¼³¸í µå¸³´Ï´Ù.

 

¿ì¼± ºñ±Ûº»¿¡ ssh Å͹̳ηΠÁ¢¼Ó ÇÕ´Ï´Ù.

 

login as: ubuntu
ubuntu@192.168.1.240's password:
Welcome to Ubuntu 12.04.3 LTS (GNU/Linux 3.8.13-bone20 armv7l)

* Documentation:  https://help.ubuntu.com/
Last login: Wed Oct 23 21:25:12 2013 from 192.168.25.62


 

·Î±×ÀÎÀ» ÇÏ°í ³ª¸é À§¿Í °°ÀÌ ¹öÀüÀÌ Ç¥½ÃµË´Ï´Ù.

ÇöÀç Ä¿³Î ¹öÀüÀº 3.8.13-bone20 ÀÔ´Ï´Ù.

 

ubuntu@ubuntu-armhf:~$ sudo -i

 

sudo -i ¸í·ÉÀ¸·Î ¿ìºÐÅõ °ü¸®ÀÚ ±ÇÇÑÀ» ȹµæÇÕ´Ï´Ù.

github¿¡¼­ ¼³Ä¡ ½ºÅ©¸³Æ®¸¦ ´Ù¿î·Îµå ÇÕ´Ï´Ù. 

´Ù¿î·Îµå°¡ ¿Ï·áµÇ¸é ½ÇÇà±ÇÇÑÀ» ÁÖ°í ½ºÅ©¸³Æ®¸¦ ½ÇÇàÇÕ´Ï´Ù.

 

ubuntu@ubuntu-armhf:~# wget -c https://raw.github.com/RobertCNelson/tools/master/pkgs/dtc.sh

ubuntu@ubuntu-armhf:~# chmod +x dtc.sh

ubuntu@ubuntu-armhf:~# ./dtc.sh

 

½ºÅ©¸³Æ®°¡ ¼öÇàµÇ¸é /usr/local/bin/µð·ºÅ丮¿¡ dtc°¡ ¼³Ä¡µË´Ï´Ù.

Á¦´ë·Î ¼³Ä¡°¡ µÇ¾ú´ÂÁö È®ÀÎÇغ¾´Ï´Ù.

 

ubuntu@ubuntu-armhf:~# /usr/local/bin/dtc -v

Version : DTC 1.3.0-glea7e802

 

È®ÀÎÀÌ µÇ¾úÀ¸¸é git ÀúÀå¼Ò¸¦ clone, checkout ÇÕ´Ï´Ù.

 

ubuntu@ubuntu-armhf:~$ git clone git://github.com/RobertCNelson/linux-dev.git

ubuntu@ubuntu-armhf:~$ cd linux-dev

root@ubuntu-armhf:~/linux-dev# git checkout origin/am33x-v3.8 -b tmp

Branch tmp set up to track remote branch am33x-v3.8 from origin.
Switched to a new branch 'tmp'

 

¿Ï·áµÇ¸é Ä¿³Î ºôµå ¸í·É¾î¸¦ ½ÇÇàÇÕ´Ï´Ù.


root@ubuntu-armhf:~/linux-dev# ./build_kernel.sh
+ Detected build host [Ubuntu 12.04.2 LTS]
+ host: [armv7l]
+ git HEAD commit: [008c78651f7b25da854f579cdb84e8fee075fcf5]
Debian/Ubuntu/Mint: missing dependencies, please install:
-----------------------------
sudo apt-get update
sudo apt-get install bc device-tree-compiler lzma lzop man-db u-boot-tools
-----------------------------
* Failed dependency check

ÀÌ ´Ü°è¿¡¼­ À§¿Í °°ÀÌ µðÆÒ´ø½Ã üũ ¸Þ½ÃÁö°¡ ³ªÅ¸³¯ ¼öµµ ÀÖ½À´Ï´Ù.

È­¸é¿¡¼­ Áö½ÃÇϴµ¥·Î apt-getÀ» updateÇϽðí, °ü·Ã ÆÐÅ°Áö¸¦ ¸ÕÀú ¼³Ä¡ÇϽʽÿÀ.

°æ¿ì¿¡ µû¶ó ´õ ¸¹°Å³ª ´õ ÀûÀº ÆÐÅ°Áö°¡ Ç¥½ÃµÉ ¼ö ÀÖ½À´Ï´Ù.

¸ðµÎ ¼³Ä¡ÇØÁØ ÈÄ ´Ù½Ã ºôµå Ä¿³Î ½ºÅ©¸³Æ®¸¦ ½ÇÇàÇØÁÝ´Ï´Ù.

 

root@ubuntu-armhf:~/linux-dev# ./build_kernel.sh
+ Detected build host [Ubuntu 12.04.2 LTS]
+ host: [armv7l]
+ git HEAD commit: [008c78651f7b25da854f579cdb84e8fee075fcf5]
-----------------------------
scripts/gcc: Using: gcc (Ubuntu/Linaro 4.6.3-1ubuntu5) 4.6.3
Copyright (C) 2011 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
-----------------------------
debug: CC=
-----------------------------
Error: git user.name/user.email not set:

For help please read:
https://help.github.com/articles/setting-your-username-in-git
https://help.github.com/articles/setting-your-email-in-git

For example, if your real name and email was: Billy Everteen & me@here.com
you would type the following into the terminal window to set it up:
-----------------------------
git config --global user.name "Billy Everyteen"
git config --global user.email "me@here.com"
-----------------------------

 

È­¸é°ú °°ÀÌ ¶Ç ¿¡·¯°¡ ³³´Ï´Ù. git À¯Àú³×ÀÓ°ú À̸ÞÀÏÀÌ ¼¼ÆõÇÁö ¾Ê¾Ò±â ¶§¹®ÀÔ´Ï´Ù.

¿¹½Ã¿Í °°ÀÌ À̸§°ú À̸ÞÀÏÀ» ¼ÂÆÃÇÕ´Ï´Ù.


root@ubuntu-armhf:~/linux-dev# git config --global user.name "Billy Everyteen"
root@ubuntu-armhf:~/linux-dev# git config --global user.email "me@here.com"

 

¼¼Æà ÈÄ ´Ù½Ã ½ºÅ©¸³Æ®¸¦ ½ÇÇàÇØÁÖ¸é ÄÄÆÄÀÏÀÌ ½ÃÀ۵˴ϴÙ.

 

root@ubuntu-armhf:~/linux-dev# ./build_kernel.sh
+ Detected build host [Ubuntu 12.04.3 LTS]
+ host: [armv7l]
+ git HEAD commit: [008c78651f7b25da854f579cdb84e8fee075fcf5]
-----------------------------
scripts/gcc: Using: gcc (Ubuntu/Linaro 4.6.3-1ubuntu5) 4.6.3
Copyright (C) 2011 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
-----------------------------
debug: CC=
-----------------------------
scripts/git: LINUX_GIT not defined in system.sh
using default location: /root/linux-dev/ignore/linux-src/
-----------------------------
scripts/git: Debug: LINUX_GIT is setup as...
/root/linux-dev/ignore/linux-src
-----------------------------
[core]
        repositoryformatversion = 0
        filemode = true
        bare = false
        logallrefupdates = true
[remote "origin"]
        fetch = +refs/heads/*:refs/remotes/origin/*
        url = git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
[branch "master"]
        remote = origin
        merge = refs/heads/master
-----------------------------
scripts/git: Updating LINUX_GIT tree via: git fetch
/root/linux-dev
Resolve operation not in progress, we are not resuming.
git tree is clean...
[v3.8.13-bone28 520ded2] empty cleanup commit
HEAD is now at 520ded2 empty cleanup commit
Checking out files: 100% (22794/22794), done.
Switched to branch 'master'
Your branch is ahead of 'origin/master' by 1 commit.
Already up-to-date.
Deleted branch v3.8.13-bone28 (was 520ded2).
Checking out files: 100% (22704/22704), done.
Switched to a new branch 'v3.8.13-bone28'
v3.8.13
Starting patch.sh
dir: dma
Applying: Without MACH_ option Early printk (DEBUG_LL)
Applying: ARM: OMAP: Hack AM33xx clock data to allow JTAG use
..... (ÀÌÇÏ »ý·«)

 

ÇÑÂü °É¸³´Ï´Ù. configuration âÀÌ ¶ã ¶§±îÁö ¹«ÇÑ ±â´Ù¸²ÀÌ ½ÃÀ۵˴ϴÙ.

¹º°¡ ¸¶±¸ È­¸é¿¡ »Ñ·ÁÁöÁö¸¸ Àü ¹«½¼ ¸»ÀÎÁö ¸ð¸¨´Ï´Ù...

 

Kernel Configuration âÀÌ ¶¹½À´Ï´Ù.

¿©±â¼­ Ä¿³Î°ú ÇÔ²² ÄÄÆÄÀÏ ÇÒ ¸ðµâ µå¶óÀ̹ö¸¦ ¼±ÅÃÇØÁÝ´Ï´Ù.

È­¸é¿¡¼­ 'Device Drivers --->' Ç׸ñÀ» ¼±ÅÃÇÕ´Ï´Ù.

 

 

Á¦°¡ »ç¿ëÇÒ ¿Â½Àµµ ¼¾¼­´Â 'Hardware Monitoring Support --->' Ç׸ñ¿¡ ÀÖ½À´Ï´Ù.

¼±ÅÃÇؼ­ µé¾î°©´Ï´Ù.

 

 

 ¸®½ºÆ®¸¦ Âß ³»·Á¿À´Ù º¸¸é 'Sensiron humidity and temperature sensors. SHT15 and compat.'¶ó´Â Ç׸ñÀÌ ÀÖ½À´Ï´Ù. Á¦°¡ ĸÃçÇÑ È­¸é¿¡´Â ÀÌ Ç׸ñ ¾Õ¿¡ <M>ÀÌ Ç¥½ÃµÇ¾î Àִµ¥, Ãʱ⠻óÅ¿¡´Â ÀÌ ºÎºÐÀÌ ¼±ÅõǾî ÀÖÁö ¾Ê½À´Ï´Ù. SHT21 Ç׸ñ¸¸ ¼±ÅÃÀÌ µÇ¾î ÀÖ½À´Ï´Ù.

 

 

SHT15 Ç׸ñÀ» ¼±ÅÃÇÏ°í configurationÀ» ºüÁ®³ª¿À¸é ÄÄÆÄÀÏ °úÁ¤ÀÌ ÁøÇàµË´Ï´Ù.

 

 

½Ã°£ÀÌ ´Ù¼Ò ¼Ò¿äµË´Ï´Ù.

 

-----------------------------
script Complete
eewiki.net: [user@localhost:~$ export kernel_version=3.8.13-bone28]
-----------------------------

È­¸é°ú °°ÀÌ ½ºÅ©¸³Æ®°¡ ¿Ï·áµÇ¾ú´Ù´Â ¸Þ¼¼Áö°¡ ¶ß¸é ÄÄÆÄÀÏÀÌ ¿Ï·áµÈ °ÍÀÔ´Ï´Ù.

ÀåÀå ¹Ý³ªÀýÀÌ ³Ñ°Ô °É¸®³×¿ä...

3.8.13-bone28 ¹öÀüÀ¸·Î ¾÷µ¥ÀÌÆ® µÇ¾ú½À´Ï´Ù.

 

ÀÚ.. ±×·³ ÄÄÆÄÀÏµÈ Ä¿³Î À̹ÌÁö·Î ºÎÆÃÇϱâ À§ÇØ ¾à°£ÀÇ Ãß°¡ÀÛ¾÷À» ÇØ Áà¾ß ÇÕ´Ï´Ù.

deploy µð·ºÅ丮¿¡ »ý¼ºµÈ Ä¿³Î À̹ÌÁö¸¦ ºÎÆ®ÆÄƼ¼ÇÀ¸·Î Ä«ÇÇÇÕ´Ï´Ù.


root@ubuntu-armhf:~/linux-dev# export kernel_version=3.8.13-bone28
À§ÀÇ ½ºÅ©¸³Æ® ¿Ï·á ¸Þ¼¼Áö¿¡ Ç¥½ÃµÈ Ä¿³Î ¹öÀüÀ» ÀÔ·ÂÇØÁÝ´Ï´Ù.

 

ÇØ´ç ÆÄƼ¼ÇÀ» ¸¶¿îÆ®ÇÕ´Ï´Ù.

root@ubuntu-armhf:~/linux-dev# DISK=/dev/mmcblk0
root@ubuntu-armhf:~/linux-dev# mkdir /media/boot
root@ubuntu-armhf:~/linux-dev# mount ${DISK}p1 /media/boot/
root@ubuntu-armhf:~/linux-dev# mkdir /media/rootfs
root@ubuntu-armhf:~/linux-dev# mount ${DISK}p2 /media/rootfs/

 

Ä¿³Î À̹ÌÁö¸¦ Ä«ÇÇÇÕ´Ï´Ù.
root@ubuntu-armhf:~# cp -v ./linux-dev/deploy/${kernel_version}.zImage /media/boot/zImage
`./linux-dev/deploy/3.8.13-bone28.zImage' -> `/media/boot/zImage'
cp: writing `/media/boot/zImage': No space left on device

ºÎÆ® ÆÄƼ¼Ç ¸¶¿îÆ® ÈÄ Ä¿³Î À̹ÌÁö Ä«ÇÇ ½ÃµµÇßÀ¸³ª ¿ë·® ºÎÁ·À¸·Î ½ÇÆÐÇÏ¿´½À´Ï´Ù.

¿ë·®À» È®ÀÎÇغýÀ´Ï´Ù.


root@ubuntu-armhf:~# df -h
Filesystem      Size  Used Avail Use% Mounted on
/dev/mmcblk0p2   29G  3.1G   25G  12% /
devtmpfs        248M  4.0K  248M   1% /dev
none             50M  224K   50M   1% /run
none            5.0M     0  5.0M   0% /run/lock
none            248M     0  248M   0% /run/shm
/dev/mmcblk0p1 1004K 1004K     0 100% /boot/uboot
/dev/mmcblk0p1 1004K 1004K     0 100% /media/boot
/dev/mmcblk0p2   29G  3.1G   25G  12% /media/rootfs

 

boot ÆÄƼ¼Ç »ç¿ë·®ÀÌ 100%³×¿ä..

ÇØ´ç µð·ºÅ丮¿¡¼­ ¾î¶² ÆÄÀÏÀÌ ¿ë·®À» ¸¹ÀÌ ¸Ô´Â°ÇÁö ºÃ½À´Ï´Ù.


root@ubuntu-armhf:~# cd boot
root@ubuntu-armhf:/boot# ls -al
total 5556
drwxr-xr-x  4 root root    4096 Jun  9 01:50 .
drwxr-xr-x 22 root root    4096 Oct 23 12:23 ..
-rw-r--r--  1 root root 2328220 May 29 10:56 System.map-3.8.13-bone20
-rw-r--r--  1 root root  107778 May 29 10:56 config-3.8.13-bone20
drwxr-xr-x  2 root root    4096 Jun  9 01:50 dtbs
drwxr-xr-x  2 root root   16384 Jan  1  1970 uboot
-rwxr-xr-x  1 root root 3218440 May 29 10:56 vmlinuz-3.8.13-bone20
lrwxrwxrwx  1 root root      21 Jun  9 01:50 zImage -> vmlinuz-3.8.13-bone20

 

ÀÌÀü Ä¿³ÎÀ̹ÌÁö¿Í ½Ã½ºÅÛ ¸ÊÀÌ Á¦ÀÏ Å« ¿ë·®À» Â÷ÁöÇÏ°í ÀÖ¾ú½À´Ï´Ù.
ÀϺθ¸ »èÁ¦ÇÏ·Á°í ÇßÀ¸³ª µÎ ÆÄÀÏÀÌ ¿ö³« Å« ¿ë·®À» Â÷ÁöÇÏ°í À־,

ºÎÆÃÀÌ µÇÁö ¾ÊÀ» À§ÇèÀ» °¨¼öÇÏ°í ÇØ´ç µð·ºÅ丮ÀÇ ¸ðµç ÆÄÀÏÀ» »èÁ¦ÇÏ¿´½À´Ï´Ù
uboot µð·ºÅ丮´Â Àý´ë »èÁ¦ÇÏ¸é ¾ÈµË´Ï´Ù.


root@ubuntu-armhf:/boot# rm -rf System.map-3.8.13-bone20 config-3.8.13-bone20 dtbs/ vmlinuz-3.8.13-bone20 zImage
root@ubuntu-armhf:/boot# ls
uboot

ºÎÆ® °ü·Ã ÆÄÀÏÀ» boot µð·ºÅ丮·Î Ä«ÇÇÇÕ´Ï´Ù.

root@ubuntu-armhf:/boot# cd ~/linux-dev/deploy/
root@ubuntu-armhf:~/linux-dev/deploy# cp -v 3.8.13-bone28.zImage /boot/zImage
`3.8.13-bone28.zImage' -> `/boot/zImage'

root@ubuntu-armhf:~/linux-dev/deploy# ls /boot
uboot  zImage

ȯ°æ¼³Á¤ ÆÄÀϵµ ÇÔ²² Ä«ÇÇÇÕ´Ï´Ù.
root@ubuntu-armhf:~/linux-dev/deploy# cp 3.8.13-bone28.config /boot/

root@ubuntu-armhf:~/linux-dev/deploy# ls /boot
3.8.13-bone28.config  uboot  zImage

dtbs ÆÄÀϵµ boot µð·ºÅ丮¿¡ Ç®¾îÁÝ´Ï´Ù.


root@ubuntu-armhf:~/linux-dev/deploy# mkdir -p /boot/dtbs/
root@ubuntu-armhf:~/linux-dev/deploy# tar xofv 3.8.13-bone28-dtbs.tar.gz -C /boot/dtbs/

root@ubuntu-armhf:~/linux-dev/deploy# ls /boot
3.8.13-bone28.config  dtbs  uboot  zImage

¸®ºÎÆÃÇÕ´Ï´Ù.
root@ubuntu-armhf:~/linux-dev/deploy# reboot

Á¤»óÀûÀ¸·Î ºÎÅÁÀÌ µÈ´Ù¸é ¿Ï·áµÈ °ÍÀÔ´Ï´Ù.

ÀÌÁ¦ µå¶óÀ̹ö ÆÄÀÏÀ» Ç®¾î ÁÙ Â÷·ÊÀÔ´Ï´Ù.


root@ubuntu-armhf:~# cd linux-dev/deploy/
root@ubuntu-armhf:~/linux-dev/deploy# ls
3.8.13-bone28-dtbs.tar.gz      3.8.13-bone28-modules.tar.gz  3.8.13-bone28.zImage
3.8.13-bone28-firmware.tar.gz  3.8.13-bone28.config          tmp

deploy µð·ºÅ丮¿¡ ÀÖ´Â ¶óÀ̺귯¸® ÆÄÀÏÀ» ·çÆ®¿¡ ÇØÁ¦ÇÕ´Ï´Ù.

root@ubuntu-armhf:~/linux-dev/deploy# tar xovf 3.8.13-bone28-modules.tar.gz -C /

 

ÇØÁ¦ ÈÄ ÇØ´ç ¶óÀ̺귯¸® µð·ºÅ丮¸¦ »ìÆ캸¸é sht15.ko ÆÄÀÏÀÌ Á¸ÀçÇÏ´Â °ÍÀ» È®ÀÎÇÒ ¼ö ÀÖ½À´Ï´Ù. 

root@ubuntu-armhf:~/linux-dev/deploy# ls /lib/modules/3.8.13-bone28/kernel/drivers/hwmon/
gpio-fan.ko  hih6130.ko  max197.ko  sht15.ko  sht21.ko  tmp102.ko

¸ðµâÀ» ·Îµå ÇÕ´Ï´Ù.

·çÆ®±ÇÇÑÀ» ¾òÀº »óÅ¿¡¼­ ¾Æ·¡ÀÇ ¸í·É¾î¸¦ ½ÇÇàÇÕ´Ï´Ù.

 

root@ubuntu-armhf:~# modprobe sht15

·ÎµåµÈ ¸ðµâÀÇ Á¤º¸¸¦ È®ÀÎÇÕ´Ï´Ù.

root@ubuntu-armhf:~# modinfo sht15
filename:       /lib/modules/3.8.13-bone28/kernel/drivers/hwmon/sht15.ko
description:    Sensirion SHT15 temperature and humidity sensor driver
license:        GPL
srcversion:     8F60F17748F23187A4CE01F
alias:          platform:sht75
alias:          platform:sht71
alias:          platform:sht15
alias:          platform:sht11
alias:          platform:sht10
depends:
intree:         Y
vermagic:       3.8.13-bone28 SMP mod_unload modversions ARMv7 p2v8

i2c_tools ÆÐÅ°Áö¸¦ ¼³Ä¡ÇÕ´Ï´Ù.

root@ubuntu-armhf:/# apt-get install i2c-tools

 

i2c ¸ðµâÀ» ã±â À§ÇØ ¾Æ·¡ ¸í·É¾î¸¦ ÀÔ·ÂÇÕ´Ï´Ù.

 

root@ubuntu-armhf:/# i2cdetect -r -y 0
     0  1  2  3  4  5  6  7  8  9  a  b  c  d  e  f
00:          -- -- -- -- -- -- -- -- -- -- -- -- --
10: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
20: -- -- -- -- UU -- -- -- -- -- -- -- -- -- -- --
30: -- -- -- -- UU -- -- -- -- -- -- -- -- -- -- --
40: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
50: UU -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
60: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
70: UU -- -- -- -- -- -- --

 

root@ubuntu-armhf:/# i2cdetect -r -y 1
     0  1  2  3  4  5  6  7  8  9  a  b  c  d  e  f
00:          -- -- -- -- -- -- -- -- -- -- -- -- --
10: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
20: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
30: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
40: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
50: -- -- -- -- UU UU UU UU -- -- -- -- -- -- -- --
60: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
70: -- -- -- -- -- -- -- --

±×·±µ¥ °Ë»öÀÌ µÇÁö ¾Ê½À´Ï´Ù.

17,18¹ø Æ÷Æ®¸¦ ÀÌ¿ëÇصµ, 19, 20¹ø Æ÷Æ®¸¦ ÀÌ¿ëÇصµ ¸¶Âù°¡Áö ÀÔ´Ï´Ù.

 

root@ubuntu-armhf:~# echo sht15 0x40 > /sys/class/i2c-adapter/i2c-0/new_device
root@ubuntu-armhf:~# echo sht15 0x40 > /sys/class/i2c-adapter/i2c-1/new_device

¾Æ¹«·± ¹ÝÀÀÀÌ ¾ø½À´Ï´Ù ¤Ð.¤Ð

 

Ȥ½Ã ¼¾¼­°¡ ºÒ·®Àΰ¡ ½Í¾î ¼¾¼­¸¦ ¾ÆµÎÀ̳뿡 ºÙ¿©¼­ ¶óÀ̺귯¸® ·ÎµåÇؼ­ Å×½ºÆ® ÇØ º¸¾Ò½À´Ï´Ù.

°ªÀÌ Á¤»óÀûÀ¸·Î ³ª¿À´Â °ÍÀ» È®ÀÎÇÏ¿´½À´Ï´Ù.

 

¼¾¼­¿¡´Â ¹®Á¦°¡ ¾øÀ¸³ª ¸®´ª½º¿¡¼­ ÀνÄÀ» ¸øÇϹǷÎ, ´Ù¸¥ ¹æ¹ýµéÀ» ã¾ÆºÁ¾ß ÇÒ °Í °°½À´Ï´Ù.

Ä¿³Î µå¶óÀ̹ö¸¦ »ç¿ëÇÏ´Â ¹æ¹ý¿¡ ´ëÇؼ­µµ ´õ ¾Ë¾ÆºÁ¾ß ÇÒ °Í °°½À´Ï´Ù.

 

¿©±âÀú±â ã¾Æº¸´Ï ÇØ´ç ¼¾¼­°¡ I2C Ç¥ÁØ ÇÁ·ÎÅäÄÝÀ» »ç¿ëÇÏ´Â °ÍÀÌ ¾Æ´Ï¶ó I2C¿¡¼­ º¯ÇüµÈ µ¶ÀÚÀûÀÎ ÇÁ·ÎÅäÄÝÀ» »ç¿ëÇÑ´Ù´Â ±Ûµµ º¸ÀÌ°í ¿©·¯°¡Áö ¹®Á¦Á¡ÀÌ ³²¾Æ ÀÖ´Â °Í °°½À´Ï´Ù.

 

¸®´ª½º Ãʺ¸, Çϵå¿þ¾î Ãʺ¸°¡ ÇÁ·ÎÁ§Æ®¸¦ ÁøÇàÇÏ·Á´Ï ¾î·Á¿î ºÎºÐµéÀÌ ¸¹³×¿ä..

±â°£³»¿¡ ÇÁ·ÎÁ§Æ®¸¦ ¿Ï¼öÇÏÁö ¸øÇÒÁöµµ ¸ð¸£Áö¸¸, ±×·¡µµ °è¼Ó ¹æ¹ýÀ» ã¾Æº¸°í ÁøÇà ÇØ º¸°Ú½À´Ï´Ù.

 

 

º» Á¦Ç°Àº ICbanQ¿¡¼­ ÈÄ¿øÇÏ°í ICbanQ ¹«»ó üÇè´Ü 10±â È°µ¿ÀÇ ÀÏȯÀ¸·Î üÇè Á¦Ç°À» Á¦°ø ¹Þ¾Æ ÀÛ¼ºµÇ¾ú½À´Ï´Ù.

 

0
ÃßõÇϱ⠴ٸ¥ÀÇ°ß 0
|
°øÀ¯¹öÆ°
  • ¾Ë¸² ¿å¼³, »óó ÁÙ ¼ö ÀÖ´Â ¾ÇÇÃÀº »ï°¡ÁÖ¼¼¿ä.
©¹æ »çÁø  
¡â ÀÌÀü±Û¡ä ´ÙÀ½±Û