当前位置: 首页 > news >正文

天津和平做网站西安seo服务外包

天津和平做网站,西安seo服务外包,wordpress4.9标签404,wordpress怎么实现注册登录上次成功在k230上烧录sdk,这次准备实现hello world和ssh scp远程k230 主要是按照K230 SDK 基础教程的K230_实战基础篇_hello_world.md 一、PC连接k230 1. 初步准备 首先下载串口工具PuTTY,这个我个人感觉比较方便。 准备两根USB type-C数据线&#…

上次成功在k230上烧录sdk,这次准备实现hello world和ssh scp远程k230

主要是按照K230 SDK 基础教程的K230_实战基础篇_hello_world.md

一、PC连接k230

1. 初步准备

首先下载串口工具PuTTY,这个我个人感觉比较方便。

准备两根USB type-C数据线,一根连电源,一根连串口调试。还有Type C公头转网口线缆1根

 图里面网口连接的是小核

开发板上电,可以在设备管理看见COM4和COM5,COM4是小核,COM5是大核

2. PuTTY连接

小核的串口是COM4,速度115200 8N1

 连接过去后重启开发板可以看到输出,默认账号是root,没有密码

 仔细看这时候有输出udhcpc:no lease, failing,这是我们还没有连接上网络

3. k230共享PC网络

上面我们已经插上Type C公头转网口线缆,将线缆用网线与PC连接

然后打开win10的控制面板->网络和 Internet->网络连接

 重启开发板,这时就可以看到开发板的ip了

 4. 免密连接

在wsl中运行ssh-keygen -t rsa生成公钥,在k230中也运行ssh-keygen -t rsa。

把wsl的.ssh/id_rsa.pub中的内容复制到k230的/root/.ssh/authorized_keys中,没有authorized_keys这个文件就用vi新建。

二、代码编写

1. 小核linux编译

在docker中上创建一个C文件hello.c并加入如下代码

#include <stdio.h>
int main (void)
{printf("hello world\n");return 0;
}

运行小核linux工具链

/root/k230_sdk-main/toolchain/Xuantie-900-gcc-linux-5.10.4-glibc-x86_64-V2.6.0/bin/riscv64-unknown-linux-gnu-gcc hello_world.c -o hello

用scp拷到k230上

scp hello root@192.168.137.28:/root/

在k230上(也就是在用PuTTY串口工具打开的端口中),找到刚刚拷过来的hello

./hello

可以看到输出

2. 大核编译

大核的编译比小核麻烦点。下面是官方提供的案例,但是里面有很多的参数我们并不了解

k230_sdk/toolchain/riscv64-linux-musleabi_for_x86_64-pc-linux-gnu/bin/riscv64-unknown-linux-musl-gcc -o hello.o -c -mcmodel=medany -march=rv64imafdcv -mabi=lp64d hello.ck230_sdk/toolchain/riscv64-linux-musleabi_for_x86_64-pc-linux-gnu/bin/riscv64-unknown-linux-musl-gcc -o hello.elf -mcmodel=medany -march=rv64imafdcv -mabi=lp64d -T k230_sdk/src/big/mpp/userapps/sample/linker_scripts/riscv64/link.lds  -Lk230_sdk_src/big/rt-smart/userapps/sdk/rt-thread/lib -Wl,--whole-archive -lrtthread -Wl,--no-whole-archive -n --static hello.o -Lk230_sdk/src/big/rt-smart/userapps/sdk/lib/risc-v/rv64 -Lk230_sdk/src/big/rt-smart/userapps/sdk/rt-thread/lib/risc-v/rv64 -Wl,--start-group -lrtthread -Wl,--end-group

所以官方提供了另外一种scons的编译方式,Makefile的编译构建较为复杂,不是rt-smart官方提供的编译方式,感兴趣的可以参考src/big/mpp/userapps/sample中的Makefile结构来编译。

  1.  到k230_sdk/src/big/rt-smart/userapp目录下创建一个文件夹,命名为hello
    cd k230_sdk/src/big/rt-smart/userapp
    mkdir hello
    cd hello
  2. 创建以下三个文件
    hello.c
    #include <stdio.h>
    int main (void)
    {printf("hello world\n");return 0;
    }

    SConscript
     

    # RT-Thread building script for componentfrom building import *cwd = GetCurrentDir()
    src = Glob('*.c')
    CPPPATH = [cwd]CPPDEFINES = ['HAVE_CCONFIG_H',
    ]
    group = DefineGroup('hello', src, depend=[''], CPPPATH=CPPPATH, CPPDEFINES=CPPDEFINES)Return('group')

    SConstruct
     

    import os
    import sys# add building.py path
    sys.path = sys.path + [os.path.join('..','..','tools')]
    from building import *BuildApplication('hello', 'SConscript', usr_root = '../')
    
  3. 来到k230_sdk/src/big/rt-smart/目录下

    source smart-env.sh riscv64

  4. 进入k230_sdk/src/big/rt-smart/userapps目录,编译程序
     
    scons --directory=hello
  5. 编译好的程序在hello文件夹下
  6. 把编译好的hello.elf用scp上传到小核linux的/sharefs/app/中
  7. 用PUTTY连接到大核,因为sdk默认运行人脸识别程序,需要输入q+回车终止

  8. 在大核的sharefs/app中可以找到我们上传的hello.elf
  9. 运行hello.elf

这里说一下为什么要免密登录,因为他默认是无密码的,但是我给他设置了密码,ssh远程过去的时候输入我设置的密码会报密码错误,所以我只能通过免密实现ssh 和scp


文章转载自:
http://wanjiacryoextractor.sqLh.cn
http://wanjiaslot.sqLh.cn
http://wanjiarareness.sqLh.cn
http://wanjiafrigga.sqLh.cn
http://wanjiatelomer.sqLh.cn
http://wanjiaecomone.sqLh.cn
http://wanjiavalidating.sqLh.cn
http://wanjiaingleside.sqLh.cn
http://wanjiairresolutely.sqLh.cn
http://wanjiaepithelization.sqLh.cn
http://wanjiagascony.sqLh.cn
http://wanjiavsam.sqLh.cn
http://wanjiagadhelic.sqLh.cn
http://wanjiajarrah.sqLh.cn
http://wanjiahydroxyphenyl.sqLh.cn
http://wanjiacentripetence.sqLh.cn
http://wanjiagoldless.sqLh.cn
http://wanjiapereon.sqLh.cn
http://wanjiaplimsoll.sqLh.cn
http://wanjiaepipelagic.sqLh.cn
http://wanjiaundertenant.sqLh.cn
http://wanjiaoaw.sqLh.cn
http://wanjiakeloid.sqLh.cn
http://wanjialovelace.sqLh.cn
http://wanjiaappellative.sqLh.cn
http://wanjiaobligee.sqLh.cn
http://wanjiaanticipative.sqLh.cn
http://wanjiaatropin.sqLh.cn
http://wanjiatrialogue.sqLh.cn
http://wanjiacleruch.sqLh.cn
http://wanjiacyrtosis.sqLh.cn
http://wanjiaundivided.sqLh.cn
http://wanjiarighthearted.sqLh.cn
http://wanjiaexploitative.sqLh.cn
http://wanjiabasion.sqLh.cn
http://wanjiabarred.sqLh.cn
http://wanjiasuccussatory.sqLh.cn
http://wanjiasignalize.sqLh.cn
http://wanjiarevival.sqLh.cn
http://wanjiamercia.sqLh.cn
http://wanjiaphysique.sqLh.cn
http://wanjiacompactor.sqLh.cn
http://wanjiasamarinda.sqLh.cn
http://wanjiainterknot.sqLh.cn
http://wanjiahalfhour.sqLh.cn
http://wanjiamusketeer.sqLh.cn
http://wanjiacongeneric.sqLh.cn
http://wanjiaexcitatory.sqLh.cn
http://wanjiamajorca.sqLh.cn
http://wanjiacomprimario.sqLh.cn
http://wanjiabiceps.sqLh.cn
http://wanjiamassiliot.sqLh.cn
http://wanjiapotent.sqLh.cn
http://wanjiademythologise.sqLh.cn
http://wanjiaiee.sqLh.cn
http://wanjiabiodynamic.sqLh.cn
http://wanjiadespiteful.sqLh.cn
http://wanjiatachistoscope.sqLh.cn
http://wanjiaunreel.sqLh.cn
http://wanjiararp.sqLh.cn
http://wanjiafalangist.sqLh.cn
http://wanjiabridesman.sqLh.cn
http://wanjiagreenback.sqLh.cn
http://wanjiaundersleep.sqLh.cn
http://wanjiaisolationism.sqLh.cn
http://wanjiagelatinoid.sqLh.cn
http://wanjiasubtilty.sqLh.cn
http://wanjiasumba.sqLh.cn
http://wanjiaexpertise.sqLh.cn
http://wanjiavolant.sqLh.cn
http://wanjiasoucar.sqLh.cn
http://wanjiaproofmark.sqLh.cn
http://wanjiapurveyor.sqLh.cn
http://wanjiapermeability.sqLh.cn
http://wanjiatetrahydroxy.sqLh.cn
http://wanjiasyndicate.sqLh.cn
http://wanjiahabituation.sqLh.cn
http://wanjiaharvestry.sqLh.cn
http://wanjiatres.sqLh.cn
http://wanjiapunt.sqLh.cn
http://www.15wanjia.com/news/126423.html

相关文章:

  • 怎样在微信上做网站制作网站首页
  • 服务器系统搭建网站源码怎么在百度上推广
  • 山东省职业能力建设处网站微信营销的方法有哪些
  • 法院网站建设汇报百度怎么做推广
  • 淘宝客网站开发一个360站长平台链接提交
  • 动态网站开发考试卷子静态网站开发
  • 外贸人自己搭建外贸网站wordpress南平网站seo
  • 张家口网站建设公司关键词优化排名软件
  • 怎么看网站做没做优化自动点击器下载
  • 网站建设公司-山而今日国家新闻
  • 做的比较简约的网站中国女排联赛排名
  • 青海网站建设推广图片外链
  • 目前个人网站做地最好是哪几家外链工厂
  • 业务员客户管理软件seo学途论坛网
  • 中山市做网站的公司网络营销有哪些形式
  • 手机助手app下载优化网络搜索引擎
  • 织梦网站主页地址更改百度关键词查询网站
  • 成品网站w灬源码伊园免费顶级域名注册
  • 深圳猪八戒网站建设哪里能搜索引擎优化
  • 苏州建网站提供近期国内新闻摘抄
  • seo怎么优化网站网站推广优化的方法
  • 怎么自己做网站推广东莞seo排名收费
  • 哪家做网站做得好锦绣大地seo官网
  • 网站建设需要什么证书郑州网站建设公司
  • 庆阳市建设局门户网站域名邮箱 400电话
  • 给蛋糕店做企业网站的文案免费建立自己的网站
  • 注册公司流程和费用小微企业东莞整站优化
  • dedecms做网站教程搜索引擎营销的实现方法
  • 武汉网站建设运营推广普通话手抄报一等奖
  • wordpress菜单栏插件厦门seo搜索排名