Bruno Salvador
2014-Jun-04 12:44 UTC
[Nut-upsuser] Unable to set up a "serial-over-USB" UPS (APC BZ2200BI-BR)
Hello Charles and Douglas, I really believe that BZ2200-BR model is the same as mine BZ1200-BR, with different capacity. If you see the BZ2200-BR specs you will notice the manufacturer "APC-Microsol". Those no-breaks have a USB port in it, but in fact it is a serial<->usb cable, usually uses the port "/dev/cuaU0". In mine, the serial<->usb chip is from FTDI, and its recognized by FreeNAS with any additional drivers. And for sure, you can never use the genuine APC driver with those Microsol nobreaks. What Douglas can do is to patch the solis executable in /usr/local/libexec/nut/solis inside freenas, with the patches that I have posted in the forum: This will work for FreeNAS last version 9.2.1.5. http://forums.freenas.org/index.php?threads/nobreak-bz1200-br-back-ups-rs-1200va-600w-bivolt-115-nt.20247/ *Instructions: * 1) Open the "*/usr/local/libexec/nut/solis*" executable in any hex editor 2) Search for the bytes 3D *A0* 00 00 00 75 8D 80 3D 77 11 21 00 FE 75 84 3) Change the "*A0*" to "*B0*" 4) Search for the bytes: *76* 29 BF A6 9C 40 00 E8 C7 F9 FF FF E9 15 FF FF 5) Change the "*76" *for* "EB"* 6) Save the file 7) Mount as write the Freenas filesystem using *mount -uw /* 8) Copy the cracked solis to* /usr/local/libexec/nut* 9) Mount the filesystem as readonly *mount -ur /* 10) Reboot. As soon as I discover what are the configure settings that FreeNAS uses to complile NUT, I'll create a original driver and send to NUT project to be included on next versions. Let me know if you need any more info. BR Bruno 2014-06-04 9:09 GMT-03:00 Charles Lepple <clepple at gmail.com>:> On Mar 20, 2014, at 10:01 AM, Douglas A. Augusto wrote: > > > Dear NUT users/developers, > > > > I'm having trouble while trying to configure the UPS APC BZ2200BI-BR[1] > in NUT, > > which despite having a USB cable it apparently communicates using the > serial > > protocol. > > > > The relevant output of 'lsusb' is: > > > > Bus 002 Device 004: ID 051d:c812 American Power Conversion > > > Douglas, > > It sounds like you have an UPS which was originally manufactured by > Microsol. > > > http://forums.freenas.org/index.php?threads/nobreak-bz1200-br-back-ups-rs-1200va-600w-bivolt-115-nt.20247/ > > http://article.gmane.org/gmane.comp.monitoring.nut.devel/6685 > > Bruno, > > Does your UPS show up as a USB ACM device in FreeBSD? Do you think that > you and Douglas have the same basic UPS with different battery capacities? > > http://article.gmane.org/gmane.comp.monitoring.nut.user/8443 > > -- > Charles Lepple > clepple at gmail > > > >-------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.alioth.debian.org/pipermail/nut-upsuser/attachments/20140604/1df16ac1/attachment.html>
Douglas A. Augusto
2014-Jun-10 17:56 UTC
[Nut-upsuser] Unable to set up a "serial-over-USB" UPS (APC BZ2200BI-BR)
On 04/06/2014 at 09:44, Bruno Salvador <bruno.salvador at gmail.com> wrote:> What Douglas can do is to patch the solis executable in > /usr/local/libexec/nut/solis inside freenas, with the patches that I have > posted in the forum:Dear guys, Following your suggestions I was able to make NUT recognize my UPS model. Actually, the only modification I had to introduce in solis.c was to change this line: if( ( (RecPack[0] & 0xF0) == 0xA0 ) to if( ( (RecPack[0] & 0xF0) == 0xA0 || (RecPack[0] & 0xF0) == 0xB0 ) Unfortunately some important information, as for instance the battery charge, do not work (e.g., battery charge is always zero). But at least now I have access to whether the UPS is on battery or not. Please let me know if you are interested in fully supporting such class of Microsol UPS in the upstream version. I do not understand the whole thing to do it on my own, but I am willing to help you on this. Thank you very much. Best regards, -- Douglas A. Augusto
Charles Lepple
2014-Jun-15 19:12 UTC
[Nut-upsuser] Unable to set up a "serial-over-USB" UPS (APC BZ2200BI-BR)
On Jun 10, 2014, at 1:56 PM, Douglas A. Augusto wrote:> On 04/06/2014 at 09:44, > Bruno Salvador <bruno.salvador at gmail.com> wrote: > >> What Douglas can do is to patch the solis executable in >> /usr/local/libexec/nut/solis inside freenas, with the patches that I have >> posted in the forum: > > Dear guys, > > Following your suggestions I was able to make NUT recognize my UPS model. > Actually, the only modification I had to introduce in solis.c was to change > this line: > > if( ( (RecPack[0] & 0xF0) == 0xA0 ) > > to > > if( ( (RecPack[0] & 0xF0) == 0xA0 || (RecPack[0] & 0xF0) == 0xB0 )Thanks for testing that. I committed this as 533dbf7 on the master branch. I will try to add some text to the apcsmart driver man page to point users to the solis driver if they have APC/Microsol equipment. I am open to suggestions on how to word this.> Unfortunately some important information, as for instance the battery charge, > do not work (e.g., battery charge is always zero). But at least now I have > access to whether the UPS is on battery or not.Bruno's post mentioned something about changing the call to ScanReceivePack(), but I'm not sure I follow that part.> Please let me know if you are interested in fully supporting such class of > Microsol UPS in the upstream version. I do not understand the whole thing > to do it on my own, but I am willing to help you on this.The next step, assuming the manufacturer does not publish protocol specifications, is to monitor the communication between the vendor software and your UPS. I wouldn't recommend doing this during normal operation, especially if the shutdown commands need to be tested. Assuming that the vendor software runs on Windows, you can use something like Portmon from Sysinternals: http://technet.microsoft.com/en-us/sysinternals/bb896644 It has been a while since I had to use Portmon, but email the list if you have any questions about setting it up. -- Charles Lepple clepple at gmail