Centre-align STM32 PWM with the TIM CMS bits
Centre-align STM32 PWM with the CMS bits in TIMx_CR1, which counts up and down and halves the PWM frequency for the same reload value.
Short posts that solve one thing: the code, the output we got, and why it works.
Centre-align STM32 PWM with the CMS bits in TIMx_CR1, which counts up and down and halves the PWM frequency for the same reload value.
Read one STM32 ADC channel in polling mode with HAL_ADC_Start, HAL_ADC_PollForConversion and HAL_ADC_GetValue, and convert the result to millivolts.
Return a TinyUSB device descriptor from tud_descriptor_device_cb with a static tusb_desc_device_t, using the IAD class codes a composite CDC device needs.
Accept exactly four CAN standard IDs on STM32 bxCAN with one filter bank in 16-bit identifier list mode, shifting each ID left by five.
Raise the Arduino I2C bus to 400 kHz by calling Wire.setClock(400000) after Wire.begin, and see what TWBR holds on a 16 MHz ATmega328P.
Place a variable in AVR EEPROM with the EEMEM attribute from avr-libc 2.2, read it with eeprom_read_byte, and upload the .eep file too.
Divide a 16-bit value by 10 on Cortex-M0 with one 32-bit multiply and a shift, exact for every input, instead of a slow library division call.
Set MIX_TARGET to a Nerves target such as rpi4 before running mix commands, so dependencies and the firmware are built for the board and not the host.
Make the STM32L4 independent watchdog start by itself at reset by clearing the IWDG_SW option bit, so a boot hang cannot go unnoticed.
Stop --gc-sections from deleting an interrupt vector table nothing references by wrapping its input section in KEEP() in a GNU ld linker script.
Stop an ESP32 pin leaking current during deep sleep by calling rtc_gpio_isolate on an RTC-capable pin in ESP-IDF v5.4 before sleeping.
i2c_smbus_read_byte_data() reads one 8-bit register from an I2C client in a single call and returns the value or a negative errno (Linux 6.12).
We send one email when a new post is published. No spam.