-
Notifications
You must be signed in to change notification settings - Fork 2
Tm/jtag #32
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Tm/jtag #32
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This patch add basic routines for ADIv5. Possibly more of routines will be needed in future. Functions has to be added to ADIV5_AP_OPS_t.
This patch add memory routines to adiv5.c. This functions allow to read and write target's memory.
This patch add CortexM routines that will be needed to upload program to RAM of target device.
TMS and TDI should be set before rise of TCK. TDO should be read before fall of TCK. Add TMS parameter when passing TDI and reading TDO, because it can be done during transition from Shift-IR/DR to Exit1-IR/DR.
This patch expose CortexM specific operations for higher level driver.
This patch add routines that allow to program STM32F4xxx.
This patch add target.c which in future will contain functions that allow to register different targets. Target will have opaerations and private data that will be passed to all of its function. This allow to add abstraction over programmed targets. This patch also fix places where structure should be free in case of probing failure.
Add "STM32F4_" prefix to all defines in stm32f4.h, because some of them are defined in Drivers/CMSIS/Device/ST/STM32F4xx/Include/stm32f429xx.h.
Sizeof return size in bytes, fixed assert in jtag_tdin. Don't skip devices without IDCODE. They still need to by bypassed. jtag_tdi return int now.
This patch add jtag_test function that allow to check by analizing output if connection is correct (you could shift DR in the loop and see IDCODEs and leater bits that where shifted in) TDO is changed to input insted of output (it is our input, TDO is output for debuged device). Low level JTAG logic is changed. Now it holds TCK up until next jtag_tdi request is issued. TCK is set to low in the same moment when TDI and TMS are setup. TDI is read right after rising edge of TCK.
Loop for next device while reading IR length will start with two bits readed instead of one.
This patch fix issues in low level JTAG driver that doesn't allow to identify STM32F4xx.
This patch fix flashing routine in four places: - Fix loop that detect EOF. - While erasing flash EOP is checked in FLASH_SR. EOP is only set if first in FLASH_CR value is set in register. - cortex pointer is saved in STM32F4_PRIV on successful detection. - Buffer for data that will be writen to target is now allocated on heap, no on stack, because leater one is more limited. Additionaly dealy on JTAG TCK is changed to allow faster transmision (currently it is aproximetly 15kHz).
Now target could be reset. Reset is also called after programing target.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
In this patchset connection to STM32F4xx via JTAG is added.