Skip to content

STM32F030C8T6 Firmware Created for Epever XTRA1210N MPPT solar charge controller.

License

Notifications You must be signed in to change notification settings

he77PC011/xtra1210

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

18 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

xtra1210

STM32F030C8T6 Firmware Created for Epever XTRA1210N MPPT solar charge controller.

This is firmware for MCU STM32F030 (heart of EPEVER solar charge controllers).

WARNING: This is still under early development process. This is still for education purposes and do not expect working MPPT regulator without code changes !!! Author does not respond for possibly destroying Your device!

What is slightly implemented:

  • cs1621 chip driver for showing segments on XDS1 display
  • MODBUS RTU protocol for showing realtime data
  • ADC 10 channels in DMA mode
  • PWM complementary signal for pseudo-synchronous DC/DC step down converter working on 40kHz

STM32F030C8T6 pinout description: GPIO in:

  • PB14 XDS1 button 1
  • PB15 XDS1 button 2
  • PB10 output Vpv/Vbat comparator, set if Vbat > Vpv

GPIO out:

ADC in:

  • PA0 Vpv, I guess Vpv = x[0]*4962/1000 [100mV];
  • PA1 Vbat, I guess Vbat = x[1]*1967/1000 [100mV];
  • PA4 V?
  • PA2 thermal sensor
  • PA3 load current obtained using LMV932
  • PA5 battery current obtained using LMV932 (can be negative), I guess Ibat = (x[5]-0x170)*40/100
  • PA7 177mV reference (3v3-60k-PA7-3k9-GND)
  • PB0 another voltage reference

UART:

  • PA10 Rx
  • PA9 Tx
  • PB9 Rx/Tx switch (low means receive)

SPI (XDS1 driving):

  • PB3 nWR (clock)
  • PA15 nCR (NSS) must be set by software in this mode
  • PB5 data

headers on board:

  • PA12 - pin 2 PS1 heade
  • PB8 - pin1 P5 header

HOWTO build this source:

  • download STM32CubeMX
  • load xtra1210n.ioc from cloned path by git
  • select Makefile in ProjectManager->Project->toolchain inside STM32CubeMX
  • push GENERATE CODE button
  • all necessary files should be shown in your project folder obtained by git
  • build using arm-none-eabi-gcc and make
  • use J6 pin to connect ST-LINK V2, pins ordered from rectangled pin1 3v3, SWDIO, GND, SWCLK, RST (not needed)
  • use stm32-for-vscode plugin, Cortex-debug plugin and openocd to flash compiled code to the solar regulator

About

STM32F030C8T6 Firmware Created for Epever XTRA1210N MPPT solar charge controller.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • C 100.0%