1 Star 0 Fork 0

hanhai-modules/hrt-spi-server

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
克隆/下载
main.c 1014 Bytes
一键复制 编辑 原始数据 按行查看 历史
ruiqiang.kang 提交于 2024-07-30 16:55 . feat: spi opensourse fix #92326
/*
*Copyright (c) 2024 Black Sesame Technologies
*
*Licensed under the Apache License, Version 2.0 (the "License");
*you may not use this file except in compliance with the License.
*You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
*Unless required by applicable law or agreed to in writing, software
*distributed under the License is distributed on an "AS IS" BASIS,
*WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
*See the License for the specific language governing permissions and
*limitations under the License.
*/
#include <hw/spi_server.h>
#include <stdio.h>
#include <sys/mman.h>
#include <stdlib.h>
#include <unistd.h>
extern void spi_main_init(char* name, uint32_t paddr, uint32_t bus, int irq);
int main(int argc, char *argv[])
{
spi_main_init(argv[0], (uint32_t)strtol( argv[1], NULL, 16), (uint32_t)strtol( argv[2], NULL, 16), strtol( argv[3], NULL, 10));
while(1){
int ret = usleep(1000000);
}
return 0;
}
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/hanhai-modules/hrt-spi-server.git
git@gitee.com:hanhai-modules/hrt-spi-server.git
hanhai-modules
hrt-spi-server
hrt-spi-server
release-open-source

搜索帮助