2015-04-24 update 1 fix a bug in AddressFormater

This commit is contained in:
parallelbgls@outlook.com
2015-04-24 10:46:21 +08:00
parent 1b1b68ddb0
commit a33423ab9e

View File

@@ -15,7 +15,7 @@ namespace ModBus.Net
{
public override string FormatAddress(string area, int address)
{
if (area.ToUpper() == "DB")
if (area.ToUpper().Substring(0,2) == "DB")
{
return area.ToUpper() + "." + "DB" + address;
}