> For the complete documentation index, see [llms.txt](https://developer.magtek.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://developer.magtek.com/hardware/~/revisions/aurjDoOhAcnQLHeoR1ks/card-readers/mms-dyna-devices/emv-common-kernel/dynaflex-ii-go/documents/developers-manuals/programmers-manual-commands/commands/file-operations/start-send-file-to-device-unsecured.md).

# Start Send File to Device (Unsecured)

## Command 0xD812 - Start Send File to Device (Unsecured)

The host uses this command to start sending unsecured files to the device for storage or processing. It is similar to Command 0xD811 - Start Send File to Device (Secured) but is used to send a different subset of file types that do not impact device security. Refer to Table 206 to determine which file type can use unsecure command. This command is paired with Command 0xD821 - Start Get File from Device, which the host can use to retrieve files. However, some file types are “one way only” and cannot be retrieved using that command after the host sends them to the device.

The sequence of events is as follows:

{% stepper %}
{% step %}

### Determine and prepare file

The host determines which file type it will send to the device (see section 6.7.1 About Files), and either opens an existing file in its file system for reading, or begins constructing it.
{% endstep %}

{% step %}

### Construct the Start Send command

The host constructs Command 0xD812 - Start Send File to Device (Unsecured) per Table 216.
{% endstep %}

{% step %}

### Send Request Message

The host sends that command to the device as a Request Message to start the process of uploading a file.
{% endstep %}

{% step %}

### Device acknowledges

The device sends a Response Message so the host knows it can begin sending the file.
{% endstep %}

{% step %}

### Send Data File Message

The host sends a Data File Message to the device. (This is only for DynaFlex II PED Only, not for DynFlex II Go or DynaProx) If the device does not receive file data within a reasonable period of time, it times out and stops listening for the data file.
{% endstep %}

{% step %}

### Device validates file

The device checks to make sure the File ID and the length and hash of the File Payload match with the values the host specified in this command.
{% endstep %}

{% step %}

### Final Response with reference

The device repeats the same Response Message, this time with the Message Reference Number set to the same value the host used in the Data File Message.
{% endstep %}
{% endstepper %}

For image data, the file must be either BMP format or Magtek signed image format, maximum 320px by 240px, with color depth 16 color, 256 color, 16-bit color, or 24-bit color. Images smaller than the maximum size are centered on the display. Maximum size is 160KB per slot, but images can span multiple slots as shown below. The maximum sizes for each slot are 640KB for slot 1, 480KB for slot 2, 320KB for slot 3, and 160KB for slot 4. Loading an image that overwrites any portion of an existing image will delete that image.

<figure><img src="/spaces/1lWLescKFIPsMeIJI6Cd/files/k7puP4j9ddY6MVUH315k" alt=""><figcaption></figcaption></figure>

## Table - Request Data for Command 0xD812 - Start Send File to Device (Unsecured)

<table><thead><tr><th width="239.66668701171875">Tag</th><th width="73.3333740234375">Len</th><th width="259.66668701171875">Value / Description</th><th width="79">Typ</th><th width="78.6666259765625">Req</th><th width="97.3333740234375">Default</th></tr></thead><tbody><tr><td>Beginning of any wrappers, at minimum including Request Message</td><td></td><td></td><td></td><td></td><td></td></tr><tr><td>D812 = Command 0xD812 - Start Send File to Device (Unsecured)</td><td></td><td></td><td></td><td></td><td></td></tr><tr><td>81</td><td>04</td><td>File ID from Table 206</td><td>B</td><td>R</td><td></td></tr><tr><td>A2</td><td>var</td><td>File transfer properties</td><td>T</td><td>R</td><td></td></tr><tr><td>/81</td><td>var</td><td>Length of File Payload. This is the length of the File Payload parameter in the Data File Message the host sends to the device.</td><td>B</td><td>R</td><td></td></tr><tr><td>/82</td><td>01</td><td><p>Hash Checksum Type</p><ul><li>0x04 = SHA-256</li></ul></td><td>B</td><td>R</td><td></td></tr><tr><td>/83</td><td>20</td><td><p>Hash Checksum</p><p></p><p>Anticipated checksum calculated against the File Payload, according to the standard specified in Hash Checksum Type.</p></td><td>B</td><td>R</td><td></td></tr><tr><td>A3</td><td>var</td><td><p>File Description</p><p>The host should populate this value to help identify the file using Command 0xD825 - Get File Info from Device.</p></td><td>T</td><td>R</td><td></td></tr><tr><td>/81</td><td>var</td><td><p>File Name</p><p>Maximum length 32 bytes</p><p>Reserved for future use. Leave empty.</p></td><td>B</td><td>O</td><td>Null</td></tr><tr><td>/83</td><td>var</td><td><p>File Version</p><p>Maximum length 7 bytes</p><p>Reserved for future use. Leave empty.</p></td><td>B</td><td>O</td><td>Null</td></tr><tr><td>/84</td><td>var</td><td><p>File Date</p><p>Maximum length 20 bytes</p><p>Reserved for future use. Leave empty.</p></td><td>B</td><td>O</td><td>Null</td></tr><tr><td>87</td><td>01</td><td>Reserved for future use. Leave empty.</td><td>B</td><td>O</td><td>Null</td></tr><tr><td>End of any wrappers, at minimum including Request Message</td><td></td><td></td><td></td><td></td><td></td></tr></tbody></table>

## Table - Response Data for Command 0xD812 - Start Send File to Device (Unsecured)

<table><thead><tr><th width="217.66668701171875">Tag</th><th width="74.66668701171875">Len</th><th width="233">Value / Description</th><th width="76">Typ</th><th width="74.66668701171875">Req</th><th width="96.6666259765625">Default</th></tr></thead><tbody><tr><td>Beginning of any wrappers, at minimum including Response Message </td><td></td><td></td><td></td><td></td><td></td></tr><tr><td>D812 = Command 0xD812 - Start Send File to Device (Unsecured)</td><td></td><td></td><td></td><td></td><td></td></tr><tr><td>No parameters.</td><td></td><td></td><td></td><td></td><td></td></tr><tr><td>End of any wrappers, at minimum including Response Message # </td><td></td><td></td><td></td><td></td><td></td></tr></tbody></table>

If the request started successfully, the Request Status in the message wrapper is OK, Started / Running, All good / requested operation was successful.

{% hint style="info" %}
Note: For additional support, please contact MagTek Support.
{% endhint %}

## Table - Request Example

| Example (Hex)                                                                                                                                                                                                                             |
| ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| AA 00 81 04 01 07 D8 12 84 44 D8 12 81 04 02 00 00 00 A2 2B 81 04 00 02 58 38 82 01 04 83 20 D5 B8 BF 2F 3A 15 D9 EE 1D 0D E5 8E DD 68 37 73 18 51 C7 3C 3D 79 58 2B A6 07 90 5C 2B 86 3C E5 A3 0A 81 08 30 32 30 30 30 30 30 30 87 01 01 |

## Table - Response Example

| Example (Hex)                             |
| ----------------------------------------- |
| AA 00 81 04 82 07 D8 12 82 04 00 00 00 00 |


---

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

```
GET https://developer.magtek.com/hardware/~/revisions/aurjDoOhAcnQLHeoR1ks/card-readers/mms-dyna-devices/emv-common-kernel/dynaflex-ii-go/documents/developers-manuals/programmers-manual-commands/commands/file-operations/start-send-file-to-device-unsecured.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.
