Device / port: PNut-Term-TS P81svj44 only.
Serial Host add-on: Parallax #64006B (P2 Eval Add-on Boards series).
Sources (do not invent pinout):
- P2 Eval Add-on Boards (#64006 Series) Product Guide — Serial Host page
- P2KB
p2kbHwAddonSerialHost/p2kbHwAddonSerialHostAddonSerialHost - Silicon USB pair: P2KB
p2kbArchSmartPin11011UsbHostDevice(even=DM, odd=DP)
Serial Host #64006B
Addressing model (documented)
Board functions are offsets 0..7 within an 8-pin eval header group:
actual_P2_pin = base_pin + offset
This project uses base_pin = 32 (header group 32–39).
Signal map (official)
| Offset | P2 pin @ base 32 | Function (64006B / P2KB) |
|---|---|---|
| 0 | 32 | Ch1 blue activity LED (active high, 1 kΩ) |
| 1 | 33 | Ch1 5 V enable (active high) |
| 2 | 34 | Ch1 USB D− |
| 3 | 35 | Ch1 USB D+ |
| 4 | 36 | Ch2 blue activity LED (active high, 1 kΩ) |
| 5 | 37 | Ch2 5 V enable (active high) |
| 6 | 38 | Ch2 USB D− |
| 7 | 39 | Ch2 USB D+ |
Power (documented critical)
- Board requires 5 V. Without it, host ports do not power.
- On P2-ES Eval Board Rev B: shunt jumper must connect ACC HDR and 5 V so 5 V reaches the I/O edge headers.
- PDF also recommends aux power on Eval P2-USB when accessories draw more than PC-USB can supply.
- Per port: up to 500 mA continuous (load switch); both ports up to 1 A total.
Software enable sequence (documented)
' Official pattern (offsets from base)
PINHIGH(base + 1) ' ch1 5V enable
PINHIGH(base + 5) ' ch2 5V enable
PINHIGH(base + 0) ' ch1 activity LED (optional health)
PINHIGH(base + 4) ' ch2 activity LED
USB data: smart-pin P_USB_PAIR on even/odd pair (DM/DP). Software implements host protocol.
What 64006B is (documented)
- Two independent USB Type-A host sockets (two host pin pairs).
- Designed for two devices at once (e.g. keyboard + mouse) — one per socket.
- Multi-device beyond two still needs an external hub on one of those sockets (ticket 1090), or two host cogs if both sockets are driven as hosts.
This project’s default host pair
| Role | Pins | EN | LED |
|---|---|---|---|
| Prefer Ch1 | 34 / 35 | 33 high | 32 optional |
| Fallback Ch2 | 38 / 39 | 37 high | 36 optional |
Constants: src/usb_pins.spin2.
P_USB_PAIR silicon (documented)
| Pair rule | Even pin = DM (D−); odd = DP (D+) |
| Host X | D15=1 host, D14=1 FS, D13:0 baud fraction |
| Baud rule | baud < sysclk/4 (FS 12 MHz ⇒ sysclk > 48 MHz) |
| Y | 0 IDLE float, 1 SE0, 2 K, 3 J driven, 4 EOP, $80 SOP |
| Z | byte + BTOG/ERR/EOP/SOP/SE1/SE0/K/J |
Source: silicon doc via P2KB USB host/device smart-pin entry.
Proto dogfood gang (project wiring, not 64006B)
| Net | Pins | Role |
|---|---|---|
| D− | 40 ↔ 48 | Loopback host/device |
| D+ | 41 ↔ 49 | Loopback host/device |
Independent of Serial Host unless deliberately jumpered.
UART USB-serial case (user plan)
USB-CDC device on hub → host enumerates CDC on Serial Host pair.
P2 pin 54 TX / 55 RX is a separate UART path to that converter’s serial side — not a third USB host pair.