3 Replies Latest reply on Jul 24, 2015 8:26 AM by kwang Branched from an earlier discussion.

    GATT DB generated by Smart Designer does not work...

      Similar to the thread here: No GATT-Database if bleprofile_Init()

       

      I am runing into this issue as well. The database and the app are completely generated by the designer, yet it won't run. All I am doing is creating a device with a generic heart rate monitor service and enabled notifications. Below is the GATT database.

      const UINT8 gatt_database[] = // Define GATT database

      {

          /* Primary Service 'Generic Access' */

          //<Name>Generic Access</Name>

          //<Uuid>1800</Uuid>

          //Service handle: HDLS_GENERIC_ACCESS

          //Service UUID: UUID_SERVICE_GAP

          PRIMARY_SERVICE_UUID16 (HDLS_GENERIC_ACCESS, UUID_SERVICE_GAP),

       

       

              /* Characteristic 'Device Name' */

              //<Name>Device Name</Name>

              //<Uuid>2A00</Uuid>

              CHARACTERISTIC_UUID16 (HDLC_GENERIC_ACCESS_DEVICE_NAME,

                  HDLC_GENERIC_ACCESS_DEVICE_NAME_VALUE,

                  UUID_CHARACTERISTIC_DEVICE_NAME,

                  LEGATTDB_CHAR_PROP_READ,

                  LEGATTDB_PERM_READABLE,

                  8),

                  'B','a','t','m','a','n','_','1',

       

       

              /* Characteristic 'Appearance' */

              //<Name>Appearance</Name>

              //<Uuid>2A01</Uuid>

              CHARACTERISTIC_UUID16 (HDLC_GENERIC_ACCESS_APPEARANCE,

                  HDLC_GENERIC_ACCESS_APPEARANCE_VALUE,

                  UUID_CHARACTERISTIC_APPEARANCE,

                  LEGATTDB_CHAR_PROP_READ,

                  LEGATTDB_PERM_READABLE,

                  2),

                  BIT16_TO_8(APPEARANCE_GENERIC_HEART_RATE_SENSOR),

       

       

          /* Primary Service 'Generic Attribute' */

          //<Name>Generic Attribute</Name>

          //<Uuid>1801</Uuid>

          //Service handle: HDLS_GENERIC_ATTRIBUTE

          //Service UUID: UUID_SERVICE_GATT

          PRIMARY_SERVICE_UUID16 (HDLS_GENERIC_ATTRIBUTE, UUID_SERVICE_GATT),

       

       

          /* Primary Service 'Heart Rate' */

          //<Name>Heart Rate</Name>

          //<Uuid>180D</Uuid>

          //Service handle: HDLS_HEART_RATE

          //Service UUID: UUID_SERVICE_HEART_RATE

          PRIMARY_SERVICE_UUID16 (HDLS_HEART_RATE, UUID_SERVICE_HEART_RATE),

       

       

              /* Characteristic 'Heart Rate Measurement' */

              //<Name>Heart Rate Measurement</Name>

              //<Uuid>2A37</Uuid>

              CHARACTERISTIC_UUID16 (HDLC_HEART_RATE_HEART_RATE_MEASUREMENT,

                  HDLC_HEART_RATE_HEART_RATE_MEASUREMENT_VALUE,

                  UUID_CHARACTERISTIC_HEART_RATE_MEASUREMENT,

                  LEGATTDB_CHAR_PROP_NOTIFY,

                  LEGATTDB_PERM_NONE,

                  2),

                  0x87,0x00,

       

       

                  /* Client Characteristic Configuration Descriptor */

                  //<Notification>true</Notification>

                  //<Indication>false</Indication>

                  CHAR_DESCRIPTOR_UUID16_WRITABLE (HDLD_HEART_RATE_HEART_RATE_MEASUREMENT_CLIENT_CONFIGURATION,

                      UUID_DESCRIPTOR_CLIENT_CHARACTERISTIC_CONFIGURATION,

                      LEGATTDB_PERM_READABLE | LEGATTDB_PERM_WRITE_CMD | LEGATTDB_PERM_WRITE_REQ | LEGATTDB_PERM_RELIABLE_WRITE | LEGATTDB_PERM_AUTH_WRITABLE,

                      2),

                      BIT16_TO_8(CCC_NOTIFICATION),

       

       

      };