Closed mrRobot62 closed 1 year ago
@jeroenSt
There's a problem with Settings->modbus_sbaudrate
. As a uint8_t
it's not working for baudrate above 76500.
The easiest would be to use a uint16_t but that would mean a breaking change to move the value else where.
Or split in hi and low and split/combine as needed until we can refactor the Settings
Or is there a way to add an upgrade rule @arendst?
@mrRobot62 Can you please advise what devices you are using that is needing 115200 ? That doesn't seem much common to have such bit rate in Modbus
@barbudor thanks for your response and your explanation.
Out from a doc "B-Series MODBUS Specification EPEVER Corporation, 2.3" I read the information
The B-Series controller supports RTU mode only. 16bit MODBUS addresses (per the modbus.org spec) The serial communication parameters are
BPS:115200 baud
Parity: None
Data bits: 8
Stop bits:1
Flow control: None
All addresses listed are for the request PDU.
My Model: EPEVER XTRA 4415N
I asked EPVER to send me a specification about their RS485 interface and what registers... are used, unfortunately the sup port was not very helpful. They didn't send me anything. Searching via Google I found attached spec. EPEVER_ControllerProtocolV2.3.pdf
Hope my understanding of this spec is ok :-/
BTW (additional info)
If I use 9600 baud and send as example from tasmota console this command
modbussend {"deviceaddress":1, "functioncode":3, "startaddress":1, "type":"uint16","count":4}
I got no repsonse from the charger. However, I do not get any response from the charger
Unless @jeroenst can provide a fix quickly I can look at it this weekend as I am too much busy with real life work
If you can't wait and are able to compile a change yourself, you can hardcode the value 115200 in xdrv_63_modbus_bridge.ino line 198
int result = modbusBridgeModbus->Begin(115200, ConvertSerialConfig(Settings->modbus_sconfig));
That should do the trick
I'll change it to uint16_t like other baudrates now. Hold on.
@barbudor & @arendst : wow - that's awesome from you !
Thanks a lot !!!!
@arendst : I saw your commit - sorry for this stupid question, were can I download the bin file with this bugfix - uhhhh blame on me ;-)
Now, you made me smile :) Where did you get the version with the problem? Birthday present on an USB stick?
But then, I didn't find it by the docs, too. My first try github -> releases -> release notes only talks about URLs for releases. You would have to know for development versions you have to delete the /release part. Or find it elswhere in the extensive tasmota docs.
TL;DR: http://ota.tasmota.com/tasmota/ Have fun!
Or just read the README at https://github.com/arendst/Tasmota#readme and find the link below the heading Development....
short update (and than I move to the discussion group), because maybe it's an mistake on my side or something else, so my hope is on the discussion board it's a better place for this issue
modbusbaudrate 115200
it's possible to change to 115200
20:00:54.564 CMD: modbusbaudrate
20:00:54.579 MQT: stat/solar/RESULT = {"ModbusBaudrate":115200}
modbusserialconfig 702
I set "8N1"
20:10:10.994 CMD: modbusserialconfig 702
20:10:11.005 MQT: stat/solar/RESULT = {"ModbusSerialConfig":"8N1"}
modbussend...
I tried to read EPEVER register on 0x3100
20:12:19.651 CMD: modbussend {"deviceAddress":1, "functionCode":2, "startAddress":12544, "type":"uint8","count":4}
20:12:19.663 MQT: stat/solar/RESULT = {"ModbusSend":"Done"}
nothing more :-/
See - discussion - problem solved - problem was 30cm in front of the screen - omg - See Discussion
PROBLEM DESCRIPTION
If I set
modbusbaudrate 115200
response is alwaysstat/modbus/RESULT = {"ModbusBaudrate":38400}
If i restart my esp32, default baud rate is set to 9600
Below log output from my tasmota device:
I tried this with several other baudrates , seems 57600 is max. Unfortunately my EPEVER XTRA 4415N is set to 115200
Any idea what I can do?
REQUESTED INFORMATION
Make sure your have performed every step and checked the applicable boxes before submitting your issue. Thank you!
Backlog Template; Module; GPIO 255
:Status 0
:TO REPRODUCE
Steps to reproduce the behavior:
EXPECTED BEHAVIOUR
A clear and concise description of what you expected to happen.
SCREENSHOTS
If applicable, add screenshots to help explain your problem.
ADDITIONAL CONTEXT
Add any other context about the problem here.
(Please, remember to close the issue when the problem has been addressed)