Parallax Propeller2 USB driver - the MashUp

Wiring recipe (ticket 0110)
Login

Wiring recipe (ticket 0110)

Port: PNut-Term-TS P81svj44 only.
Pin constants: pin-map.md, src/usb_pins.spin2.

One-time physical setup so software can run dogfood (on-chip host↔device) and later Serial Host (real MSC) without rewiring data lines.


Safety

  1. Common GND between all P2 USB pairs under test and any external hub/SSD.
  2. VBUS: only Serial Host EN pins (33/37) drive port power. Never back-drive 5 V into a pair that is only D±.
  3. Dogfood proto gang has no VBUS — pure D± loop for emulators.
  4. Do not short Serial Host D± (34/35 or 38/39) to proto 40/41/48/49 unless you intend one electrical bus.
  5. Leave PropPlug / debug pins alone.

Topology A — Dogfood (default bring-up)

Used by harness/top_selftest.spin2 and ticket 3005.

Role Pair (DM/DP) EN
Host 40 / 41 none
Device min 48 / 49 none

Jumpers (required):

Wire From To
D− 40 48
D+ 41 49
   P2
 40 ──D−── 48     host cog = 40/41
 41 ──D+── 49     device cog = 48/49

Software: dev.start(48) then app.open(40, -1).


Topology B — Serial Host real media (MSC later)

Priority Logical DM/DP VBUS EN
1st Ch1 (prefer top USB-A) 34/35 33 high
2nd Ch2 fallback 38/39 37 high

Topology C — Hub (multi-device, later)

  1. Host pair = Serial Host ch1 (34/35) + EN 33.
  2. Hub upstream → that USB-A; hub powered externally.
  3. Downstream: real SSD and/or future emulator ports (only if you jumper extra pairs to hub-facing connectors — not the default proto gang).
  4. Software: same host object; addresses from enum (ticket 1090/1100).

Pin picture

Serial Host (base 32)                 Proto dogfood gang
┌──────────────────────┐              40 ── D− ── 48
│ 32 LED1              │              41 ── D+ ── 49
│ 33 EN1 → VBUS ch1    │
│ 34 D−  → USB ch1     │              independent of Serial Host
│ 35 D+  → USB ch1     │
│ 36 LED2              │
│ 37 EN2 → VBUS ch2    │
│ 38 D−  → USB ch2     │
│ 39 D+  → USB ch2     │
└──────────────────────┘
         ▲
    real SSD / stick

SE0 / float notes (multi pair)


Acceptance (0110)