Hacktoberfest 2026:メンテナが10月に向けて印を付けた、オープンで初心者向けの issue。 Hacktoberfest の issue を見る

Feature Request: Refactor SPI to allow alternative implementations (e.g., Software SPI)

オープン
#9,293 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る

まだ誰も着手していません。

評価

難易度
5/5
見積もり時間
1週間以上
初心者へのやさしさ
35/100
issue の種類
機能追加
明瞭さ
おおむね明確
活発さ
停滞
技術スタック
cpp
領域
embedded-iot

調査の方向性

まず ESP8266AVRISP.cpp と SPIClass のコア実装を読み、SPI.begin() と SPI.transfer() の直接呼び出し、およびグローバルな SPI 依存関係に注目してください。既存のハードウェア SPI 設計と、提案されている Software SPI 実装を比較してください。ESP8266AVRISP がハードウェア SPI ピンに結び付けられるのではなく、注入された代替 SPI 実装を使用できれば完了です。

索引モデルが issue の本文から書いたものです。

説明

The problem

Currently, the core SPIClass is a concrete implementation tied directly to the hardware SPI peripheral (HSPI).

Libraries included in this repository, such as ESP8266AVRISP, are hard-coded to use the global SPI instance. For example, ESP8266AVRISP.cpp directly calls SPI.begin() and SPI.transfer().

This creates a problem: it's impossible to use ESP8266AVRISP (or other similarly-coded libraries) if the hardware SPI pins (GPIO 12, 13, 14) are already in use by another device. It also prevents the use of a "bit-bang" (software) SPI implementation on arbitrary pins.

My goal is to add a Software SPI implementation and be able to use it with the ESP8266AVRISP library.

Proposed solution

I propose refactoring the SPI ecosystem to allow for "Dependency Injection," where a library (like ESP8266AVRISP) accepts an SPI implementation in its constructor instead of being hard-coded to the global SPI object.

My contribution

I have working solution with modified ESP8266AVRISP which use software SPI implementation I made. I can make PR if this propose is accepted

主要言語
C++
スター
16.7k
フォーク
13.1k
PR マージ指標
30日以内にマージされた PR はありません

環境構築

このプロジェクトには開発コンテナ、Dockerfile、コントリビューションガイドがありません。まず README を読み、一般的な手順ははじめてのコントリビューションガイドを参照してください。

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

esp8266/Arduino のほかの issue

esp8266/Arduino の issue をすべて見る

似ている issue

C++ の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。