3rdparty
: Third party code and dependenciescmake
: Additional CMake scripts used to configure and build the projectdata
: Resources embedded in the final binaryhardware_design
: Hardware design filesmain
: ESP IDF componentsrc
: Source codesrc/include
: Header filestest
: Unit tests (meant to be run on PC)
After setting up the ESP IDF build environment and making sure the tools are available in your PATH, run:
idf.py build # Build the source code
idf.py -p <port> flash
idf.py -p <port> monitor
Make sure you have CMake and CTest available in your PATH and a C and C++ compiler available.
Run:
mkdir build && cd build
cmake .. && cmake --build .
ctest
Design files for PowerMonitor hardware for development:
- SPD_PowerMonitor-AFE - board containing the analog frontend and isolation barrier
- SPD_PowerMonitor-Controller - board containing the ESP32 MCU with RS485 and USB for software debugging
Characteristics:
- Designed to fit into a 2 DIN Module SPD base enclosure
- Instead of Ethernet and 24V AC power the controller has a USB transciever chip to ease development
- Powered by USB 5V DC
- Breakout headers for internal SPI bus in order to experiment with external RAM
- Breakout headers for I2C bus to add ST NFC module for configuration loading
- Shunt mounted directly on the SPD spade plugs
Notes
From software side this is the final design, any changes to hardware should be transparent to software. On hardware side, because of chip shortages and especially the low availability of the isolated power supply for the AFE, this design will have to be modified to use other ICs that are available. Analog FE will not change.