|
SmartSnippets DA1459x SDK
|
This application is a sample implementation of the Apple Media Service (AMS) service client - Media Remote role defined in the AMS Profile Specification. The demo supports all optional characteristics of AMS - Remote Command, Entity Update and Entity Attribute.
The project is located in the projects/dk_apps/ble_profiles/ams folder.
To install the project follow the General Installation and Debugging Procedure.
The application can be controlled using the serial console exposed over UART2.
GPIO pins configuration is as follows:
| DA1469x GPIO pin | DA1468x GPIO pin | DA1459x GPIO pin | Function |---------------—|---------------—|-------------------------— | P0.9 | P1.3 | P0.13 | UART2 TX | P0.8 | P2.3 | P0.15 | UART2 RX | P0.7 | P1.6 | P0.11 | UART2 CTS
UART settings are as follows:
| Setting | Value |
|---|---|
| Baudrate | 115200 |
| Data bits | 8 |
| Stop bits | 1 |
| Parity | None |
| Flow control | RTS/CTS |
The application sets the LED active when playing. Otherwise the LED is turned off. The LED is connected to: P1.1 on the DA1459x platform (P1.1 is connected to the RED led on the daughterboard), P1.5 on the DA1468x platform (jumper J5 must be connected), P1.1 on the DA1469x platform (P1.1 is connected to the RED led on the daughterboard).
The application uses a button to trigger PLAY/PAUSE command. The button is also used to unpair all devices at startup - user may simply keep the button pressed during reboot. If there is any bonded device, the following message will be printed on the console (in this example C4:61:8B:80:2B:5E device is in cache):
The button is connected to: P0.10 on the DA1459x platform (J8 jumper must be connected), P1.2 on the DA1468x platform (a connection between J8 connector's first pin and P1.2 pin is needed), P0.6 on the DA1469x platform (J8 jumper must be connected).
To enable verbose logs containing all data coming from the AMS, set CFG_VERBOSE_LOG in ams_config.h file to a non-zero value, i.e.
The application is controlled using command line interface (CLI) which can be accessed using the serial port available when the platform is connected to a PC using USB connector (e.g. /dev/ttyUSBx or COMx).
Use a device that supports AMS service, scan for the "Renesas AMS Demo" device and connect to it.
Notifications from Entity Update are displayed in human-readable form as follows:
Send remote command
It will send a remote command to the AMS Media Source. Remote commands are defined in the AMS Profile Specification, i.e.:
Will send a RemoteCommandIDTogglePlayPause command.
This command allows the user to read the content of a given attribute. I.e. if the negotiated MTU was not large enough to send Track Name in the Entity Update notification, it can be fetched using the command below:
Enabling verbose logs allow the user to see more detailed information about notifications coming from iOS. Entity Update notifications are decoded as follows:
Read from Entity Attribute:
Remote Command notifications:
1.8.16