# C Code Interface: CAPL Conversion

Vehicle Spy includes a nice time saving feature that converts Vector CAPL to C code. This feature is found under [Scripting and Automation](https://docs.intrepidcs.com/vspy-3-documentation/vehicle-spy-main-menus/main-menu-scripting-and-automation) -> [C Code Interface](https://docs.intrepidcs.com/vspy-3-documentation/vehicle-spy-main-menus/main-menu-scripting-and-automation/c-code-interface).\
\
Follow these steps to convert CAPL to C code for use in Vehicle Spy:

1. Verify a [platform and its databases](https://docs.intrepidcs.com/vspy-3-documentation/vehicle-spy-main-menus/main-menu-setup/network-databases) are setup properly.
2. Open C Code Interface.
3. Click **Add Project** and select "New Project from Vector CAPL". (Figure 1)
4. Select the \*.CAN file to convert.\
   &#x20; Verify MS Visual Studio converts the file into a project without errors.
5. Build the project in MS Visual Studio. (can use Ctrl+Shift+B)

   &#x20;  Verify the project builds without errors.<br>
6. Take Vehicle Spy online to run the converted and built CAPL project.\
   &#x20;  Results will depend upon what is in the CAPL project.\
   &#x20;  See results on the CCIF Output tab, [Messages view](https://docs.intrepidcs.com/vspy-3-documentation/vehicle-spy-main-menus/main-menu-spy-networks/messages-view), [Application Signals](https://docs.intrepidcs.com/vspy-3-documentation/vehicle-spy-main-menus/main-menu-scripting-and-automation/application-signals), [Graphical Panels](https://docs.intrepidcs.com/vspy-3-documentation/vehicle-spy-main-menus/main-menu-measurement/graphical-panels), etc.

![Figure 1: Convert CAPL to C code using the C Code Interface.](https://3170208387-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FL6lcovCpkhoS9uTOFtEp%2Fuploads%2FBNsWVAX9Wd4eBo2dwCNo%2FspyCAPLConverter.gif?alt=media\&token=62dc3df9-8f11-45ba-8909-e6d3af24799e)


---

# Agent Instructions: 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:

```
GET https://docs.intrepidcs.com/vspy-3-documentation/vehicle-spy-main-menus/main-menu-scripting-and-automation/c-code-interface/c-code-interface-capl-conversion.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
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.
