I am working with IoT Sensor Kit SDK v5.160.1.19 and want to port the project to the Murata ZY module, which incorporates DA14580.
I have attached W25X20 flash to the bootable SPI bus (AN-B-023 Table 3).
In Keil, I have removed __DA14583__ from the preprocessor symbols.
I have made the following changes to the code:
user_periph_setup.h
#define SPI_FLASH_DEFAULT_SIZE --> changed to 262144
user_periph_setup.c
spi_driver_cs_pad.* --> changed to SPI flash CE pin/port on my board
user_platform.h
#define SPI_FLASH_* --> changed to SPI flash ports on my board
#define BMI* --> changed to same ports (SPI bus is shared between sensors and flash)
#define BMM* --> changed to same ports (SPI bus is shared between sensors and flash)
#define SPI_*_PIN --> changed to same ports
#define DA14583_SPI_FLASH* --> changed to same ports
#define DA14583_SPI_FLASH_SIZE --> changed to 0x40000
gpio.c
RESERVE_GPIO(DA14583_INTERNAL_FLASH_SPI_*) --> changed to SPI flash ports on my board
Furthermore I have changed the interrupt pins accordingly.
Unfortunately after flashing the ROM (with "bootable" enabled) the device does not start advertising.
Questions:
(1) What other steps am I missing to port the code successfully to DA14580?
(2) The sensors are not yet connected to SPI (I have left their CS unconnected), can this be a problem? Will the code halt before advertising BT?
(3) Do I have to make changes in the code regarding battery/power? IoT Sensor kit is operating in BOOST mode from coin cell, I am operating from 3.3V.
(4) Is there recommended Kyle project for first bring-up? I am thinking of a firmware which will just output some text through the UART such that I can verify successful booting from the SPI flash. I have seen in Training7 of the Prototype Bring-up Guide . Is the empty_peripheral_template suitable for such a test, or is this just suitable to test BT?
Best regards
Johannes
Hi gme_johannes,
Thanks, PM_Dialog
Hi,
thank you for your answer. I understand you can not provide detailed guidance, I will try it on my own and already had some further success.
I have the code running now such that I can discover it with a BT scanner.
关于之前的问题:
(1) I have also changed GPIOs for the sensors, I forgot to mention it. However they are not connected at the moment.
(2) Thank you, I have identified what you meant.
(3) Misunderstanding from my side, I thought it was operating from a 1.5V cell, I see now that it is in fact 3.0V. Thank you.
(4) Unfortunately Kyle is showing only "boxes" in the UART terminal.
这也是case when I try it with your original DA14583 IoT sensor with original firmware (v5.160.1.19) when I press reset (probably just a glitch from booting).
Connecting through UART per se is not a problem, e.g. I can access and program through it (hence I assume baud rate is set correctly to 56k in smart snippets).
Is there no output on UART in the default project? I had assume that something like this "DBG_MSG("ADV UNDR COMPLT\r\n");" will be output to UART as default.
Best regards
Johannes
Hi gme_johannes
我不能够明白你的意思with your last statement “Kyle is showing only boxes in the UART terminal”.Could you please explain little bit more what you mean exactly? As If I understand correctly, you mean that if you attach the UART pins to an FTDI cable and open a terminal, you only get that output? If this is the problem, you are able to see the bootloader executing, so there is no firmware downloaded to your device. You have requested in your previous post something basic, a firmware that will just print out a few characters over the UART, if you download the indicated firmware you will be able to see what you want to print. Regarding printing from the IoT project, you should define the CFG_PRINTF in the da1458x_config_basic.h file and attach an FTDI cable on the corresponding pins of the CIB board. After that configuration, you will be able to print.
Thanks, PM_Dialog