This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

[参考译文] CCS/LAUNCHXL-CC2640R2:LAUNCHXL-CC2640R2

Guru**** 2034770 points
请注意,本文内容源自机器翻译,可能存在语法或其它翻译错误,仅供参考。如需获取准确内容,请参阅链接中的英语原文或自行翻译。

https://e2e.ti.com/support/tools/code-composer-studio-group/ccs/f/code-composer-studio-forum/784942/ccs-launchxl-cc2640r2-launchxl-cc2640r2

器件型号:LAUNCHXL-CC2640R2
Thread 中讨论的其他器件:SYSBIOS

工具/软件:Code Composer Studio

ABORT -异常程序终止。  当前只是暂停执行。  

我正在将外部闪存(IS25LP128)与 CC2640R2 launchpad 相连。 它们通过 SPI 进行连接。我只需要读取外部闪存的器件 ID。但当我尝试运行代码时、会创建一个 exit.c 文件。在调试会话中、它显示了阻止读取的存储器映射。

这是我的代码、

#include
#include

/* BIOS 模块标题*/
#include
#include
#include

/*示例/板头文件*/
#include "Board.h"
#include
#include
#include
void * mainThread (void * arg0)

int MSGSIZE = 4;
SPI_Handle SPI;
SPI_Params spiParams;
SPI_Transaction spiTransaction;
uint8_t transmitBuffer[MSGSIZE];
uint8_t 接收缓冲器[MSGSIZE];
bool transferOK = false;

Board_initGeneral();

spi_init();
SPI_Params_init (&spiParams);
spiParams.dataSize = 8;
// spiParams.bitrate = 4000000;
spiParams.mode = SPI_MASTER;//0

/*调用驱动程序初始化函数*/

SPI = SPI_OPEN (Board_SPI0、&spiParams);
transmitBuffer[0]= 0x90;
transmitBuffer[1]= 0x00;
transmitBuffer[2]= 0x00;
transmitBuffer[3]= 0x00;
spiTransaction.count = MSGSIZE;
spiTransaction.txBuf = transmitBuffer;
spiTransaction.rxBuf =接收缓冲器;

transferOK = SPI_transfer (SPI、&spiTransaction);
if (!transferOK)


BIOS_exit (0);//终止程序并转储 SysMin 输出*/
返回(0);

请帮助解决此问题

  • 请注意,本文内容源自机器翻译,可能存在语法或其它翻译错误,仅供参考。如需获取准确内容,请参阅链接中的英语原文或自行翻译。
    您好!
    只是想知道为什么在代码中注释掉.bitrate。
    此外、请参阅 SDK 中的 nvsexternal_CC2640xx_xx 示例是否有帮助。 该示例使用 SPI 与外部闪存连接。