zoukankan      html  css  js  c++  java
  • Yocto开发笔记之《应用程序架构》(QQ交流群:519230208)

    QQ群:519230208,为避免广告骚扰,申请时请注明 “开发者” 字样

    ========================================================

    Eclipse IDE 官方使用文档:
    http://help.eclipse.org/juno/index.jsp?topic=%2Forg.eclipse.cdt.doc.user%2Ftasks%2Fcdt_t_proj_paths.htm

    伪代码 ——>>>>>>>>>>>>>>>>

     ===================================

    main()


    uart.open

    uart.setting

    net.open

    net.setting

    can.open

    can.setting

    ----------------------------

    uart.read.thread.start ——> *uart.read.fun

    net.read.thread.start ——> *net.read.fun

    can.read.thead.start ——> *can.read.fun

    ----------------------------

    uart.read.thread.stop

    net.read.thread.stop

    can.read.thread.stop

    ----------------------------

    uart.close

    net.close

    can.close

    ======================================

    new thread

    *uart.read.fun;  *net.read.fun; *can.read.fun;

    while(1) {

      read.data

      judge.data

      send.data ——> *data.handle.fun (msg?  new thread?)

    }

    ======================================

    synchronized fun

    Used by *data.handle.fun:

    *uart.write.fun 

    *net.write.fun 

    *can.write.fun 

    ======================================

    ======================================

    pthread_create error

    project properitys --> Autotools --> Configure Settings -->

    Command:

    CFLAGS=" -g -O0 -lpthread --sysroot=/home/summer/test-yocto/qemuarm" CXXFLAGS=" -g -O0  --sysroot=/home/summer/test-yocto/qemuarm" LDFLAGS=" --sysroot=/home/summer/test-yocto/qemuarm" CPPFLAGS=" --sysroot=/home/summer/test-yocto/qemuarm" configure --with-libtool-sysroot=/home/summer/test-yocto/qemuarm

    All Options:

     --host=arm-poky-linux-gnueabi --build=x86_64-linux --target=arm-poky-linux-gnueabi 

    ======================================

    Yocto Application Makefile

    CC=i586-poky-linux-gcc -m32 -march=i586 --sysroot=/opt/poky/1.8/sysroots/i586-poky-linux

    LD=i586-poky-linux-ld --sysroot=/opt/poky/1.8/sysroots/i586-poky-linux

    CFLAGS=-O2 -pipe -g -feliminate-unused-debug-types

    CXXFLAGS=-O2 -pipe -g -feliminate-unused-debug-types

    ======================================

     Create New Project: Eclipse with yocto plugin

    To create a project based on a Yocto template and then display the source code, follow these steps:

    1. Select "Project" from the "File -> New" menu.

    2. Double click CC++.

    3. Double click C Project to create the project.

    4. Expand Yocto Project ADT Autotools Project.

    5. Select Hello World ANSI C Autotools Project. This is an Autotools-based project based on a Yocto template.

    6. Put a name in the Project name: field. Do not use hyphens as part of the name.

    7. Click "Next".

    8. Add information in the Author and Copyright notice fields.

    9. Be sure the License field is correct.

    10. Click "Finish".

    11. If the "open perspective" prompt appears, click "Yes" so that you in the C/C++ perspective.

    12. The left-hand navigation pane shows your project. You can display your source by double clicking the project's source file.

  • 相关阅读:
    [原创]软件性能测试培训
    100w条记录分页,可以有多快?—— DataReader分页与SQL语句分页的对比测试(在线演示)
    【自然框架】注册会员活动——第一份代码的修改建议(第一版)
    加班有几种情况?兼谈讨论的方式。
    衔着树枝飞跃太平洋的傻鸟!(童话版)
    参加活动的好处。
    【自然框架】开源社区活动,会员注册的第一份代码!
    【自然框架】数据访问之精雕细琢(一)存储过程的参数
    自然框架开发系列(一):自然框架 和 AgileEAS.NET 合作,开发b/s的药店系统!
    自然框架开源社区的第一次活动——实现会员注册
  • 原文地址:https://www.cnblogs.com/alanfang/p/5034579.html
Copyright © 2011-2022 走看看