Skip to content

Commit

Permalink
BF-018ARev.2.ino
Browse files Browse the repository at this point in the history
Fixed PWM parameters
  • Loading branch information
uehara00 committed Apr 27, 2023
1 parent 18da4b7 commit e1fb04f
Show file tree
Hide file tree
Showing 5 changed files with 46,138 additions and 21 deletions.
6 changes: 3 additions & 3 deletions BF-018ARev2/BF-018ARev2.ino
Original file line number Diff line number Diff line change
Expand Up @@ -146,9 +146,9 @@ const int marker(0xff); // marker code TcoValue() returns
// PWM for TCO signal
const uint8_t ledc_pin(22); // GPIO22 for TCO
const uint8_t ledc_channel(0);
const uint32_t ledc_frequency(60000); // 40kHz(east), 60kHz(west)
const uint8_t ledc_resolution(2); // 2^2 = 4
const uint32_t ledc_duty_on(2); // 2/4 = 50%
const uint32_t ledc_frequency(40000); // 40kHz(east), 60kHz(west)
const uint8_t ledc_resolution(8); // 2^8 = 256
const uint32_t ledc_duty_on(128); // 128/256 = 50%
const uint32_t ledc_duty_off(0); // 0

// real time
Expand Down
14 changes: 14 additions & 0 deletions BF-018ARev2/debug.cfg
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
# SPDX-License-Identifier: GPL-2.0-or-later
#
# Example OpenOCD configuration file for ESP32-WROVER-KIT board.
#
# For example, OpenOCD can be started for ESP32 debugging on
#
# openocd -f board/esp32-wrover-kit-3.3v.cfg
#

# Source the JTAG interface configuration file
source [find interface/ftdi/esp32_devkitj_v1.cfg]
set ESP32_FLASH_VOLTAGE 3.3
# Source the ESP32 configuration file
source [find target/esp32.cfg]
19 changes: 19 additions & 0 deletions BF-018ARev2/debug_custom.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
{
"name":"Arduino on ESP32",
"toolchainPrefix":"xtensa-esp32-elf",
"svdFile":"esp32.svd",
"request":"attach",
"postAttachCommands":[
"set remote hardware-watchpoint-limit 2",
"monitor reset halt",
"monitor gdb_sync",
"thb setup",
"c"
],
"overrideRestartCommands":[
"monitor reset halt",
"monitor gdb_sync",
"thb setup",
"c"
]
}
Loading

0 comments on commit e1fb04f

Please sign in to comment.