Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
41 changes: 36 additions & 5 deletions config/project.yml
Original file line number Diff line number Diff line change
@@ -1,10 +1,7 @@
options:
USE_CORE:
name: local
url: http://blabla
SEND_JOB_START_TOKEN: true
# INCLUDE:
# - filename

compile:
compile-psoc6-cy8ckit_062s2_ai:
Expand Down Expand Up @@ -64,7 +61,7 @@ unit-test:

unit-test-tone:
- description: Compiling, flashing and monitoring tone, no-tone unit test.
command: make test_digitalio_single
command: make test_tone_no_tone
query: tone_no_tone_single_board == '1:1'
working_dir: extras/arduino-core-tests

Expand Down Expand Up @@ -118,4 +115,38 @@ unit-test:
- description: Compiling, flashing and monitoring I2C single board unit test.
command: make test_wire_connected1_pingpong
query: iic_ping_pong_single_board == '1:1'
working_dir: extras/arduino-core-tests
working_dir: extras/arduino-core-tests

unit-test-analog-io-adc:
- description: Compiling, flashing and monitoring ADC unit test.
command: make test_analogio_adc
query: analogio_adc_single_board == '1:1'
working_dir: extras/arduino-core-tests

unit-test-analog-io-pwm:
- description: Compiling, flashing and monitoring PWM unit test.
command: make test_analogio_pwm
query: analogio_pwm_single_board == '1:1'
working_dir: extras/arduino-core-tests

unit-test-pulse:
- description: Compiling, flashing and monitoring Advanced IO Pulse unit test.
command: make test_pulse_board1
query: adv_io_pulse_board1 == '1:1'
working_dir: extras/arduino-core-tests

- description: Compiling, flashing and monitoring Advanced IO Pulse unit test.
command: make test_pulse_board2
query: adv_io_pulse_board2 == '1:1'
working_dir: extras/arduino-core-tests

unit-test-uart:
- description: Compiling, flashing and monitoring UART RX unit test.
command: make test_uart_rx
query: uart_multiple_boards_rx == '1:1'
working_dir: extras/arduino-core-tests

- description: Compiling, flashing and monitoring UART TX unit test.
command: make test_uart_tx
query: uart_multiple_boards_tx == '1:1'
working_dir: extras/arduino-core-tests
4 changes: 4 additions & 0 deletions config/user.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,3 +8,7 @@ unit-test:
- unit-test-tone
- unit-test-spi-loopback
- unit-test-iic-single-board
- unit-test-analog-io-adc
- unit-test-analog-io-pwm
- unit-test-pulse
- unit-test-uart
2 changes: 1 addition & 1 deletion cores/psoc6/analog_io.c
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ static cyhal_adc_t adc_obj = {0};
static cyhal_adc_vref_t desiredVRef = CYHAL_ADC_REF_VDDA;
static bool adc_initialized = false;
static adc_channel_t adc_channel[ADC_HOWMANY] = {0};
static int desiredReadResolution = ADC_RESOLUTION;
static int desiredReadResolution = ADC_RESOLUTION - 1; // 11-bit ADC resolution
static float desiredWriteResolution = PWM_RESOLUTION_8_BIT;
static pwm_t pwm[PWM_HOWMANY] = {0};

Expand Down
1 change: 1 addition & 0 deletions tests/cy8ckit-062s2-ai-hil-test-table.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@
| | | | |
|Advanced IO Pulse | P9.5 | P9.5 | IO5 (Pulse Output) to |
| | | | IO5 (Pulse Input) |
| | P9.4 | P9.4 | IO synch signal |
| | | | |

# Pin Connections for HIL Test Setup on Single Board
Expand Down
3 changes: 2 additions & 1 deletion tests/test_config.h
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,8 @@
#define TEST_PIN_ANALOG_IO_VREF A0 // Pin connected to VREF
#define TEST_PIN_ANALOG_IO_DIVIDER A1 // Pin connected to voltage divider

#define TEST_ADC_RESOLUTION 2048 // 11-bit resolution
#define TEST_ADC_RESOLUTION 11
#define TEST_ADC_MAX_VALUE 2048 // 11-bit resolution

// Forward declarations for SPI instances
extern SPIClassPSOC SPI1;
Expand Down
Loading