Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Compillation error for Generic STM32F103C #137

Open
Sergey-R5AU opened this issue Feb 19, 2023 · 4 comments
Open

Compillation error for Generic STM32F103C #137

Sergey-R5AU opened this issue Feb 19, 2023 · 4 comments

Comments

@Sergey-R5AU
Copy link

Sergey-R5AU commented Feb 19, 2023

Hi !
I have error with compillation keyer code for STM32 Blue Pill board:


C:\Users\r5au\Documents\Arduino\k3ng_cw_keyer-master\k3ng_keyer\k3ng_keyer.ino:1536:4: error: #error "You cannot define paddle_left or paddle_right as 0 to disable"
#error "You cannot define paddle_left or paddle_right as 0 to disable"
^
Multiple libraries were found for "Wire.h"
Used: C:\Users\r5au\AppData\Local\Arduino15\packages\stm32duino\hardware\STM32F1\2022.9.26\libraries\Wire
Not used: C:\Users\r5au\AppData\Local\Arduino15\packages\stm32duino\hardware\STM32F1\2022.9.26\libraries\WireSlave
exit status 1

Compilation error: #error "You cannot define paddle_left or paddle_right as 0 to disable"

Arduino IDE version 2.0.3 64bit

STM32 board support with http://dan.drown.org/stm32duino/package_STM32duino_index.json

What is wrong ?
Copmpillation for Arduino nano without troubles

@k3ng
Copy link
Owner

k3ng commented Feb 19, 2023 via email

@Sergey-R5AU
Copy link
Author

Sergey-R5AU commented Feb 19, 2023

Hi Antony !
Thank you for reply !
in my definitions: keyer_pin_settings_generic_STM32F103C.h looks like:

GENERIC STM32F103C Blue Pill board

*/

/* Pins - you must review these and configure ! */
#ifndef keyer_pin_settings_h
#define keyer_pin_settings_h

#define paddle_left PA1
#define paddle_right PA0
#define tx_key_line_1 PC15 // (high = key down/tx on)
.
.

or i should directly wrote here pins nr from Blue Pill, like:
#define paddle_left 11
#define paddle_right 10
following with attached pic ?

stm32-pin-details_0

@Sergey-R5AU
Copy link
Author

For tetsing purpose i did as abose
#define paddle_left 11
#define paddle_right 10

however next stop with Serial Port:

C:\Users\r5au\Documents\Arduino\k3ng_cw_keyer-master\k3ng_keyer\k3ng_keyer.ino: In function 'void initialize_serial_ports()':
C:\Users\r5au\Documents\Arduino\k3ng_cw_keyer-master\k3ng_keyer\k3ng_keyer.ino:18238:25: error: cannot convert 'HardwareSerial' to 'USBSerial' in assignment
primary_serial_port = PRIMARY_SERIAL_PORT;

Compilation error: cannot convert 'HardwareSerial' to 'USBSerial' in assignment

probably somwhere in definitions files port assigment are wrong ? 'HardwareSerial' <-> 'USBSerial' ?

@pe1cim
Copy link

pe1cim commented Mar 14, 2023

Do you have the correct board loaded ?
Load the stm boards on IDE.
Preferences -> Board Manegers URL
Use :https://github.com/stm32duino/BoardManagerFiles/raw/main/package_stmicroelectronics_index.json

I have now the same error :
error: cannot convert 'HardwareSerial*' to 'USBSerial*' in assignment
primary_serial_port = PRIMARY_SERIAL_PORT;

line 18246 k3ng_keyer.ino

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants