Hello,
I have downloaded the cc2531 ProdHex file in CC2531 dongle. It got detected in ztool also. after making some cahnges in code for uart communication i tried to download the cc2530 Prodhex file in my cc2530 module but it is not detected in ztool.
I made the following changes in code:
1. In hal_board_cfg.h file
/* ------------------------------------------------------------------------------------------------
* Clock Speed
* ------------------------------------------------------------------------------------------------
*/
#define HAL_CPU_CLOCK_MHZ 32
/* This flag should be defined if the SoC uses the 32MHz crystal
* as the main clock source (instead of DCO).
*/
#define HAL_CLOCK_CRYSTAL
// Values based on powerup h/w config as input with pull-up - not using dynamic cfg of transport.
#define ZNP_CFG0_32K_XTAL 1 /* 32kHz crystal installed and used */
#define ZNP_CFG0_32K_OSC 0 /* 32kHz crystal not installed; internal osc. used */
#define ZNP_CFG1_SPI 0 /* use SPI transport */
#define ZNP_CFG1_UART 1 /* use UART transport */
extern unsigned char znpCfg1;
extern unsigned char znpCfg0;
I did it to change the configuration to uart.
2. In OnBoard.C file
oid InitBoard( uint8 level )
{
if ( level == OB_COLD )
{
// IAR does not zero-out this byte below the XSTACK.
*(uint8 *)0x0 = 0;
// Interrupts off
osal_int_disable( INTS_ALL );
// Check for Brown-Out reset
ChkReset();
// Special ZNP CFG1 (CFG0 handled in hal_board_cfg.h.
#if defined CC2531ZNP
znpCfg1 = ZNP_CFG1_UART;
#elif defined CC2530_MK
znpCfg1 = ZNP_CFG1_UART;;
#else
znpCfg1 = P2_0;
znpCfg0 = P1_2;
// Tri-state the 2 CFG inputs after being read (see hal_board_cfg_xxx.h for CFG0.)
P1INP |= BV(2);
P2INP |= BV(0);
#endif
}
else // !OB_COLD
{
/* Initialize Key stuff */
HalKeyConfig(HAL_KEY_INTERRUPT_DISABLE, OnBoard_KeyCallback);
}
}
I have define CC2530_MK in Options/ (C/C++ Compiler) / PreProcessor /Defined Symbols.
when i insert my device it is detected in serial devices section of ztool and i have edited the baud rate also but still it is showing no device found.
Can anybody help me on this problem.
Regards,
Prija Nair.