스터디/IoT

헥시웨어 스펙과 Mac 개발환경 설정

Dalmangyi 2019. 10. 18.

지난글 : https://dalgonakit.tistory.com/128

 

Hexiwear 헥시웨어 개봉기

지난 게시글 : https://dalgonakit.tistory.com/122 워치용 웨어러블 개발 키트 조사 (Watch Wearable Dev Kit) 검색해도 잘 나오질 않아서 이것저것 정리해 볼까 합니다 1. Ingenic Newton2 Plus (인게닉 뉴톤2..

dalgonakit.tistory.com

 

 

 

 

 

헥시웨어 스펙

먼저 어떠한 기능들이 제공되는지 알아봅시다 

https://www.hexiwear.com/

 

null

ARM Cortex-M4와 BLE 센서

3축센서, 심박도 센서, 온습도 센서, 1.1인치 OLED

190mAh Li-Po 배터리, 터치 센서 까지! 

정말 다양한 센서가 한 군데 있네요.

 

 

null

내부 모듈 연결 다이어그램을 보니 NXP 라는 녀석이 많이 보이네요  

 

 

 

 

 

 

 

 

 

 

Hexiwear 개발 환경 구축하기 (1)

외국 서버에서 파일을 받아올 일이 많아서 그런지 개발환경 구축하는 순수 시간만해도 많이 소요됩니다

 

 

 

1. python3 설치

https://dejavuqa.tistory.com/60

 

Mac에 Python 3.x 설치 (package)

Mac에는 기본으로 Python 2.7.10이 설치되어 있습니다. 터미널을 열어 python 버전을 확인해 보겠습니다. $ python --version Python 2.7.10 Python 3.x를 사용하고 싶다면 Python.org에서 다운받습니다. Python..

dejavuqa.tistory.com

 

2. brew 설치

https://brew.sh/index_ko

 

Homebrew

The missing package manager for macOS (or Linux).

brew.sh

 

3.wget 설치

brew install wget

 

 

4. 각종 Dependencies 설치

brew install cmake ninja gperf ccache dfu-util qemu dtc python3

 

 

 

5. west (Zephyr's meta-tool) 설치

pip3 install -U west

 

 

6. Zephyr Repositories Clone

west init zephyrproject
cd zephyrproject
west update

 

 

7. Python Dependencies 설치

pip3 install -r zephyr/scripts/requirements.txt

 

 

8. Zephyr Environment Scripts 적용

source zephyr-env.sh

 

 

8. 환경 확인

env | grep ZEPHYR

 

9. Zephyr SDK 설치

$ cd ~
$ wget https://github.com/zephyrproject-rtos/sdk-ng/releases/download/v0.10.3/zephyr-sdk-0.10.3-setup.run
$ chmod +x zephyr-sdk-0.10.3-setup.run
$ ./zephyr-sdk-0.10.3-setup.run -- -d ~/zephyr-sdk-0.10.3

mac 안된다는디......?

 

 

 

 

10. 3rd Party Toolchains - GNU ARM Embedded 다운로드

https://developer.arm.com/tools-and-software/open-source-software/developer-tools/gnu-toolchain/gnu-rm/downloads

접속 후, Mac OS X 64-bit 다운로드

 

11. 툴체인 압축해제

$ tar -xvzf 파일명

 

12. 툴체인 환경변수 등록

export ZEPHYR_TOOLCHAIN_VARIANT=gnuarmemb
export GNUARMEMB_TOOLCHAIN_PATH=설치위치

 

 

 

 

 

 

 

빌드

cd zephyr
west build -b hexiwear_k64 samples/hello_world

(참고: https://docs.zephyrproject.org/latest/guides/west/build-flash-debug.html)

 

 

 

 

 

 

 

 

Mac Ports설치?

macOS와 다윈 운영 체제의 소프트웨어 설치를 단순화시켜 주는 패키지 관리자

 

 

1. Xcode와 Xcode Command Line Tools 설치

2. Xcode 라이센스 동의 

$ sudo xcodebuild -license

3. 운영체제 버전에 맞는 MacPorts설치

https://github.com/macports/macports-base/releases/tag/v2.6.2

4.명령어 확인

$port
exit

 

5. QEMU 설치

$sudo port install qemu

 

6. QEMU 설치확인

$ls /opt/local/bin | grep "qemu"

qemu-edid
qemu-ga
qemu-img
qemu-io
qemu-nbd
qemu-system-i386
qemu-system-x86_64

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

댓글