Add TURBO_200MHZ define to support 200Mhz system clock
125Mhz system clock - 31.25Mhz sample rate (logic analyzer) 200Mhz system clock - 50Mhz sample rate (logic analyzer) Signed-off-by: Jaroslav Kysela <perex@perex.cz>
This commit is contained in:
parent
07e8a92a3b
commit
d18b0129a1
|
@ -21,6 +21,11 @@ if (DEFINED ENV{PICOPROBE_LED})
|
||||||
target_compile_definitions(picoprobe PRIVATE PICOPROBE_LED=$ENV{PICOPROBE_LED})
|
target_compile_definitions(picoprobe PRIVATE PICOPROBE_LED=$ENV{PICOPROBE_LED})
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
if (DEFINED ENV{TURBO_200MHZ})
|
||||||
|
message("TURBO_200MHZ is defined as " $ENV{TURBO_200MHZ})
|
||||||
|
target_compile_definitions(picoprobe PRIVATE TURBO_200MHZ=$ENV{TURBO_200MHZ})
|
||||||
|
endif()
|
||||||
|
|
||||||
set(DBG_PIN_COUNT=4)
|
set(DBG_PIN_COUNT=4)
|
||||||
|
|
||||||
pico_generate_pio_header(picoprobe ${CMAKE_CURRENT_LIST_DIR}/src/probe.pio)
|
pico_generate_pio_header(picoprobe ${CMAKE_CURRENT_LIST_DIR}/src/probe.pio)
|
||||||
|
|
|
@ -31,6 +31,10 @@
|
||||||
#include "tusb.h"
|
#include "tusb.h"
|
||||||
|
|
||||||
#include "picoprobe_config.h"
|
#include "picoprobe_config.h"
|
||||||
|
#if TURBO_200MHZ
|
||||||
|
#include "pico/stdlib.h"
|
||||||
|
#include "hardware/vreg.h"
|
||||||
|
#endif
|
||||||
#include "probe.h"
|
#include "probe.h"
|
||||||
#include "cdc_uart.h"
|
#include "cdc_uart.h"
|
||||||
#include "cdc_sump.h"
|
#include "cdc_sump.h"
|
||||||
|
@ -49,6 +53,11 @@ void tud_cdc_line_coding_cb(uint8_t itf, cdc_line_coding_t const* line_coding) {
|
||||||
|
|
||||||
int main(void) {
|
int main(void) {
|
||||||
|
|
||||||
|
#if TURBO_200MHZ
|
||||||
|
vreg_set_voltage(VREG_VOLTAGE_1_15);
|
||||||
|
set_sys_clock_khz(200000, true);
|
||||||
|
#endif
|
||||||
|
|
||||||
board_init();
|
board_init();
|
||||||
usb_serial_init();
|
usb_serial_init();
|
||||||
cdc_uart_init();
|
cdc_uart_init();
|
||||||
|
|
|
@ -45,6 +45,9 @@
|
||||||
#define picoprobe_dump(format,...) ((void)0)
|
#define picoprobe_dump(format,...) ((void)0)
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#if false
|
||||||
|
#define TURBO_200MHZ 1
|
||||||
|
#endif
|
||||||
|
|
||||||
// PIO config
|
// PIO config
|
||||||
#define PROBE_SM 0
|
#define PROBE_SM 0
|
||||||
|
|
Loading…
Reference in New Issue