Setup that I was on mind is a little different, but I think your setup works well. In my setup the HUB is connected directly to the UPS, then the cables go to raspberry and device. In your setup the HUB is connected directly to the raspberry, then the cables go to UPS and Device. It?s Ok? In both configurations I need the same things: Male B->female A adaptor, HUB and 2 male A-> male A cables. The male A- male A cables have any peculiarity? Can I buy it or make it myself without problems? Thanks a lot for advice. Da: Charles Lepple [mailto:clepple at gmail.com] Inviato: marted? 20 gennaio 2015 14:23 A: Maurizio Iacaruso Cc: NUT List Oggetto: Re: [Nut-upsuser] R: NUT and relay on USB On Jan 20, 2015, at 7:43 AM, Maurizio Iacaruso <maurizio.iacaruso at gmail.com <mailto:maurizio.iacaruso at gmail.com> > wrote: I connect USB A (female) to USB B (male) adapter -> HUB -> 2 USB wires male to male, one to raspberry and another one to my device. I'm not sure I understand your setup. This should work, using standard USB cables: <- upstream downstream -> <- host device -> A->B A->B Raspberry Pi -> hub -> UPS | \---> device The problem is that there is no equivalent of a "crossover cable" or "null-model adapter" for USB. (I am ignoring USB OTG <http://en.wikipedia.org/wiki/USB_On-The-Go> for the moment, since you want the RPi to talk to the UPS). There are many USB adapter cables out there that will only work for supplying power, or only with point-to-point USB OTG. -- Charles Lepple clepple at gmail -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.alioth.debian.org/pipermail/nut-upsuser/attachments/20150120/603d053f/attachment.html>
On Jan 20, 2015, at 9:32 AM, Maurizio Iacaruso <maurizio.iacaruso at gmail.com> wrote:> Setup that I was on mind is a little different, but I think your setup works well. > In my setup the HUB is connected directly to the UPS, then the cables go to raspberry and device. > In your setup the HUB is connected directly to the raspberry, then the cables go to UPS and Device.well, actually, I was describing a scenario with three standard A->B cables. In my mind, the presence of an A-to-A cable indicates a problem in the design :-) Wait, are you just trying to use the UPS for 5VDC power over USB for the other device? The diagram I drew shows how to connect the UPS to the RPi for monitoring, through the hub. Other configurations are possible if you don't need to monitor the UPS.> It?s Ok? > > In both configurations I need the same things: Male B->female A adaptor, HUB and 2 male A-> male A cables. > The male A- male A cables have any peculiarity? Can I buy it or make it myself without problems?http://en.wikipedia.org/wiki/USB#Cable_plugs_.28USB_1.x.2F2.0.29 The "non-standard" designation for the A-to-A cable means that it can't be used for normal USB communications, but it might work for supplying 5VDC.> Thanks a lot for advice. > > > > Da: Charles Lepple [mailto:clepple at gmail.com] > Inviato: marted? 20 gennaio 2015 14:23 > A: Maurizio Iacaruso > Cc: NUT List > Oggetto: Re: [Nut-upsuser] R: NUT and relay on USB > > On Jan 20, 2015, at 7:43 AM, Maurizio Iacaruso <maurizio.iacaruso at gmail.com> wrote: > > > I connect USB A (female) to USB B (male) adapter -> HUB -> 2 USB wires male > to male, one to raspberry and another one to my device. > > I'm not sure I understand your setup. > > This should work, using standard USB cables: > > <- upstream downstream -> > <- host device -> > > A->B A->B > > Raspberry Pi -> hub -> UPS > | > \---> device > > The problem is that there is no equivalent of a "crossover cable" or "null-model adapter" for USB. (I am ignoring USB OTG for the moment, since you want the RPi to talk to the UPS). There are many USB adapter cables out there that will only work for supplying power, or only with point-to-point USB OTG. > > -- > Charles Lepple > clepple at gmail > > > > _______________________________________________ > Nut-upsuser mailing list > Nut-upsuser at lists.alioth.debian.org > http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/nut-upsuser-- Charles Lepple A: Because it messes up the order in which people normally read text. Q: Why is top-posting such a bad thing? A: Top-posting. Q: What is the most annoying thing on usenet and in e-mail? -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.alioth.debian.org/pipermail/nut-upsuser/attachments/20150120/87678454/attachment-0001.html>
On Jan 21, 2015, at 3:41 AM, Maurizio Iacaruso <maurizio.iacaruso at gmail.com> wrote:> The ?device? is this http://www.dlink.com/it/it/business-solutions/network-storage/network-video-recorders/dnr-322l-cloud-network-video-recorder , a NVR with USB port for monitoring UPS. It doesn?t support monitoring by LAN. > So, my aim is to ?replicate? the state of the UPS, in the sense that the information are sent to raspberry (for NUT) AND to NVR, so it may shutdown properly.It is not a simple matter to replicate the UPS state, in that sense. In general, UPS monitoring ports cannot be "shared" by two devices (although some high-end UPSes have more than one serial port for that purpose). This is why NUT has 'upsd'. In the following diagram, "communication" is the USB link between the UPS and the Raspberry Pi (or the NVR). Either the Raspberry Pi has to share the UPS status through something like upsd (or something similar, like apcupsd's NIS master mode), or the NVR has to send the shutdown signal to the Raspberry Pi. http://www.networkupstools.org/docs/user-manual.chunked/ar01s03.html#_advanced_configuration -- Charles Lepple clepple at gmail -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.alioth.debian.org/pipermail/nut-upsuser/attachments/20150121/fd4f65bb/attachment.html>
So, the hardware way seems too difficult. I see the raspberry documentation in order to understand if it?s possible ?replicate? an USB signal to GPIO. So, with a TTL-USB cable I send the signal to the NVR. I hope this is possible! Da: Charles Lepple [mailto:clepple at gmail.com] Inviato: mercoled? 21 gennaio 2015 13:41 A: Maurizio Iacaruso Cc: NUT List Oggetto: Re: [Nut-upsuser] R: NUT and relay on USB On Jan 21, 2015, at 3:41 AM, Maurizio Iacaruso <maurizio.iacaruso at gmail.com <mailto:maurizio.iacaruso at gmail.com> > wrote: The ?device? is this <http://www.dlink.com/it/it/business-solutions/network-storage/network-video -recorders/dnr-322l-cloud-network-video-recorder> http://www.dlink.com/it/it/business-solutions/network-storage/network-video- recorders/dnr-322l-cloud-network-video-recorder , a NVR with USB port for monitoring UPS. It doesn?t support monitoring by LAN. So, my aim is to ?replicate? the state of the UPS, in the sense that the information are sent to raspberry (for NUT) AND to NVR, so it may shutdown properly. It is not a simple matter to replicate the UPS state, in that sense. In general, UPS monitoring ports cannot be "shared" by two devices (although some high-end UPSes have more than one serial port for that purpose). This is why NUT has 'upsd'. In the following diagram, "communication" is the USB link between the UPS and the Raspberry Pi (or the NVR). Either the Raspberry Pi has to share the UPS status through something like upsd (or something similar, like apcupsd's NIS master mode), or the NVR has to send the shutdown signal to the Raspberry Pi. http://www.networkupstools.org/docs/user-manual.chunked/ar01s03.html#_advanc ed_configuration -- Charles Lepple clepple at gmail -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.alioth.debian.org/pipermail/nut-upsuser/attachments/20150121/5f2a848c/attachment.html>