platform-shakti
platform-shakti copied to clipboard
Debugging support
Hi @sathya281! Could you please describe (or ask someone who knows) how you debug your boards at the moment? What software, debug probe, target do you use (for example artix7_100t
board)?
Hi,
First of all thanks for the platform support.
Hope below answer helps you:
Board : artix7_100t and artix7_35t debug probe: ftdi interface connected through riscv openocd Debugger: riscv gnu GDB, 32 bit / 64 bit
For openocd, we want to use below commit. This has ftdi support. https://github.com/riscv/riscv-openocd/tree/fd9c54b1feea13f6846c69fc9e1e8dc3a7879717
regards, Sathya
Could you post here a simple command for openocd with all arguments that you are using?
command - sudo openocd -f spike.cfg
contents of spike.cfg #interface_list interface jlink debug_level 2
#interface remote_bitbang #interface usb_blaster
#remote_bitbang_host localhost #remote_bitbang_port 10000
set _CHIPNAME riscv jtag newtap $_CHIPNAME cpu -irlen 5 -expected-id 0x100039d3 #jtag newtap $_CHIPNAME cpu -irlen 5 -expected-id 0x10e31913
set _TARGETNAME $_CHIPNAME.cpu target create $_TARGETNAME riscv -chain-position $_TARGETNAME
adapter_khz 900 #$_TARGETNAME configure -event reset-start { adapter_khz 200 } #riscv set_prefer_sba on gdb_report_data_abort enable
init halt
This one is for ftdi stuff command - sudo openocd -f spike.cfg
contents of spike.cfg debug_level 1 adapter_khz 8000 interface jlink gdb_port 3333 telnet_port 4444 tcl_port 6666
set _CHIPNAME riscv jtag newtap $_CHIPNAME cpu -irlen 5 -expected-id 0x100039D3
set _TARGETNAME $_CHIPNAME.cpu target create $_TARGETNAME riscv -chain-position $_TARGETNAME
gdb_report_data_abort enable
riscv set_prefer_sba on
init
In both scripts, jlink
is specified as the interface: interface jlink
. Is that right?
Hey sorry, Thanks for pointing it out.
I have listed below the config files for both the debug probe.
- FTDI support
sudo openocd -f ftdi_spike.cfg ftdi_spike.cfg
- JLINK support
sudo openocd -f jlink_spike.cfg jlink_spike.cfg
Any plans for adding those scripts to the official shakti-sdk
repository? At the moment there is only one spike.cfg
for jlink debug probe.
We are working on it. In 24hrs, we will add.
On Wed, 10 Jul, 2019, 6:03 PM Valerii Koval, [email protected] wrote:
Any plans for adding those scripts to the official shakti-sdk repository? At the moment there is only one spike.cfg for jlink debug probe.
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/platformio/platform-shakti/issues/1?email_source=notifications&email_token=ABEPUPM7FK3Z4JXAR2ZAKR3P6XJKDA5CNFSM4H7HM7NKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGODZTJ4EI#issuecomment-510041617, or mute the thread https://github.com/notifications/unsubscribe-auth/ABEPUPKYIGRMQXYO4JRLTH3P6XJKDANCNFSM4H7HM7NA .
Hi, you can check now. The SDK is updated.
I went through the code. We need to change lots of data in JSON file
Sure thing, feel free to submit a PR.
@valeros how do i pull /use this in pio ? i don't see any entry added for the boards mentioned.
You need to install this platform from the git repository, in case you are using the command line version:
pio platform install https://github.com/platformio/platform-shakti.git
or PIO Home -> Platforms -> Advanced Installation
in the IDE
Yes i was able to load the platform into the ide , as part of the board entries i don't find the boards as part of shakti-platform.
I'm not sure I understand your question. Can you please describe in detail what you're trying to achieve?
I was trying to understand how to add the board entry (ie), when you create a project it should be able to point to the designated board which we have support for eg - artix7_100t or artix7_35t also along with the SDK.
So i discussed with @sathya281 , i will make the changes and submit a PR soon.