Answers.Body: <p>The back of this sensor unscrews. The back breaks out the 6-pin cable into an 8-pin connector:</p>
  <p><a href="https://i.sstatic.net/Vo5Cg.png" rel="nofollow noreferrer"><img src="https://i.sstatic.net/Vo5Cg.png" alt="Inside of back" /></a></p>
  <p>The order of the connections for the pins in that picture from left to right are:</p>
  <pre><code> 6    5    4    3    x    x    2    1
  ID2  ID1  VCC  GND   x    x   M2   M1
  </code></pre>
  <p>The primary sensor can be pulled out of the front of the part:</p>
  <p><a href="https://i.sstatic.net/vUooz.png" rel="nofollow noreferrer"><img src="https://i.sstatic.net/vUooz.png" alt="Sensor Front" /></a></p>
  <p>We can then remove the shroud around the sensor to reveal the front side of the PCB:</p>
  <p><a href="https://i.sstatic.net/j3HTZ.png" rel="nofollow noreferrer"><img src="https://i.sstatic.net/j3HTZ.png" alt="PCB Front" /></a></p>
  <p>The largest chip on the front side is an <a href="https://www.st.com/en/microcontrollers-microprocessors/stm8s105k6.html" rel="nofollow noreferrer">STM8S105K6</a>.</p>
  <p>Here's the PCB from the back:</p>
  <p><a href="https://i.sstatic.net/itmuY.png" rel="nofollow noreferrer"><img src="https://i.sstatic.net/itmuY.png" alt="PCB Back" /></a></p>
  <p>The largest chip on the back is a <a href="https://www.nexperia.com/products/analog-logic-ics/logic/buffers-inverters-transceivers/buffers/HEF4049BT.html" rel="nofollow noreferrer">HEF4049BT hex inverting buffer</a>.</p>
  <p>I don't have any insight into why an 8-pin connector is used internally when there are only 6 conductors in the wire, but I did confirm electrically that 6 of the 8 pins are connected to the 6 conductors in the wire.</p>
  <p>There are <a href="http://www.mindsensors.com/spike-prime/218-breadboard-connector-kit-for-spike-prime-ultrasonic-sensor-cable" rel="nofollow noreferrer">3rd-party breakout boards</a> that can make the connections from the back of the ultrasonic sensor available for advanced usage:</p>
  <p><a href="https://i.sstatic.net/Y4DVu.png" rel="nofollow noreferrer"><img src="https://i.sstatic.net/Y4DVu.png" alt="Breakout board" /></a></p>
  <p>A header (or individual wires) of appropriate size can also be inserted directly into the back of the sensor without a specialized board, but the pitch is smaller (0.050&quot; or 1.27mm) than what is typically used by hobbyists.</p>
  
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2024-01-06T15:13:43.193Z
Answers.Text: I'm confused/intrigued by https://community.legoeducation.com/blogs/31/220 , about "the back of the [distance] sensor can be removed and the cable detached, effectively becoming a LEGO Power Functions 2.0 (LPF2) breakout cable"
Answers.UserDisplayName: IvanSanchez
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2024-01-06T15:27:26.853Z
Answers.Text: @IvanSanchez Thanks for sharing that! I've added info about that breakout board to the answer.
Answers.UserDisplayName: jncraton
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2024-01-07T04:35:19.307Z
Answers.Text: My guess for the 8-pin mystery is that it's a **fail-safe** mechanism. AFAICS, pins 3 and 4 are +VCC and GND, whereas 5 and 6 are not connected to anything. Since the connector is symmetrical, one could plug a connector rotated 180° - when doing so, +VCC and GND are connected to nothing, i.e. a fail-safe state. If this fail-safe was not in place, it could be possible to connect +VCC to GND and GND to +VCC (or some other weird combination) and potentially damage the circuits.
Answers.UserDisplayName: IvanSanchez
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2024-01-07T15:53:47.773Z
Answers.Text: Thanks for your quick answer Can you confirm uC : STM8S105K6 in QFP on Top-Side ?
  What is the SO16 Chip on Bottom Side ?
  An Hex-CMOS Inverter as 9V Driver would be in SO14, so would not fit ... Jo
Answers.UserDisplayName: user22626
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2024-01-09T00:44:04.683Z
Answers.Text: @user22626 I've added the info for those chips.
Answers.UserDisplayName: jncraton
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2024-01-09T22:54:24.287Z
Answers.Text: Pins 5 and 6 can also be multiplexed as UART. Pin 5 is TX and pin 6 is RX from the point of view of the hub.
Answers.UserDisplayName: David Lechner
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2024-01-06T15:05:10.850Z
Answers.LastActivityDate: 2024-01-09T00:42:59.923Z
Answers.LastEditDate: 2024-01-09T00:42:59.923Z
Answers.UserDisplayName: jncraton
Body: <p>What is inside the Spike Ultrasonic Sensor 45604?</p>
  <p><a href="https://i.sstatic.net/uaUCF.png" rel="nofollow noreferrer"><img src="https://i.sstatic.net/uaUCF.png" alt="Element photo" /></a></p>
  <p>Pictures of Top&amp;Bottom PCB-Assembly would be helpful.</p>
  <p>PoweredUp Cable and Connector use 6-Pin, but why is there used 8-Pin connector inside &quot;black-and-white&quot; Module connection? Are these 2 additional pins in use? What is their function?</p>
  
Tags: <mindstorms><electronics><powered-up><disassembly><spike-prime>
Title: Electronic inside Spike Ultrasonic Sensor 45604
UserDisplayName: user22619
ThreadText: # Electronic inside Spike Ultrasonic Sensor 45604
  
  (Asked by: username_0 on 2024-01-06)
  
  What is inside the Spike Ultrasonic Sensor 45604?
  
  [![Element photo](https://i.sstatic.net/uaUCF.png)](https://i.sstatic.net/uaUCF.png)
  
  Pictures of Top&Bottom PCB-Assembly would be helpful.
  
  PoweredUp Cable and Connector use 6-Pin, but why is there used 8-Pin connector inside "black-and-white" Module connection? Are these 2 additional pins in use? What is their function?
  
  **Tags:** mindstorms, electronics, powered-up, disassembly, spike-prime
  
  
  ---
  
  ## 1 answers
  
  ### Answer by username_1 on 2024-01-06. Score: 4
  
  The back of this sensor unscrews. The back breaks out the 6-pin cable into an 8-pin connector:
  
  [![Inside of back](https://i.sstatic.net/Vo5Cg.png)](https://i.sstatic.net/Vo5Cg.png)
  
  The order of the connections for the pins in that picture from left to right are:
  
  ```
   6    5    4    3    x    x    2    1
  ID2  ID1  VCC  GND   x    x   M2   M1
  
  ```
  
  The primary sensor can be pulled out of the front of the part:
  
  [![Sensor Front](https://i.sstatic.net/vUooz.png)](https://i.sstatic.net/vUooz.png)
  
  We can then remove the shroud around the sensor to reveal the front side of the PCB:
  
  [![PCB Front](https://i.sstatic.net/j3HTZ.png)](https://i.sstatic.net/j3HTZ.png)
  
  The largest chip on the front side is an [STM8S105K6](https://www.st.com/en/microcontrollers-microprocessors/stm8s105k6.html).
  
  Here's the PCB from the back:
  
  [![PCB Back](https://i.sstatic.net/itmuY.png)](https://i.sstatic.net/itmuY.png)
  
  The largest chip on the back is a [HEF4049BT hex inverting buffer](https://www.nexperia.com/products/analog-logic-ics/logic/buffers-inverters-transceivers/buffers/HEF4049BT.html).
  
  I don't have any insight into why an 8-pin connector is used internally when there are only 6 conductors in the wire, but I did confirm electrically that 6 of the 8 pins are connected to the 6 conductors in the wire.
  
  There are [3rd-party breakout boards](http://www.mindsensors.com/spike-prime/218-breadboard-connector-kit-for-spike-prime-ultrasonic-sensor-cable) that can make the connections from the back of the ultrasonic sensor available for advanced usage:
  
  [![Breakout board](https://i.sstatic.net/Y4DVu.png)](https://i.sstatic.net/Y4DVu.png)
  
  A header (or individual wires) of appropriate size can also be inserted directly into the back of the sensor without a specialized board, but the pitch is smaller (0.050" or 1.27mm) than what is typically used by hobbyists.
  
  > **Comments:**
  > **username_2**: I'm confused/intrigued by https://community.legoeducation.com/blogs/31/220 , about "the back of the [distance] sensor can be removed and the cable detached, effectively becoming a LEGO Power Functions 2.0 (LPF2) breakout cable"  
  > **username_1**: @username_2 Thanks for sharing that! I've added info about that breakout board to the answer.  
  > **username_2**: My guess for the 8-pin mystery is that it's a **fail-safe** mechanism. AFAICS, pins 3 and 4 are +VCC and GND, whereas 5 and 6 are not connected to anything. Since the connector is symmetrical, one could plug a connector rotated 180° - when doing so, +VCC and GND are connected to nothing, i.e. a fail-safe state. If this fail-safe was not in place, it could be possible to connect +VCC to GND and GND to +VCC (or some other weird combination) and potentially damage the circuits.  
  > **username_3**: Thanks for your quick answer Can you confirm uC : STM8S105K6 in QFP on Top-Side ? What is the SO16 Chip on Bottom Side ? An Hex-CMOS Inverter as 9V Driver would be in SO14, so would not fit ... Jo  
  > **username_1**: @username_3 I've added the info for those chips.  
  > **username_4**: Pins 5 and 6 can also be multiplexed as UART. Pin 5 is TX and pin 6 is RX from the point of view of the hub.  
  
  ---
  
  