Stamp FPC12 =========== .. py:currentmodule:: stamp ``StampF12`` maps the one-based connector positions of the Stamp Series FPC12 connector to GPIO numbers on the current Stamp host. It supports StampC5, StampC6, and StampS3Mini. Pin Mapping ----------- .. list-table:: Stamp Series FPC12 position mapping :header-rows: 1 * - Position - StampC5 - StampC6 - StampS3Mini * - 1 - 3V3 - 3V3 - 3V3 * - 2 - 3V3 - 3V3 - 3V3 * - 3 - G23 - G8 - G38 * - 4 - G0 - G0 - G21 * - 5 - G24 - G18 - G39 * - 6 - G25 - G19 - G40 * - 7 - GND - GND - GND * - 8 - G26 - G20 - G41 * - 9 - G27 - G21 - G42 * - 10 - G11 - G22 - G43 * - 11 - GND - GND - GND * - 12 - G12 - G23 - G44 Positions 1 and 2 are 3.3 V. Positions 7 and 11 are ground. They are not returned as GPIO signals. MicroPython Example ------------------- The following example obtains the GPIO at FPC12 position 4 on the current Stamp host. MicroPython Code Block: .. code-block:: python from stamp import StampF12 f12 = StampF12() pin = f12.pin(4) print(pin) **API** ------- class StampF12 -------------- Constructors ------------ .. class:: StampF12() Create an FPC12 position mapper for the current Stamp host. :raises NotImplementedError: If the current board is not StampC5, StampC6, or StampS3Mini. Methods ------- .. method:: StampF12.pin(position) Return the GPIO number assigned to a connector position. :param int position: One-based FPC12 position. :returns: GPIO number for the current Stamp host. :rtype: int :raises ValueError: If the position is outside 1-12 or is a power or ground position.