summaryrefslogtreecommitdiff
path: root/xpp/xpp_fxloader
AgeCommit message (Collapse)Author
2012-03-15xpp: xpp_fxloader: improve outputTzafrir Cohen
* Replaced (almost) all $LOGGER to echo: - In interactive use -- that what we want anyway - When called from UDEV, the subprocess stdout/stderr is piped to $LOGGER anyway (at the end of the script) - No need for many $LOGGER instances (each with its own pid) Signed-off-by: Oron Peled <oron.peled@xorcom.com> Acked-by: Tzafrir Cohen <tzafrir.cohen@xorcom.com> git-svn-id: http://svn.asterisk.org/svn/dahdi/tools/trunk@10495 a0bf4364-ded3-4de4-8d8a-66a801d63aff
2011-12-04xpp: xpp_fxloader: regressions from r10348Tzafrir Cohen
* Avoid a duplicated run of udev on some systems. * Fix usage of astribank_tool's output. Signed-off-by: Tzafrir Cohen <tzafrir.cohen@xorcom.com> git-svn-id: http://svn.asterisk.org/svn/dahdi/tools/trunk@10366 a0bf4364-ded3-4de4-8d8a-66a801d63aff
2011-11-29xpp: recovery firmware in xpp_fxloaderTzafrir Cohen
USB_RECOV.hex is an extra firmware that may be useful for recovering from certain Astribank hardware faults in some scenarios. This adds support for either loading it manually ('/usr/share/dahdi/xpp_fxloader recover-sb') or through udev, *if* the required udev rules were set on the system. Signed-off-by: Tzafrir Cohen <tzafrir.cohen@xorcom.com> git-svn-id: http://svn.asterisk.org/svn/dahdi/tools/trunk@10349 a0bf4364-ded3-4de4-8d8a-66a801d63aff
2011-11-29xpp: Serialized Parallel load; E-Main-3 firmwareTzafrir Cohen
This introduces support for loading multiple firmwares in parallel also for the case of a manual load. This is anyway the case for an automatic load from udev. * libusb needs to scan the bus all too often. This causes occasional failures for opening devices. * Thus introduce a semaphore to serialize uses of libusb. E-Main-3 firmware differs by a different value of bcdDevice: * Read this from the sysfs devices tree. * Fall back to lsusb -v (much slower) is sysfs not available. Signed-off-by: Tzafrir Cohen <tzafrir.cohen@xorcom.com> git-svn-id: http://svn.asterisk.org/svn/dahdi/tools/trunk@10348 a0bf4364-ded3-4de4-8d8a-66a801d63aff
2011-07-10xpp: support loading Octasic EC firmwareTzafrir Cohen
Echo Cancellation firmware is loaded by xpp/stribank_hexload (Using the oct612x code). * astribank_hexload: options -O/-o/-A for handling the Octasic echo cancellation firmware. * astribank_tool: report that. * xpp_fxloader: Run astribank_hexload, if needed. * dahdi_perl: The EC module is an extra XPD, but not a "telephony device" and hence not a span. Deal with that. * waitfor_xpds: may need to wait a bit longer for firmware loading. Signed-off-by: Tzafrir Cohen <tzafrir.cohen@xorcom.com> git-svn-id: http://svn.asterisk.org/svn/dahdi/tools/trunk@10032 a0bf4364-ded3-4de4-8d8a-66a801d63aff
2011-03-10xpp: use 'xtalk' for the USB access codeTzafrir Cohen
* Move most of the USB access code from xpp/ to xpp/xtalk/ . * astribank_tool and such tools can now use a shorter -D mmm/nnn rather than a full path. Signed-off-by: Oron Peled <oron.peled@xorcom.com> Acked-by: Tzafrir Cohen <tzafrir.cohen@xorcom.com> git-svn-id: http://svn.asterisk.org/svn/dahdi/tools/trunk@9825 a0bf4364-ded3-4de4-8d8a-66a801d63aff
2010-11-16xpp_fxloader: Don't try to load FPGA firmware twiceTzafrir Cohen
When called from udev to load the FPGA firmware, make sure that this is not the event generated for the first end-point of the existing two, as we need to talk with the second one. This is probably better done in the udev rules, but will be slightly more complicated to apply only to the FPGA loading and not to USB firmware loading. git-svn-id: http://svn.asterisk.org/svn/dahdi/tools/trunk@9482 a0bf4364-ded3-4de4-8d8a-66a801d63aff
2010-07-22increase maximal firmware delay to 15 secondsTzafrir Cohen
Hmm... how badly congested can the startup of Centos be? git-svn-id: http://svn.asterisk.org/svn/dahdi/tools/trunk@8964 a0bf4364-ded3-4de4-8d8a-66a801d63aff
2010-07-20xpp_fxloader: replace a sleep with a sleep loopTzafrir Cohen
For newer kernels there's no need to sleep at all. For Centos5 systems there seems to be a need for a large sleep for firmware load at boot time. So let's make it a loop. git-svn-id: http://svn.asterisk.org/svn/dahdi/tools/trunk@8951 a0bf4364-ded3-4de4-8d8a-66a801d63aff
2010-05-03xpp_fxloader: make sure 1163 is not missed.Tzafrir Cohen
git-svn-id: http://svn.asterisk.org/svn/dahdi/tools/trunk@8589 a0bf4364-ded3-4de4-8d8a-66a801d63aff
2010-04-29Load xpp firmware in the background (udev)Tzafrir Cohen
Move loading the the xpp firmwares (when called from udev) to a background sub-process. This helps with: * Don't block udev * It seems that with older systems (e.g. CentOS 5) we need to wait a bit for the device file to appear (in one of the upcoming udev events). If we keep blocking udev, we won't have the device file. The 'sleep' does not seem to be required for newer systems (e.g. Debian Lenny). git-svn-id: http://svn.asterisk.org/svn/dahdi/tools/trunk@8580 a0bf4364-ded3-4de4-8d8a-66a801d63aff
2010-01-12xpp: Also properly count 1163 Astribanks on a manual load.Tzafrir Cohen
git-svn-id: http://svn.asterisk.org/svn/dahdi/tools/trunk@7895 a0bf4364-ded3-4de4-8d8a-66a801d63aff
2010-01-04xpp_fxloader: adapt to newer kernelsTzafrir Cohen
This commit prepares xpp_fxloader to get hotplug envirnment from newer kernel versions: * DEVICE will eventually be replaced with DEVNAME. Accept both (and look at DEVNAME first). * If we get DEVICE, we'll probably get an invalid path based at /proc/bus/usb . Fix it to use /dev/bus/usb . * While we're at it, allow using PRODUCT from the envirnment instead of from the command-line. This should allow fixing udev rules but will also work with existing rules in DAHDI-linux (for systems where they are valid). git-svn-id: http://svn.asterisk.org/svn/dahdi/tools/trunk@7752 a0bf4364-ded3-4de4-8d8a-66a801d63aff
2009-11-19xpp: support loading USB firmware into 1163 devices as wellTzafrir Cohen
git-svn-id: http://svn.asterisk.org/svn/dahdi/tools/trunk@7596 a0bf4364-ded3-4de4-8d8a-66a801d63aff
2009-11-04xpp: Comment-only changes: copyright, keywordsTzafrir Cohen
git-svn-id: http://svn.asterisk.org/svn/dahdi/tools/trunk@7463 a0bf4364-ded3-4de4-8d8a-66a801d63aff
2009-09-27xpp: reduce the clutter of firmware loadingTzafrir Cohen
Make the new XPP tools much less verbose: * demote messages to be debug * Convert multi-line messages to be single-line messages Making xpp_fxloader run in debug mode can be done by setting DEBUG=yes in /etc/dahdi/init.conf git-svn-id: http://svn.asterisk.org/svn/dahdi/tools/trunk@7221 a0bf4364-ded3-4de4-8d8a-66a801d63aff
2009-08-13xpp_fxloader: Search for commands in our directory first.Tzafrir Cohen
This allows using scripts from /usr/share/dahdi as well. xpp rev: 7286 git-svn-id: http://svn.asterisk.org/svn/dahdi/tools/trunk@6999 a0bf4364-ded3-4de4-8d8a-66a801d63aff
2009-08-13xpp: Add astribank_is_starting:Tzafrir Cohen
astribank_is_running is used to tell when we may have an Astribank that is initializing (and may be re-enumerating and thus not listed as a device). It uses a semaphore as we can always write to one and we can't always write to a file. git-svn-id: http://svn.asterisk.org/svn/dahdi/tools/trunk@6987 a0bf4364-ded3-4de4-8d8a-66a801d63aff
2009-04-16xpp_fxloader: exit properly when run with incorrect argumentTzafrir Cohen
git-svn-id: http://svn.asterisk.org/svn/dahdi/tools/trunk@6375 a0bf4364-ded3-4de4-8d8a-66a801d63aff
2009-04-02Support for Astribanks 116x: tools partTzafrir Cohen
* New USB firmware loading mechanism. - Incompatible with previous one: upgrade using fxload or hard reset - astribank_hexload is the new low-level loading tool - fpga_load remains for backward compatibility. - xpp/astribank_upgrade: automate upgrading using fxload * Much enhanced control protocol ("MPP") - astribank_tool is the low-level tool for that. * Support for the TwinStar (dual USB port) - Managed through astribank_tool - Wrapper perl modules and scripts provided * Allow explicit ordering of Astribanks - /etc/dahdi/xpp_order - explicit order of Astribanks on the system - The default sorter is now to use those and fall back to connectors (previous default). - An option to dahdi_registration to change sorting. git-svn-id: http://svn.asterisk.org/svn/dahdi/tools/trunk@6313 a0bf4364-ded3-4de4-8d8a-66a801d63aff
2008-11-24Add some missing copyright statements in the xpp/ directory as well.Tzafrir Cohen
git-svn-id: http://svn.asterisk.org/svn/dahdi/tools/trunk@5379 a0bf4364-ded3-4de4-8d8a-66a801d63aff
2008-08-12* xpp_fxloader: shows USB firmware version.Tzafrir Cohen
* Update PCI IDs database. git-svn-id: http://svn.asterisk.org/svn/dahdi/tools/trunk@4765 a0bf4364-ded3-4de4-8d8a-66a801d63aff
2008-07-10Well, make this a bashism formally.Tzafrir Cohen
git-svn-id: http://svn.asterisk.org/svn/dahdi/tools/trunk@4600 a0bf4364-ded3-4de4-8d8a-66a801d63aff
2008-06-29dahdi_genconf configuration separated from the kernel config.Tzafrir Cohen
* Using /etc/dahdi/genconf_parameters. * A shiny new format (sample file included). * xpp_fxloader is configured from /etc/dahdi/init.conf (like the init.d script). * Yet some more string cleanups. git-svn-id: http://svn.asterisk.org/svn/dahdi/tools/trunk@4484 a0bf4364-ded3-4de4-8d8a-66a801d63aff
2008-06-19XPP tools rename: part 2.Tzafrir Cohen
Removed obsolete astribank_hook (not needed) and print_modes (moved to kernel). git-svn-id: http://svn.asterisk.org/svn/dahdi/tools/trunk@4416 a0bf4364-ded3-4de4-8d8a-66a801d63aff
2008-06-17Move the xpp utilities to the tools side.Tzafrir Cohen
git-svn-id: http://svn.asterisk.org/svn/dahdi/tools/trunk@4374 a0bf4364-ded3-4de4-8d8a-66a801d63aff