> For the complete documentation index, see [llms.txt](https://mrwheel-docs.gitbook.io/yappgenerator_en/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://mrwheel-docs.gitbook.io/yappgenerator_en/connecting-base-and-lid.md).

# Connecting Base and Lid

### Connectors to connect Base and Lid together

With this type of connector you can connect the Base and the Lid together.

```
//===================================================================
//   *** Connectors ***
//   Standoffs with hole through base and socket in lid for screw type connections.
//-------------------------------------------------------------------
//  Default origin = yappCoordBox: box[0,0,0]
//  
//  Parameters:
//   Required:
//    p(0)  = posX
//    p(1)  = posY
//    p(2)  = pcbStandHeight
//    p(3)  = screwDiameter
//    p(4)  = screwHeadDiameter (don't forget to add extra for the fillet)
//    p(5)  = insertDiameter
//    p(6)  = outsideDiameter
//   Optional:
//    p(7)  = PCB Gap : Default = -1 : Default for yappCoordPCB=pcbThickness, yappCoordBox=0
//    p(8)  = filletRadius : Default = 0/Auto(0 = auto size)
//    n(a) = { <yappAllCorners> | yappFrontLeft | yappFrontRight | yappBackLeft | yappBackRight }
//    n(b) = { <yappCoordBox> | yappCoordPCB | yappCoordBoxInside }
//    n(c) = { yappNoFillet }
//    n(g) = {yappSelfThreading} : Make the insert self threading specify the Screw Diameter in the insertDiameter
//-------------------------------------------------------------------
```

For every entry in the connectors array at least the first seven (0..6) parameters are required. All the others can be omitted.\
Look at [YAPPgenerator API](/yappgenerator_en/yappgenerator-api.md) to see how to use **Optional** parameters.

Example:

```
connectors   =  
[
    [10, 10, standoffHeight
     , 2.7    //-- diameter of the screw (add some slack)
     , 5      //-- the diameter of the screw head
     , 4.1    //-- the diameter of the insert
     , 9]     //-- the outside diameter of the connector
];
```

<figure><img src="/files/NIgb8NjCo5FVqt45o3GW" alt=""><figcaption></figcaption></figure>

The **Optional** parameter **n(b)** specifies whether there will be space for the PCB (*yappCoordPCB*) between the two parts of the connector or not (default *yappCoordBox*) as well as the origin of the posX and posY values.

Example:

```
connectors   =  
[
    [10, 10, standoffHeight
     , 2.7           //-- diameter of the screw (add some slack)
     , 5             //-- the diameter of the screw head
     , 4.1           //-- the diameter of the insert
     , 9             //-- the outside diameter of the connector
     , yappCoordPCB] //-- use [0,0,0] of the PCB os origen
];
```

Results in these connectors:

<figure><img src="/files/yG6VR51Nmcbwc7yhpf8N" alt=""><figcaption></figcaption></figure>

{% hint style="info" %}
Thanks to *Oliver Grafe*
{% endhint %}

The depth of the screw is changed with the standoffHeight so you don't have to buy new screws every time you make a projectbox with a different height.

<figure><img src="/files/Butuk5pszlmGwKUQFApk" alt=""><figcaption></figcaption></figure>

### Melt Inserts

You have to press/melt an **`insert`** into the Lid-connector.&#x20;

<div><figure><img src="/files/Egj06xdkgF30vI47cF4h" alt=""><figcaption></figcaption></figure> <figure><img src="/files/aifhNms0BoWrtFQKpV5o" alt=""><figcaption></figcaption></figure></div>


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://mrwheel-docs.gitbook.io/yappgenerator_en/connecting-base-and-lid.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
