# 430TR

## Manifest.xml Configurations&#x20;

```java
<manifest ... >
    ...
    <application ... >
        ...
        <meta-data android:name="app_name" android:value="BNK_ID_COMPANYNAME" /> 
        <meta-data android:name="app_model_type" android:value="430TR" /> // For 430TR devices
        <meta-data android:name="app_version" android:value="43000110" /> // Change Android  Version major/minor/build into integer. We kindly request this change. Version no must start with 430. Example: 43000110.
     </application>
...
```

**To convert version name to manifest data, you can use following example in your build.gradle**

```java
apply plugin: 'com.android.application'

// This section is parsing Android manifest file, reads version in the meta-data tag, writes it into version name in gradle
// so that the version shown in the android settinsg is same as version in the meta-tag
def versionFromManifest

task parseManifest() {
    def manifest = new XmlSlurper().parse(file(android.sourceSets.main.manifest.srcFile)).declareNamespace(android: 'http://schemas.android.com/apk/res/android');
    println manifest.@package
    manifest.application["meta-data"].each {
        def m = it.attributes()['android:name'] =~ /app_version/
        if (m.find()) {
            versionFromManifest = it.attributes()['android:value'].toString()
        }
    }
}

android {
    compileSdkVersion 28
    defaultConfig {
        applicationId "com.example.atms_alpha"
        minSdkVersion 26
        targetSdkVersion 28
        versionCode versionFromManifest.toInteger()
        versionName "${versionFromManifest}"
        testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
        setProperty("archivesBaseName", "ATMS_Alpha_" + versionFromManifest)

    }
    buildTypes {
        release {
            minifyEnabled false
            proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
        }
    }
}
```

## Device Info

#### void getFiscalId(DeviceInfoResponseHandler deviceInfoResponseHandler) <a href="#void-getfiscalid-deviceinforesponsehandler-deviceinforesponsehandler" id="void-getfiscalid-deviceinforesponsehandler-deviceinforesponsehandler"></a>

The `getFiscalId` function retrieves the fiscal ID from the service.

```
deviceInfo.getFiscalId(object: DeviceInfoResponseHandler {
    override fun onSuccess(result: String) {
        Log.i("Fiscal ID", result)

    }
    override fun onFail(errMessage: String) {
        Log.i("Error Message", errMessage)
    }
});
```

<mark style="color:red;">**Note:**</mark> The Fiscal ID will be in the format **AW**......

#### void getDeviceMode(DeviceInfoResponseHandler deviceInfoResponseHandler) <a href="#void-getdevicemode-deviceinforesponsehandler-deviceinforesponsehandler" id="void-getdevicemode-deviceinforesponsehandler-deviceinforesponsehandler"></a>

The `getDeviceMode` function retrieves the device mode from the service.

```kotlin
deviceInfo.getDeviceMode(object : DeviceInfoResponseHandler {
    override fun onSuccess(result: String) {
        Log.i("Device Mode", result)
        // "POS"
    }

    override fun onFail(errMessage: String) {
        Log.i("Error Message", errMessage)
    }
})
```

```kotlin
public enum PosModeEnum {
    VUK507,
    POS,
    GIB,
    ECR,
    EFT_POS,
    RESERVED_0,
    RESERVED_1,
    RESERVED_2,
    RESERVED_3,
    RESERVED_4,
    CY // CYPRUS    
}
```

<mark style="color:red;">**NOTE:**</mark> The deviceMode value of the device will be **POS**.

## Important Considerations

### Device Name

Device name will be "430TR".

When the device model information is obtained using the `Build.MODEL` field, it returns the value `430TR` for the corresponding device.&#x20;

<mark style="color:red;">**NOTE:**</mark> On the devices provided for development, this value is displayed as 330TR; however, under normal conditions, the value will be 430TR.

```kotlin
Log.i(tag, "Device Model: ${Build.MODEL}")

// 430TR
```

### UI&#x20;

**UI behavior is identical to the X30TR device.**\
Therefore, if UI separation is implemented via **`BuildConfig`** checks in your codebase, the relevant conditional statements should be reviewed.

For QR display flows, if the **`QrScreen330` fragment** is used on the **X30TR**, the same fragment can be reused on the **430TR**.
