Wykres commitów

4 Commity (3a723ad2fed6e4ea93b7c1a7ae4aee00471d96c9)

Autor SHA1 Wiadomość Data
Andrew Leech 4343c9330e stm32: Add method for statically configuring pin alternate function.
Works with pins declared normally in mpconfigboard.h, eg. (pin_XX), as well
as (pyb_pin_XX).

Provides new mp_hal_pin_config_alt_static(pin_obj, mode, pull, fn_type)
function declared in pin_static_af.h to allow configuring pin alternate
functions by name at compile time.
2018-07-20 14:03:21 +10:00
Damien George a7ebac2eae stm32/can: Allow CAN pins to be configured per board.
This patch allows a given board to configure which pins are used for the
CAN peripherals, in a similar way to all the other bus peripherals (I2C,
UART, SPI).  To enable CAN on a board the mpconfigboard.h file should
define (for example):

    #define MICROPY_HW_CAN1_TX (pin_B9)
    #define MICROPY_HW_CAN1_RX (pin_B8)
    #define MICROPY_HW_CAN2_TX (pin_B13)
    #define MICROPY_HW_CAN2_RX (pin_B12)

And the board config file should no longer define MICROPY_HW_ENABLE_CAN.
2018-04-11 16:35:24 +10:00
Damien George 0041396f05 stm32/pin: In pin AF object, remove union of periph ptr types.
The individual union members (like SPI, I2C) are never used, only the
generic "reg" entry is.  And the union names can clash with macro
definitions in the HAL so better to remove them.
2018-04-11 16:14:58 +10:00
Damien George 4a93801c12 all: Update Makefiles and others to build with new ports/ dir layout.
Also renames "stmhal" to "stm32" in documentation and everywhere else.
2017-09-06 14:09:13 +10:00