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.
Hi,
I was wandering for the reason of the "retry"? Its in a project called "MSP432Host_UART_BSL_MSP430FR", part of Simplelink MSP432 SDK.
int BSL_main()
{
bool result = true;
UART_Initialize();
uint8_t retry = MAX_RETRY;
while (retry)
{
Debug_UART_printString("\r\n\r\n*****New Attempt*****\r\n\r\n");
BSLEntrySequence();
MsDelay(100);
result = WritePasswordDefault();
if (!result)
{
Debug_UART_printString("Write password failed\r\n");
retry --;
continue;
}
Debug_UART_printString("Write Password was successful\r\n");
uint8_t deviceIDBytes[2] = {0};
result = ReadMemory(0x1A04, 2, deviceIDBytes);
if (!result)
{
Debug_UART_printString("Device ID read failed\r\n");
retry --;
continue;
}
uint16_t deviceID = deviceIDBytes[0] << 8 | deviceIDBytes[1];
Debug_UART_printStringWithNumber("Device ID: 0x%X\r\n", deviceID);
result = ProgramMSP430();
if (!result)
{
Debug_UART_printString("\r\nMSP430 programming failed\r\n");
retry --;
continue;
}
Debug_UART_printString("\r\nMSP430 programmed successfully\r\n");
UART_Close();
Reset();
Debug_UART_printString("Device is reset\r\n");
return 0;
}
UART_Close();
Debug_UART_printString("Max retries exceeded\r\n");
return 1;
}
rgds,
Laurent van Poppelen
Hi Laurent,
Sorry for reply you too late, do you still need support for this?
Retry should just a double check BSL communication.
Thanks!
Best Regards
Johnson
Hi Johnson,
thanks for reply. Yes, still support needed. We are using the MSP430FR6047. We would like confirmation on the procedure for BSL for this part. The 'Command Returns' in document slau550t par 4.1.5.2 mentions something but, its not clear about it?
rgds,
Laurent
2M Engineering Ltd
the Netherlands
Hi Netherlands,
Which information you can understand?
And is there are some issue you encounter? What is your host? Processor or PC?
Thanks!
Best Regards
Johnson
Hi,
the problem might be caused elsewhere! We have another reading thread on that same uart! The question is than, what happens to this read when we change the baudrate? If it stays waiting in that other thread we can imaging things go wrong! Can you clearify what happens to that read()? Should we change it to non-blocking and, stop it first?
rgds,
Laurent
Hi Laurent,
Sorry, I don't get your point. You are encounter some issue when use FRAM BSL based on FR6047.
I think you should be able to follow our application note to impletemnt BSL function.
What issue you encounter? Update fail? or other phenomenon?
Thanks!
Best Regards
Johnson
Hi Johnson,
thanks for quick reply! Well, I discovered that, when changing baudrate to 9600 baud one UART_read(), in another task was still active! This could give trouble so I solved this. I encountered some irredical beheviour which could be caused by that UART_read(). Could you give me a link to the application note ypu mentioned? I'll let you know the results next week.
rgds,
Laurent
Hi Laurent,
You can find all material about BSL here:
https://www.ti.com/tool/MSPBSL
Thanks!
Best Regards
Johnson
**Attention** This is a public forum