I finally find a little time to integrate your fox. Thanks a lot.
On 15 avr, 20:57, Ardison Nicolas <
nicolas....@gmail.com> wrote:
> Hi Luc, thanks for your reply,
> I found the bug, it's a problem with variable types, in the "Master" class
>
> class Master:
> def __init__(self, protocol, address, id, db):
>
> if protocol == "tcp":
>
> try:
> (host, port) = address.split(":")
> self.modbus = modbus_tcp.TcpMaster(host, port)
>
> The variables in red must be casted, the host to string and the port to int.
> (Really only the port to int, because the split() function returns a array
> of strings, but to keep the thinks clear i put the cast in both variables.
>
> So here it's the class solved.
> class Master:
> def __init__(self, protocol, address, id, db):
>
> if protocol == "tcp":
>
> try:
> (host, port) = address.split(":")
> self.modbus = modbus_tcp.TcpMaster(str(host), int(port))
>
> Now works good, i'm using Python 2.6.4
>
> On 12 April 2011 02:14, Luc JEAN <
luc.j...@gmail.com> wrote:
>
>
>
>
>
>
>
>
>
> > Hello Nicolas,
> > The webhmi is somehow an experimental feature. It may have some troubles.
> > Can you try to modify the show_results function in master_webhmi.py and
> > catch all exceptions. It will help you to understand what's wrong.
> > I hope it helps
> > Best
> > luc
>
>
> > Hello there,
> >> I have a device that have a Modbus TCP/IP server working good in port
> >> 8000.
> >> I tried to put WebHMI in work, adding the device with the format
> >> IpAdress:Port, and some variable to see, but when i clicked in "view"
> >> it don't work.
>
> >> I got the message (In the browser), (url:
> >>
http://localhost:8075/modbus-read/5/1/3/200/16
> >> )
>
> >> [START MESSAGE]
> >> Error 500: Internal Server Error
>
> >> caused an error:
>
> >> Unhandled exception
> >> [END MESSAGE]
>
> >> in the console i got the message
> >> localhost - - [11/Apr/2011 16:58:49] "GET /modbus-read/5/1/3/200/16
> >> HTTP/1.1" 500 716
>
> >> I have never used bottlepy, but i think that it's a problem with it.
>
> >> Thanks
>
> >> Cheers
>
> >> Nicolas Ardison
> >> Lanus, BA - Argentina
>
> > --
> >
http://www.apidev.fr
>
> --
> Nicolas G. Ardison