순서는 아래와 같다.


1. fidl 및 fdepl 작성하기

2. Dbus , Someip 코드 생성하기 


CommonAPI 생성 디렉토리로 이동



DBus 코드 생성하기

 1) memory.fidl 코드 생성하기

./commonapi-generator-linux-x86_64 -sk /home/kj/Desktop/ivis_memory/fidl/memory.fidl

 2) 생성된 코드 확인

 다음 경로에 소스가 생성된다.  src-gen/v1/genivi/ivis/setting/


Someip 코드 생성하기



'Embedded > CommonAPI' 카테고리의 다른 글

[CommonAPISomeIP] 작성하기  (0) 2019.01.04
[GENIVI] ARA integration project  (0) 2019.01.04
[Franca] 작성하고 코드 생성하기  (0) 2019.01.03
[CommonAPI C++] D-Bus binding  (0) 2019.01.03
[CommonAPI] tool 설치 작성중  (0) 2019.01.02

QString 을 이용하여 문자열 합치기


숫자앞에 0채우기


int number= 11;

QString string;

string = QString::number(number).rightJustified(5,'0');



결과 00011 

'Qt > 활용' 카테고리의 다른 글

[Qt] Connect  (0) 2019.10.15
라즈베리파이4 구매  (0) 2019.07.01
특정 폴더 제외하고 검색하기  (0) 2019.07.01
[Ubuntu16.04] 한글설정하기  (0) 2018.12.21
[Linux] Monitoring Qt  (0) 2018.12.14


Franca to ARA interface integration and demo code : https://github.com/GENIVI/franca_ara_integration


ARA:COM XML 포맺과 Franca IDL 과의 통신을 보여준다.


소스코드 다운로드 : https://github.com/GENIVI/franca_ara_integration.git



Yocto 관련부분 정리

  GDP 메타데이터 다운로드 

  git clone https://github.com/GENIVI/genivi-dev-platform.git

 cd genivi-dev-platform


 Franca - ARA 다운로드

 git clone git@github.com:GENIVI/franca_ara_integration.git


 GDP 빌드 셋업

 source .init.sh rcar-m3xx~


 meta-franca-ara 레이어 추가하기

 bitbake-layers add-layer ../franca_ara_integration/yocto/meta-franca-ara


 conf/local.conf 파일에 인스톨 추가하기

 IMAGE_INSTALL_append = " franca-ara"


 빌드시작

 bitbake genivi-dev-platform


 빌드관련 정보들

 video.tar 이미지관련파일들 /usr/local/share/franca-ara/images 폴더에 사진이미지를 넣어둔다.

소스코드들


컴파일 옵션

cd tests/testprograms/capi_server


$CXX -o capi_server -std=c++14 -I src-gen \ main.cpp src-gen/v1/genivi/aasr/showcase/*.cpp \ `pkg-config --cflags --libs CommonAPI-SomeIP` -lpthread

g++ -o capi_server -std=c++14 -I src-gen main.cpp src-gen/v1/genivi/aasr/showcase/*.cpp `pkg-config --cflags --libs CommonAPI-SomeIP` -lpthread

 capi_server  <-- 파일 생성됨


데모 테스트 


capi_server 실행

franca_ara_integration 에서 빌드한 franca-ara 실행



'Embedded > CommonAPI' 카테고리의 다른 글

[CommonAPISomeIP] 작성하기  (0) 2019.01.04
[Memory-1] fidl 작성하기 -작성중  (0) 2019.01.04
[Franca] 작성하고 코드 생성하기  (0) 2019.01.03
[CommonAPI C++] D-Bus binding  (0) 2019.01.03
[CommonAPI] tool 설치 작성중  (0) 2019.01.02


https://github.com/GENIVI/capicxx-wamp-runtime


WAMP


설치방법 

* Install build tools and Boost libs: sudo apt install libbz2-dev libssl-dev cmake libboost-dev libboost-system-dev libboost-thread-dev libboost-log-dev



일단조사해보면 

WAMP 란 Window + Apache + MySql +PHP 약자 

'Qt > Network' 카테고리의 다른 글

Wifi  (0) 2018.12.20
[QLocalSocket] 도매인 소켓이란  (0) 2018.12.18
[Qt] 4K download 소스  (0) 2018.12.14

이전에서 CommonAPI 관련 라이브러리를 설치 완료하였다.



이번에는 Franca 형식으로 인터페이스를 작성하고 Dbus , Someip 코드로 생성해보도록 하겠다.


원문링크

https://github.com/GENIVI/capicxx-someip-tools/wiki/CommonAPI-C---SomeIP-in-10-minutes#step4



1. 폴더를 생성후 HelloWorld.fidl 을 작성한다.


다음 명령을 통하여 파일을 검색한다.

$ find ./ -name "CommonAPI-SOMEIP_deployment_spec.fdepl"



./capicxx-someip-tools/org.genivi.commonapi.someip/deployment/CommonAPI-SOMEIP_deployment_spec.fdepl


kj@kj:~/GENIVI/ComAPI_New/tools/test$ mkdir project

kj@kj:~/GENIVI/ComAPI_New/tools/test$ cd project/

kj@kj:~/GENIVI/ComAPI_New/tools/test/project$ ls

kj@kj:~/GENIVI/ComAPI_New/tools/test/project$ mkdir fidl

kj@kj:~/GENIVI/ComAPI_New/tools/test/project$ cd fidl/

vim HelloWorld.fidl


package commonapi


interface HelloWorld {

  version {major 1 minor 0}

  method sayHello {

    in {

      String name

    }

    out {

      String message

    }

  }

}






2. 코드 생성하기 

제너레이더 파일을 다운받는다.


툴을 다운받아 두개의 폴더에 각각 압축을 해제하였다.


dbus_gen  someip_gen


http://genivi.github.io/capicxx-dbus-tools/

http://genivi.github.io/capicxx-someip-tools/


생성되는 폴더명은 v[M버전]/ package 내임 . 별로 폴더생성 과 같다.

dbus_gen 폴더로 이동 후 zip 파일을 압축해제


 ./commonapi-dbus-generator-linux-x86_64 ../fidl/HelloWorld.fidl 


Executing CommonAPI DBus Code Generation...


Using Franca Version 0.9.1.201412191134

Generating code for /home/kj/GENIVI/ComAPI_New/tools/test/project/dbus_gen/../fidl/HelloWorld.fidl 




3. 결과물 확인




src_gen 폴데에 해당 소스파일들이 생성된다.

src-gen/v1/commonapi


[FileName]+DBusDeployment.cpp

[FileName]+DBusDeployment.hpp

[FileName]+DBusDBusProxy.cpp

[FileName]+DBusDBusProxy.hpp

[FileName]+DBusDBusStubAdapter.cpp

[FileName]+DBusDBusStubAdapter.hpp



Deployment , Proxy, StubAdapter 라는 파일이 생성된다.



다음으로 someip  코드도 작성하여 생성해보도록 한다.


원문 : https://github.com/GENIVI/capicxx-someip-tools/wiki/CommonAPI-C---SomeIP-in-10-minutes


1. 파일 생성 

vim HelloWorld.fdepl

import "platform:/plugin/org.genivi.commonapi.someip/deployment/CommonAPI-SOMEIP_deployment_spec.fdepl"

import "HelloWorld.fidl"


define org.genivi.commonapi.someip.deployment for interface commonapi.HelloWorld {

        SomeIpServiceID = 4660


        method sayHello {

                SomeIpMethodID = 123

        }

}


define org.genivi.commonapi.someip.deployment for provider MyService {

        instance commonapi.HelloWorld {

                InstanceId = "test"

                SomeIpInstanceID = 22136

        }

}


2. someip_gen 

 

제너레이터 폴더로 이동후 코드 생성하기


./commonapi-someip-generator-linux-x86_64 ../fidl/HelloWorld.fdepl 




3. 생성된 파일확인

  src-gen 폴더에 생성된다.


[FileName]+SomeIPDeployment.cpp

[FileName]+SomeIPDeployment.hpp

[FileName]+SomeIPDBusProxy.cpp

[FileName]+SomeIPDBusProxy.hpp

[FileName]+SomeIPDBusStubAdapter.cpp

[FileName]+SomeIPDBusStubAdapter.hpp 


파일이 생성된다. 




/commonapi-generator-linux-x86_64 를 사용하여 코드생성시에 옵션이 존재한다.

-sk 옵션

 -sk,--skel <arg>                   Generate skeleton code. The optional argument specifies the postfix. 

Without argument, the postfix is 'default'

 






생성된 코드를 활용하여 어플리케이션 코드 작성은 다음에 정리 

'Embedded > CommonAPI' 카테고리의 다른 글

[Memory-1] fidl 작성하기 -작성중  (0) 2019.01.04
[GENIVI] ARA integration project  (0) 2019.01.04
[CommonAPI C++] D-Bus binding  (0) 2019.01.03
[CommonAPI] tool 설치 작성중  (0) 2019.01.02
[Dbus] 사용하기  (0) 2018.12.28


http://genivi.github.io/capicxx-dbus-tools/


D-bus를  위한 CommonAPI C++


CommonAPI C++ 은 내부 프로세스간 통신을 하기위한 C++ 프레임워크이다. high-level 의 C++  API 로 구성되어 있으며 D-Bus 와 같은 다양한 IPC 메커니즘에서 사용할 수 있다.



자세한 사항은  http://genivi.github.io/capicxx-core-tools/ 를 참고


CommonAPI C++ D-Bus 바인딩은 표준 D-Bus 라이이브러리를 기반으로 하지만 런타임 코드와 함께 게시되는 libdbus 패치가 필요하다.


기본 기능

 D-Bus 메시지의 고성능 직렬화



링크 


CommonAPI D-Bus C++ User Guide


CommonAPIDBusCppUserGuide.pdf 문서 참고


의존성

 libdbus , CommonAPI , cmake


제한사항

 Dbus 서명의 경우 255자를 넘지 않아야 함



설치시 관련 필요 라이브러리

 DBus 

dbus-1.12.2-r0

dbus-c++ 1_0.9.0

common-api-c++ 3.1.12-r0

common-api-c++-dbus 3.1.12-r0

common-api-c++-someip 3.1.12-r0

vsomeip 2.10.21



관련 소스코드 다운로드


/home/kj/GENIVI/ComAPI_New


$ git clone https://github.com/GENIVI/capicxx-core-runtime.git

$ git clone https://github.com/GENIVI/capicxx-dbus-runtime.git

$ git clone https://github.com/GENIVI/dlt-daemon.git

$ git clone https://github.com/GENIVI/vsomeip.git

$ git clone https://github.com/GENIVI/capicxx-someip-runtime.git


#!/bin/bash

git clone https://github.com/GENIVI/capicxx-core-runtime.git

git clone https://github.com/GENIVI/capicxx-dbus-runtime.git

git clone https://github.com/GENIVI/dlt-daemon.git

git clone https://github.com/GENIVI/vsomeip.git

git clone https://github.com/GENIVI/capicxx-someip-runtime.git


브랜치 변경



현재 우분투의 dbus 버전 확인

$ dpkg -l | grep dbus


$ dpkg -l | grep dbus

dbus                        1.12.2-1ubuntu1                              amd64        simple interprocess messaging system (daemon and utilities)

dbus-user-session  1.12.2-1ubuntu1                              amd64        simple interprocess messaging system (systemd --user integration)


인터넷 검색하여 Ubuntu16.04 dbus download

https://launchpad.net/ubuntu/+source/dbus/1.12.2-1ubuntu1


dbus_1.12.2.orig.tar.gz2.0 MiB272bb5091770b047c8188b926d5e6038fa4fe6745488b2add96b23e2d9a83d88
dbus_1.12.2-1ubuntu1.debian.tar.xz61.0 KiB7c968a77cc7f8512229f190b51a619cf7b5901db0cf43fcae6c367eff1ede78c



두파일을 다운로드 한다.

한폴더에 압축해제

tar xvf dbus_1.12.2-1ubuntu1.debian.tar.xz

tar xvf dbus_1.12.2.orig.tar.gz



debian/patches/ubuntu 폴더의 패치 파일 복사 cp * ../../../dbus-1.12.2/



capicxx-dbus-runtime/src/dbus-patches 폴더안에 패치파일을 dbus 폴더로 복사한다.

소스의 패치적용



dbus-1.12.2 설치하기


./configure --prefix=/opt/Ngenivi --with-system-socket=/run/dbus/system_bus_socket



make -C dbus

make -C dbus install

make install-pkgconfigDATA


  /bin/mkdir -p '/opt/Ngenivi/lib/pkgconfig'

 /usr/bin/install -c -m 644 dbus-1.pc '/opt/Ngenivi/lib/pkgconfig'


환경변수 적용하기

export PKG_CONFIG_PATH=/opt/Ngenivi/lib/pkgconfig:$PKG_CONFIG_PATH

export LD_LIBRARY_PATH=/opt/Ngenivi/lib/:$LD_LIBRARY_PATH



설치시 폴더이동후 build 폴더생성은 생략하도록 한다.

capicxx-core-runtime 설치하기



mkdir build

cd build

cmake -D CMAKE_INSTALL_PREFIX=/opt/Ngenivi ..



capicxx-dbus-runtime 설치하기


mkdir build

cd build

cmake -D CMAKE_INSTALL_PREFIX=/opt/Ngenivi ..


vsomeip 설치 


cmake -D USE_INSTALLED_COMMONAPI=ON -D CMAKE_INSTALL_PREFIX=/opt/Ngenivi/ ..



capicxx-someip-runtime  설치



cmake -D USE_INSTALLED_COMMONAPI=ON -D CMAKE_INSTALL_PREFIX=PREFIX=/opt/Ngenivi/ .. 



dlt-daemon 까지 동일하게 설치



관련 라이브러리 설치완료 

환경변수 파일 생성



소스코드 생성은 다음 포스팅을 참고

2019/01/02 - [Embedded/CommonAPI] - [CommonAPI] tool 설치 작성중



'Embedded > CommonAPI' 카테고리의 다른 글

[GENIVI] ARA integration project  (0) 2019.01.04
[Franca] 작성하고 코드 생성하기  (0) 2019.01.03
[CommonAPI] tool 설치 작성중  (0) 2019.01.02
[Dbus] 사용하기  (0) 2018.12.28
[GENIVI] 개발환경설정  (0) 2018.12.20

https://elinux.org/R-Car/Boards/M3SK#Flashing_firmware


Writing data (Yocto v2.23 or later)
FilenameProgram Top AddressFlash Save AddressDescription
bootparam_sa0.srec0xE63200000x000000Loader(Boot parameter)
bl2-m3ulcb.srec0xE63040000x040000Loader
cert_header_sa6.srec0xE63200000x180000Loader(Certification)
bl31-m3ulcb.srec0x440000000x1C0000ARM Trusted Firmware
tee-m3ulcb.srec0x441000000x200000OP-Tee
u-boot-elf.srec0x500000000x640000U-Boot


'Embedded > Board' 카테고리의 다른 글

[GDP]RCar opencv 설치 및 빌드 SDK 생성  (0) 2019.01.16
[GDP] Rcar-M3 어플리케이션제어  (2) 2019.01.11
휴대폰 정보  (0) 2019.01.02
[GDP] Build Error  (0) 2018.12.28
[GDP] qemu x86_64  (0) 2018.12.28

https://genivi.github.io/capicxx-core-tools/




CommonAPI C++ D-Bus tooling


소스코드 다운로드 : https://github.com/GENIVI/capicxx-dbus-tools.git



 


git clone https://github.com/GENIVI/capicxx-dbus-tools.git

cd capicxx-dbus-tools
cd 

/home/kj/GENIVI/ComAPI_New/tools/capicxx-dbus-tools/org.genivi.commonapi.dbus.verification


mkdir build

cd build




cmake \

-DCOMMONAPI_TOOL_GENERATOR=myworkpath/CommonAPI-Tools/org.genivi.commonapi.core.cli.product ←-

/target/products/org.genivi.commonapi.core.cli.product/linux/gtk/MYARCH/commonapi- ←-

generator-linux-MYARCH \

-DCOMMONAPI_DBUS_TOOL_GENERATOR=myworkpath/CommonAPI-D-Bus-Tools/org.genivi.commonapi.dbus. ←-

cli.product/target/products/org.genivi.commonapi.dbus.cli.product/linux/gtk/MYARCH/ ←-

commonapi-dbus-generator-linux-MYARCH \

-DCommonAPI_DIR=myworkpath/CommonAPI/build \

-DCommonAPI-DBus_DIR=myworkpath/CommonAPI-D-Bus/build \

-DCOMMONAPI_TEST_FIDL_PATH=myworkpath/CommonAPI-Tools/org.genivi.commonapi.core. ←-

verification/fidl ..



https://github.com/GENIVI/capicxx-someip-tools


https://github.com/GENIVI/capicxx-someip-tools.git


커맨드를 잘활용하지 못하는것같아 사용법 부터 정리해야 겟다..


'Embedded > CommonAPI' 카테고리의 다른 글

[GENIVI] ARA integration project  (0) 2019.01.04
[Franca] 작성하고 코드 생성하기  (0) 2019.01.03
[CommonAPI C++] D-Bus binding  (0) 2019.01.03
[Dbus] 사용하기  (0) 2018.12.28
[GENIVI] 개발환경설정  (0) 2018.12.20



vs plugin qt

https://download.qt.io/development_releases/vsaddin/


qt-vsaddin-msvc2017-2.3.0.vsix

qt-vsaddin-msvc2017-2.2.0




관련 설명 포스트 : http://blog.qt.io/blog/2018/10/08/qml-debugging-visual-studio/

 2018.10.08


다음릴리즈 될 Qt Visual Studio Tools, v2.3.0 에서는 QML 어플리케이션을 VS 를 사용하여 디버깅 할 수 있다.

QML 파일에 브레이크 포인터를 추가하여 QML 코드를 실행할 수 있다. 브레이크 모드 일 때 변수와, 그들의 값을 확인 할 수 있다. 

QML 디버그 세션은 C++ 디버그 세션에서 동작한다. 


The QML debug session will run concurrently to the C++ debug session, so it will be possible to set breakpoints and watch variables in both C++ and QML during the same debug run of the application.


이하 생략...


visual Studio .vsix 설치하기 

1. VS 2017 실행


라이센스 만료로 중단..흐..




잡다백수의 낙서장 :http://zabda100su.tistory.com/335?category=747670

    - 정리 및 게임개발 경험



+ Recent posts