Conversation
|
/morph test |
|
I'll review this PR today or tomorrow |
|
/morph test |
|
There's build error: This issue is related (the last comment): #651 (comment) |
|
Can we reuse the files from KL26 or move them as suggested in the issue? |
fixed. I forgot to add the RTE_Driver files. |
Sure. Let me know where you want to move the Driver_Common.h and Driver_USART.h headers from K26F HIC folder. I don't know if the RTE_Driver files I've added should also be common. |
|
study |
|
/morph test |
|
|
||
| /// Indicate that UART Serial Wire Output (SWO) trace is available. | ||
| /// This information is returned by the command \ref DAP_Info as part of <b>Capabilities</b>. | ||
| #define SWO_UART 1 ///< SWO UART: 1 = available, 0 = not available |
There was a problem hiding this comment.
The DAP_config.h file should be shared between all uses of the LPC4322, not specific to a target. If you want to customize per target, you can wrap this line with #if !defined(SWO_UART), then define that macro in the target project yaml.
| - source/hic_hal/nxp/lpc4322/RTE_Driver | ||
| - source/hic_hal/nxp/lpc4322/RTE_Driver/Config | ||
| sources: | ||
| lpc4322: | ||
| - source/hic_hal/nxp/lpc4322/RTE_Driver/USART_LPC43xx.c | ||
| - source/hic_hal/nxp/lpc4322/RTE_Driver/GPDMA_LPC43xx.c | ||
| - source/hic_hal/nxp/lpc4322/RTE_Driver/SCU_LPC43xx.c |
There was a problem hiding this comment.
Please add these sources and includes to the lpc4322.yaml so they are common to all LPC4322 builds. Specifically, we want the generic lpc4322_if project to support SWO.
|
Hi @groleo, would you mind removing the RTE_Driver sources that aren't used? To answer your question, these files are specific to the LPC4322, so should stay under that folder. And yes, please move the |
|
Hi,
Got it. I'll move the lpc specific files.
If you ask me, it makes sense to have the "Driver_*" under
source/cmsis-driver.
The files are coming from a sub-directory with the same name, part of a
Kyle lpc-link2 sample.
I'll push a new p-r tomorow.
…On Thu, Jun 11, 2020, 10:21 PM Chris Reed ***@***.***> wrote:
Hi @groleo <https://github.com/groleo>, would you mind removing the
RTE_Driver sources that aren't used? To answer your question, these files
are specific to the LPC4322, so should stay under that folder.
And yes, please move the Driver_Common.h and Driver_USART.h headers. For
now, please place them directly under source/hic_hal/. Or do you think
source/cmsis-driver/ would be better?
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#712 (comment)>, or
unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAB2RYRTZBMCMOU5FJIQHNLRWEVEBANCNFSM4MXID7KA>
.
|
|
You don't need to create a new PR (please don't). Just force push (assuming you even need to) from the same branch, and it will update this PR. Let's put the CMSIS-Driver headers under |
This comment has been minimized.
This comment has been minimized.
1 similar comment
|
/morph test |
|
The ci-morph "Details" link is pointing to an internal IP: Is there another way I can see what went wrong ? |
|
v2: CMSIS-Driver headers under source/cmsis-driver as you prefer. |
|
/morph test |
Is there a way to see the CI failures ? |
|
It's internal server, I'll find out now |
This is the building error. |
| - SWO_UART=1 | ||
| - SWO_USART_PORT=1 |
There was a problem hiding this comment.
Is there a reason to restrict enabling SWO to only the RT1170-EVK and not enable on all LPC4322 boards? I know the LPCXpresso55S69 has SWO connected to the LPC4322.
There was a problem hiding this comment.
the only reason would be that I'm only testing on the RT1170-EVK board.
If you say I can enable SWO for other boards, it's ok with me, I can add a patch for those too.
source/board/mimxrt1170_evk.c
Outdated
| * @brief board ID for the NXP MIMXRT1170-EVK board. | ||
| * | ||
| * DAPLink Interface Firmware | ||
| * Copyright (c) 2009-2020, ARM Limited, All Rights Reserved |
There was a problem hiding this comment.
Please change the copyright to your own (or NXP's, as appropriate) for 2020-2021. The same applies to all other new files you added.
| static bool buf_empty; | ||
| static bool current_sector_valid; | ||
| static bool page_erase_enabled = false; | ||
| static bool page_erase_enabled = true; |
There was a problem hiding this comment.
I'm slightly concerned about making this change globally, only because most of the flash algos have not been tested in page erase mode. You can use set the kEnablePageErase flag in the board_info_t struct to set it per board (see frdmk64f.c for an example). It's probably safe to change it globally, but that would better be done in a separate PR.
There was a problem hiding this comment.
added kEnablePageErase to source/board/mimxrt1170_evk.c.
| #include "target_config.h" | ||
| extern target_cfg_t target_device ; | ||
|
|
||
| if(buf[0] == 'F' && buf[1] == 'C' && buf[2] == 'F' && buf[3] == 'B') | ||
| { | ||
| target_device.flash_regions[0].start = 0x30000400; | ||
| return 1; | ||
| } | ||
| else | ||
| else if(buf[0] == 0xFF && buf[1] == 0xFF && buf[2] == 0xFF && buf[3] == 0xFF) | ||
| { | ||
| return 0; | ||
| target_device.flash_regions[0].start = 0x30000000; | ||
| return 1; | ||
| } | ||
|
|
||
| return 0; |
There was a problem hiding this comment.
Nice hack! Would you mind adding some comments describing what this code does so we don't forget in the future? 😄
There was a problem hiding this comment.
From what I understand, if buf is a FlexSPI Config block (the "FCFB"/0x42464346 test), it moves the flash start address;
but I have no idea what the test against 0xFFFFFFFF part does; I see some other platforms have a "cookieList"
flit
left a comment
There was a problem hiding this comment.
The only changes requested are updating the copyrights, page erase mode default, and possibly enabling SWO on all LPC4322 based boards.
|
@groleo My apologies this PR has been outstanding for so long! Honestly I haven't been paying much attention since I've been primarily focused on pyocd. |
Signed-off-by: Alex Yang <alex.yang@nxp.com> Signed-off-by: Adrian Negreanu <adrian.negreanu@nxp.com>
Signed-off-by: Adrian Negreanu <adrian.negreanu@nxp.com>
It provides GetClockFreq() which is needed by USART_LPC43xx.
this provides definitions needed by GetClockFreq()
Signed-off-by: Adrian Negreanu <adrian.negreanu@nxp.com>
Signed-off-by: Adrian Negreanu <adrian.negreanu@nxp.com>
This way, one can set SWO_UART from the target's yaml. Signed-off-by: Adrian Negreanu <adrian.negreanu@nxp.com>
Signed-off-by: Adrian Negreanu <adrian.negreanu@nxp.com>
Signed-off-by: Adrian Negreanu <adrian.negreanu@nxp.com>
Signed-off-by: Adrian Negreanu <adrian.negreanu@nxp.com>
Signed-off-by: Adrian Negreanu <adrian.negreanu@nxp.com>
Signed-off-by: Adrian Negreanu <adrian.negreanu@nxp.com>
Signed-off-by: Adrian Negreanu <adrian.negreanu@nxp.com>
df0e372 to
67e6130
Compare
|
Superseded by #906. |
This p-r is adding support for NXP's i.MXRT1170-EVK board
and enables SWO for it.