Constants.java
Go to the documentation of this file.
00001 package com.github.rosjava.android_remocons.common_tools.rocon;
00002 
00003 import org.ros.internal.message.DefaultMessageFactory;
00004 import org.ros.internal.message.definition.MessageDefinitionReflectionProvider;
00005 
00006 import rocon_std_msgs.PlatformInfo;
00007 import rocon_std_msgs.Strings;
00008 
00014 public class Constants {
00015     public static final int NFC_SSID_FIELD_LENGTH           =  16;
00016     public static final int NFC_PASSWORD_FIELD_LENGTH       =  16;
00017     public static final int NFC_MASTER_HOST_FIELD_LENGTH    =  16;
00018     public static final int NFC_MASTER_PORT_FIELD_LENGTH    =   2;
00019     public static final int NFC_APP_HASH_FIELD_LENGTH       =   4;
00020     public static final int NFC_EXTRA_DATA_FIELD_LENGTH     =   2;
00021     public static final int NFC_APP_RECORD_FIELD_LENGTH     =  56;
00022     public static final int NFC_PAYLOAD_LENGTH              =  56; // 16 + 16 + 16 + 2 + 4 + 2
00023     public static final int NFC_ULTRALIGHT_C_MAX_LENGTH     = 137;
00024 
00025     // unique identifier to key string variables between activities.
00026     static public final String ACTIVITY_SWITCHER_ID = "com.github.rosjava.android_remocons.common_tools.rocon.Constants";
00027     static public final String ACTIVITY_ROCON_REMOCON = "com.github.rosjava.android_remocons.rocon_remocon.Remocon";
00028 
00029     public static final rocon_std_msgs.PlatformInfo ANDROID_PLATFORM_INFO = makePlatformInfo();
00030 
00038     private static PlatformInfo makePlatformInfo() {
00039         MessageDefinitionReflectionProvider messageDefinitionProvider = new MessageDefinitionReflectionProvider();
00040         DefaultMessageFactory messageFactory = new DefaultMessageFactory(messageDefinitionProvider);
00041         PlatformInfo platformInfo = messageFactory.newFromType(PlatformInfo._TYPE);
00042         // rocon:/hw/name/app_framework/os"
00043         platformInfo.setUri("rocon:/"
00044                         + Strings.URI_WILDCARD + "/" + Strings.URI_WILDCARD + "/"
00045                         + Strings.APPLICATION_FRAMEWORK_INDIGO + "/"
00046                         + Strings.OS_ICE_CREAM_SANDWICH + "|" + Strings.OS_JELLYBEAN + "|"
00047                         + Strings.OS_CHROME
00048         );
00049         platformInfo.setVersion(Strings.ROCON_VERSION);
00050         /* Not yet implemented */
00051         /* platformInfo.setIcon() */
00052 
00053         return platformInfo;
00054     }
00055 }


android_remocons
Author(s): Daniel Stonier, Kazuto Murase
autogenerated on Sat Jun 8 2019 19:32:24