CANBus 函式庫

86Duino IDE 從 Coding 103 開始加入此函式庫,用於存取 86Duino One 提供的 CAN bus (Controller Area Network) 通訊介面。

CAN 是一種常見的工業通訊協定,可以支持高安全等級及有效率的即時控制,常被用於各種車輛與自動化設備上。86Duino 內建的 CAN Bus 控制器主要特色如下:

  • 支援 CAN 2.0A 及 2.0B 規範
  • 傳輸速率最高可達 1 Mbps
  • 支援 standard (11-bit) 和 extended (29-bit) 的 data/remote frame 傳輸
  • 提供三組 frame buffer
  • 豐富的錯誤檢測及處理機制

為了讓 Arduino 使用者更容易上手此函式庫,我們在函式庫 API 的設計上已盡量與 Wire 函式庫 以及 Seeed Studio 的 CAN Bus 函式庫 相近。下面說明各函式的使用方式。

Functions

begin()
init_Mask()
init_Filt()
beginTransmission()
endTransmission()
write()
requestFrom()
read()
available()
remoteExt()
remoteID()
sendMsgBuf()
readMsgBuf()
checkReceive()
getCanId()


函式庫參考主頁面

The text of the 86Duino reference is licensed under a Creative Commons Attribution-ShareAlike 3.0 License. Code samples in the reference are released into the public domain.