Skip to Content
《Arduino 烹饪书》第三版
book

《Arduino 烹饪书》第三版

by Michael Margolis, Brian Jepson, Nicholas Robert Weldin
May 2025
Beginner to intermediate
798 pages
10h 10m
Chinese
O'Reilly Media, Inc.
Content preview from 《Arduino 烹饪书》第三版

数字和模拟引脚

F-1F-2显示了 Arduino Uno 板和 Mega 板的数字和模拟引脚。Arduino "栏是 ATmega168/328,"Mega "栏是 ATmega1280/2560。

端口列列出了引脚使用的物理端口--有关如何通过直接写入端口来设置引脚的信息,请参阅配方 18.11第 18 章引言中包含有关定时器使用的更多详细信息。下表显示了

  • USART RX 为硬件串行接收

  • USART TX 是硬件串行传输

  • Ext Int 为外部中断(后跟中断编号)

  • PWM TnA/B 是定时器 n 的脉宽调制(analogWrite )输出。

  • MISO、MOSI、SCK 和 SS 是 SPI 控制信号

  • SDA 和 SCL 是 I2C 控制信号

常用 Arduino 板通用的模拟和数字引脚分配
Arduino 168/328 Arduino Mega(0-19 引脚)
数字引脚 港口 模拟引脚 使用方法 港口 模拟引脚 使用方法

0

PD 0

USART RX

PE 0

USART0 RX,引脚 Int 8

1

PD 1

USART TX

体育 1

USART0 TX

2

PD 2

Ext Int 0

体育 4

PWMT3B、INT4

3

PD 3

PWMT2B,扩展输入 1

PE 5

PWMT3C、INT5

4

PD 4

PG 5

PWMT0B

5

PD 5

PWMT0B

体育课 3

PWMT3A

6

PD 6

PWMT0A

PH 3

PWMT4A

7

PD 7

PH 4

PWMT4B

8

PB 0

输入捕捉

PH 5

PWMT4C

9

PB 1

PWMT1A

PH 6

PWMT2B

10

PB 2

PWMT1B、SS

PB 4

PWMT2A,引脚 Int 4

11

PB 3

PWMT2A,MOSI

PB 5

PWMT1A,引脚 Int 5

12

PB 4

SPI MISO

PB 6

PWMT1B,引脚 Int 6

13

PB 5

SPI SCK

PB 7

PWMT0A,引脚 Int 7

14

PC 0

0

PJ 1

USART3 TX,引脚 Int 10

15

PC 1

1

PJ 0

USART3 RX,引脚 Int 9

16

PC 2

2

PH 1

USART2 TX

17

PC 3

3

PH 0

USART2 RX

18

PC 4

4

I2C SDA

PD 3

USART1 TX,扩展 Int 3

19

PC 5

5

I2C SCL

PD 2

USART1 RX,扩展输入 2

其他 Mega 引脚的分配
Arduino Mega(引脚 20-44) Arduino Mega(45-69 引脚)
数字引脚 港口 使用方法 数字引脚 港口 模拟引脚 ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.

Read now

Unlock full access

More than 5,000 organizations count on O’Reilly

AirBnbBlueOriginElectronic ArtsHomeDepotNasdaqRakutenTata Consultancy Services

QuotationMarkO’Reilly covers everything we've got, with content to help us build a world-class technology community, upgrade the capabilities and competencies of our teams, and improve overall team performance as well as their engagement.
Julian F.
Head of Cybersecurity
QuotationMarkI wanted to learn C and C++, but it didn't click for me until I picked up an O'Reilly book. When I went on the O’Reilly platform, I was astonished to find all the books there, plus live events and sandboxes so you could play around with the technology.
Addison B.
Field Engineer
QuotationMarkI’ve been on the O’Reilly platform for more than eight years. I use a couple of learning platforms, but I'm on O'Reilly more than anybody else. When you're there, you start learning. I'm never disappointed.
Amir M.
Data Platform Tech Lead
QuotationMarkI'm always learning. So when I got on to O'Reilly, I was like a kid in a candy store. There are playlists. There are answers. There's on-demand training. It's worth its weight in gold, in terms of what it allows me to do.
Mark W.
Embedded Software Engineer

You might also like

技术主管的进阶之路 (Chinese Edition)

技术主管的进阶之路 (Chinese Edition)

Anemari Fiser

Publisher Resources

ISBN: 9798341659582