Other

项目介绍

piconomix/px-fwlib 是一个托管在 GitHub 上的开源项目,主要使用 C 编写,采用 Other 许可证,目前获得 289 个 Star、26 次 Fork。

仓库全名
piconomix/px-fwlib
开源许可证
Other
Star 数
289
Fork 数
26
未关闭 Issue
2

README 摘要

:warning: Project name change notice Apologies for any inconvenience caused. The Git project name has been shortened from "piconomix-fwlib" to "px-fwlib". Here is the Git command to change your cloned repo's URL: git remote set-url origin https://github.com/piconomix/px-fwlib.git The online documentation URL has changed to: https://piconomix.com/px-fwlib/index.html PX-HER0 Board # STM32L072 PX-HER0 Board now in…

完整内容见 GitHub 原始 README 或本页 。

常见问题

px-fwlib 用什么语言开发?

主要使用 C 编写,采用 Other 许可证,目前有 289 个 Star。

px-fwlib 可以免费商用吗?

仓库标注的许可证为 Other,商用前请先阅读仓库 LICENSE 文件确认授权范围。

如何获取 px-fwlib 的源码?

可以直接克隆仓库:git clone https://github.com/piconomix/px-fwlib.git,默认分支为 master;安装与运行步骤见仓库 README。

px-fwlib 最近还在维护吗?

仓库最近一次更新为 2 周前,当前有 2 个未关闭 Issue;Star 数为 289,可作为社区活跃度的参考。

关于

GitHub 原始描述(英文)

open source bare-metal C firmware and documentation for microcontrollers

描述取自 GitHub 官方 API,保持仓库作者书写的原文。

简要分析

热度分
355
价值分
182
活跃状态
活跃

语言占比

Assembly
Batchfile
C
C++
CSS
Go Template
HTML
Linker Script
Makefile
Python
Shell

Release

README

MIT license

:warning: Project name change notice

Apologies for any inconvenience caused. The Git project name has been shortened from “piconomix-fwlib” to “px-fwlib”. Here is the Git command to change your cloned repo’s URL:

git remote set-url origin https://github.com/piconomix/px-fwlib.git

The online documentation URL has changed to:

https://piconomix.com/px-fwlib/index.html

PX-HER0 Board

STM32L072 PX-HER0 Board now in stock at Crowd Supply! Click HERE

Introduction

https://piconomix.com

px-fwlib is a collection of open source C firmware and documentation for microcontrollers to develop portable bare-metal code that is vendor and architecture neutral (or easier to reuse).

It is tough to find the best compromise between lean 8-bit targets, middle-of-the-road 16-bit targets, and resource rich 32-bit targets, but this cross-platform library aims to provide a good foundation before you are forced to add target specific code and getting locked in.

Click HERE to view the complete online documentation.

Click HERE to download releases of the open source library (source code and offline documentation).

Goals

  • Teach good firmware development practices to guide the next generation of professional embedded engineers.
  • Share source code, knowledge and expertise with our global community of engineers, scientists and enthusiasts.
  • Publish concise quick start guides and tutorials to reduce the learning curve of new microcontrollers.
  • Provide a standard framework and drivers for rapid code development.
  • Minimize porting by providing unified peripheral driver APIs (to maximize device driver reuse).

My sincere hope is that seasoned veterans will pitch in and share their years of experience to mentor the future generation and raise the bar in terms of quality and quantity.

Example

Included with the library is a CLI (Command Line Interpreter) executing on an Arduino Uno R3 that creates an interactive shell environment so that you can experiment with GPIO, ADC, I2C and SPI using only an ANSI/VT100 terminal emulator (for example Tera Term).

Electrodragon BMP280 breakout board connected to I2C

Connect your board, fire up the CLI and verify that it works:

CLI Exlorer executing on an Arduino Uno R3

The BMP280 is found at 7-bit slave address 0x76. The chip identification register value for the BMP280 is 0x58. This confirms that you are able to write to and read from the I2C slave.

After verification, it is easy to accomplish the same in C using the library:

#include "px_i2c.h"
#include "px_board.h"

// Bosch BMP280 I2C Slave Address
#define I2C_SLA_ADR   0x76

// Create I2C Slave handle object
px_i2c_handle_t px_i2c_handle;

int main(void)
{
    uint8_t data[1];

    // Initialise board
    px_board_init();
    // Initialise I2C driver
    px_i2c_init();
    // Open handle to I2C slave device
    px_i2c_open(&px_i2c_handle, PX_I2C_NR_0, I2C_SLA_ADR);

    // START I2C write transaction and write register address
    data[0] = 0xd0;
    px_i2c_wr(&px_i2c_handle, data, 1, PX_I2C_FLAG_START_AND_END);
    // REPEATED START I2C read transaction and read register value
    px_i2c_rd(&px_i2c_handle, data, 1, PX_I2C_FLAG_REP_START_AND_STOP);

    // Close I2C Handle
    px_i2c_close(&px_i2c_handle);
}

License

MIT license

The MIT license has been selected to grant freedom for both open source and commercial (closed source) projects and to nurture future growth of the library. Please see the LICENSE.

Questions or Feedback?

Questions or feedback (positive and negative) is great and will help to improve the library:

Feedback

Methods of communication:

Support

A significant amount of time has been invested to craft and refine this free open source library. If you saved development time, acquired a new skill, or advanced your career, you are welcome to support this project with a visit to the shop.

Shop Click HERE to visit the shop

评论

暂无评论