[docs] Add debugging info for RPi 4, fix GPIO numbers
This commit is contained in:
@@ -5,6 +5,7 @@ Debugging of Realtek Ameba chips is possible and was tested with OpenOCD running
|
||||
*(the following is applicable to Arduino framework, and was not tested with SDK framework)*
|
||||
|
||||
LibreTuya has ready-to-use OpenOCD config files:
|
||||
|
||||
- [platform/realtek-ambz/openocd/amebaz.cfg](../../../platform/realtek-ambz/openocd/amebaz.cfg)
|
||||
|
||||
## Local debugger
|
||||
@@ -22,7 +23,18 @@ Using a Raspberry Pi is probably the easiest option (and cheapest, as everyone h
|
||||
|
||||
Connect your Realtek board to your Pi, as per [Programming Microcontrollers using OpenOCD on a Raspberry Pi](https://learn.adafruit.com/programming-microcontrollers-using-openocd-on-raspberry-pi).
|
||||
|
||||
TL;DR: Install OpenOCD. Conenct A14 to GPIO23, A15 to GPIO22. Remember to join GND together. Refer to [boards/](../../../boards/) for pinouts.
|
||||
Check out [RPi BCM2711 GPIOs](https://elinux.org/RPi_BCM2711_GPIOs) to read more about BCM pin mappings.
|
||||
|
||||
TL;DR: Install OpenOCD. Conenct A14 to BCM GPIO#11, A15 to BCM GPIO#25. Remember to join GND together. Refer to [boards/](../../../boards/) for pinouts.
|
||||
|
||||
!!! note
|
||||
On Raspberry Pi 4, additional config might be needed:
|
||||
```
|
||||
bcm2835gpio peripheral_base 0xFE000000
|
||||
bcm2835gpio speed_coeffs 236181 60
|
||||
```
|
||||
Save the lines to a .cfg file, and pass it to OpenOCD using `-f file.cfg`.
|
||||
Read more [here](https://forums.raspberrypi.com/viewtopic.php?p=1541631&sid=915e8d039f24301b85c060318a44b7f0#p1541631).
|
||||
|
||||
Start OpenOCD like this (you also need your config file in the working directory):
|
||||
```shell
|
||||
|
||||
Reference in New Issue
Block a user