Thanks @bridystone and @foxblock
The SevSegShift works very well for arduino uno, but it don't work for esp32. I have spend a hole day to find the problem, and finally two websites provide the solution.
1. Move two array digitPins and segmentPins which located in setup() to the global scope.
or
2. Add the code in SevSegShift.cpp and SevSegShift.h
Thanks @bridystone and @foxblock
The SevSegShift works very well for arduino uno, but it don't work for esp32. I have spend a hole day to find the problem, and finally two websites provide the solution.
1. Move two array
digitPinsandsegmentPinswhich located in setup() to the global scope.or
2. Add the code in SevSegShift.cpp and SevSegShift.h