Skip to content
Snippets Groups Projects
Select Git revision
  • 048196e6a60f403d77cd70eefce4e94a0f7262fc
  • master default protected
  • fix-warnings
  • tvbgone-fixes
  • genofire/ble-follow-py
  • schneider/ble-stability-new-phy-adv
  • schneider/ble-stability
  • msgctl/gfx_rle
  • schneider/ble-stability-new-phy
  • add_menu_vibration
  • plaetzchen/ios-workaround
  • blinkisync-as-preload
  • schneider/max30001-pycardium
  • schneider/max30001-epicaridum
  • schneider/max30001
  • schneider/stream-locks
  • schneider/fundamental-test
  • schneider/ble-buffers
  • schneider/maxim-sdk-update
  • ch3/splashscreen
  • koalo/bhi160-works-but-dirty
  • v1.11
  • v1.10
  • v1.9
  • v1.8
  • v1.7
  • v1.6
  • v1.5
  • v1.4
  • v1.3
  • v1.2
  • v1.1
  • v1.0
  • release-1
  • bootloader-v1
  • v0.0
36 results

svc_dis.c

Blame
  • Forked from card10 / firmware
    Source project has a limited visibility.
    svc_dis.c 9.72 KiB
    /*************************************************************************************************/
    /*!
     *  \file
     *
     *  \brief  Example Device Information Service implementation.
     *
     *  Copyright (c) 2011-2018 Arm Ltd. All Rights Reserved.
     *  ARM Ltd. confidential and proprietary.
     *
     *  IMPORTANT.  Your use of this file is governed by a Software License Agreement
     *  ("Agreement") that must be accepted in order to download or otherwise receive a
     *  copy of this file.  You may not use or copy this file for any purpose other than
     *  as described in the Agreement.  If you do not agree to all of the terms of the
     *  Agreement do not use this file and delete all copies in your possession or control;
     *  if you do not have a copy of the Agreement, you must contact ARM Ltd. prior
     *  to any use, copying or further distribution of this software.
     */
    /*************************************************************************************************/
    
    /* card10:
     * Copied from lib/sdk/Libraries/BTLE/stack/ble-profiles/sources/services/svc_dis.c
     *
     * Contains adaptions for the card10 (e.g. manufacturer name)
     */
    #include "wsf_types.h"
    #include "att_api.h"
    #include "wsf_trace.h"
    #include "util/bstream.h"
    #include "svc_dis.h"
    #include "svc_cfg.h"
    
    /**************************************************************************************************
      Macros
    **************************************************************************************************/
    
    /*! Characteristic read permissions */
    #ifndef DIS_SEC_PERMIT_READ
    #define DIS_SEC_PERMIT_READ SVC_SEC_PERMIT_READ
    #endif
    
    /*! Default manufacturer name */
    #define DIS_DEFAULT_MFR_NAME        "CCC"
    
    /*! Length of default manufacturer name */
    #define DIS_DEFAULT_MFR_NAME_LEN    3
    
    /*! Default model number */
    #define DIS_DEFAULT_MODEL_NUM       "1"
    
    /*! Length of default model number */
    #define DIS_DEFAULT_MODEL_NUM_LEN   1
    
    /*! Default serial number */
    #define DIS_DEFAULT_SERIAL_NUM      "1"
    
    /*! Length of default serial number */
    #define DIS_DEFAULT_SERIAL_NUM_LEN  1
    
    /*! Default firmware revision */
    #define DIS_DEFAULT_FW_REV          "<git hash>"
    
    /*! Length of default firmware revision */
    #define DIS_DEFAULT_FW_REV_LEN      10
    
    /*! Default hardware revision */
    #define DIS_DEFAULT_HW_REV          "1"
    
    /*! Length of default hardware revision */
    #define DIS_DEFAULT_HW_REV_LEN      1