Smart integration of silicon nanowire arrays in all-silicon thermoelectric micro-nanogenerators