# ATEGFK

> [HTML Version](ategfk_sbx.htm)

_Updated January 2018; see History_

**xcall ATEGFK, hostspec, pcspec, flags, status**

ATEGFK.SBX retrieves a file from the PC via the ATE terminal connection. This is useful in situations where FTP isn't available or isn't practical. 

**Parameters**

_hostspec_  ([String](string.md))  \[in\]

is the destination (native or AMOS-style)

_pcspec_  ([String](string.md))  \[in\] 

is the source (PC native)

_flags_  ([Num](num.md)) ( \[in\] 

may contain zero or more of the following:

| **Value** | **Definition** |
|------|------|
| 16 | skip post-transfer verification |
| 32 | pre-verify (skip transfer if destination matches source) |
| 64 | ignore version 0 in pre-verification |
| 128 | put ategfk.log in current directory rather than OPR: |




_status_  (Signed [Num](num.md))  \[out\] 

returns status of operation:

| **Value** | **Definition** |
|------|------|
| \>0 | file transferred |
| 0 | transfer not required |
| \-1 | ATE required |
| \-2 | source file doesn't exist |
| \-3 | file transferred but failed to verify afterwards |
| \-4 | transfer failure |




**See Also**

•	Test program [TSTATEGFK.BP in SOSLIB:\[907,33\]](https://bitbucket.org/microsabio/soslib/src/master/907033/tstategfk.bp).

•	[MX\_ATEFILEXFR](mx_atefilexfr.md)

•	Source, samples and related functions can be found in [SOSLIB:\[907,33\]](https://bitbucket.org/microsabio/soslib/src/master/907033/).

**History**

2018 January 2018, A-Shell 6.4.1556, ATEGFK.SBX 1.0(105):  eliminate a five second delay in the case where the source file exists but has zero bytes.

2016 April, A-Shell 6.3.1510:  Routine added to A-Shell