Chat here about code rewrites, mods, etc... with respect to the github project https://github.com/esp8266/Arduino

Moderator: igrr

User avatar
By George Hlavacs
#45535 Hi Scott,

I saw your interesting work on connecting arduino with a Voltronic Axpert inverter.
I would like to switch the inverter from UPS mode to SBU (off grid) by sending a command from my arduino.
Can you give me a tip how I can do that simply?

Best regards,

George
User avatar
By Ariel
#48681 Today I had a personal breakthrought which I hope will be useful to the community.
I modified the SoftwareSerial library to add the possibility of defining pins in setup() while maintaining global scope for the SeftwareSerial object.
This means it is possible to define SoftwareSerial pins with values recovered from EEPROM.
It works for sure once after startup, it should also give the possibility to change serial pins during program execution, but I haven't tried it (actually I might).
Here it is: https://github.com/Ariel-International/ ... areserial2
User avatar
By Ariel
#48682
Ariel wrote:It works for sure once after startup, it should also give the possibility to change serial pins during program execution, but I haven't tried it (actually I might).


I tested it and it works like a charm!
You can switch SoftwareSerial pins during program execution.
Default speed is 9600 baud, to set different speed one must run:
<serialname>.begin(<baudrate>) ;
each time after the attach statement.