npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

@labjack/ljswitchboard-device_scanner

v2.2.0

Published

A node project dedicated to finding ALL LabJack devices that are able to be connected to.

Downloads

7

Readme

ljswitchboard-device_scanner

A node project dedicated to finding ALL LabJack devices that are able to be connected to. Uses LabJack-nodejs for LJM's scanning functionality as well as some special node additions.

findAllDevices

Takes an optional parameter of a list of connected device objects.

Returns an array,

  • containing device types (T7/Digit/etc.) as objects, which includes an array "devices",
    • which contain discovered devices as objects grouped by device serial number, which contains an array of "connectionTypes",
      • which are objects describing how each discovered device is available

findAllDevices return example and format:

[
  {
    "deviceType": 7,
    // Integer device type

    "deviceTypeString": "LJM_dtT7",
    // The LJM device type

    "deviceTypeName": "T7",
    // A human-readable device type - never indicates device subclass

    "devices":
    // A list of devices, grouped by serial number
    [
      {
        "deviceType": 7,
        // Integer device type

        "deviceTypeString": "LJM_dtT7",
        // The LJM device type

        "deviceTypeName": "T7",
        // A human-readable device type - never indicates device subclass

        "serialNumber": 470010103,
        // Integer serial number

        "acquiredRequiredData": true,
        // true if data was collected successfully, false if not

        "isMockDevice": true,
        // True if mock device, false if real device

        "productType": "T7-Pro",
        // Human-readable device class / subclass name, e.g. "T7" or "T7-Pro"
n
        "modelType": "T7-Pro",
        // Same as productType

        "isActive": false,
        // true if user has connected to this device, false if not

        "connectionTypes":
        // Array of objects for each connection this device has
        [
          {
            "dt": 7,
            // Legacy, (non-canonical) integer LJM device type

            "ct": 3,
            // Legacy, (non-canonical) integer LJM connection type

            "connectionType": 3,
            // Integer LJM connection type

            "str": "LJM_ctETHERNET",
            // String LJM connection type

            "name": "Ethernet",
            // Human-readable connection type name

            "ipAddress": "192.168.1.207",
            // Human-readable IP address string. Meaningless if USB.

            "safeIP": "192_168_1_207",
            // ipAddress with underscores (_) instead of periods (.)

            "verified": true,
            // true if the device could be opened directly, false if not

            "isActive": false,
            // true if connection was previously opened by the user before scan, false if not

            "foundByAttribute": false,
            // true if found through checking device attributes, false if found in by scan

            "insertionMethod": "scan",
            // "attribute" foundByAttribute is true, "scan" if foundByAttribute is false
          },
          {
            // Another connection, e.g. for USB, WiFi, etc.
          }
        ]

        // The following attributes are controlled by ljswitchboard-ljm_device_curator
        "DEVICE_NAME_DEFAULT",
        "HARDWARE_INSTALLED",
        "ETHERNET_IP",
        "WIFI_STATUS",
        "WIFI_IP",
        "WIFI_RSSI",
        "FIRMWARE_VERSION",
        "DGT_INSTALLED_OPTIONS",
        // etc.
      },
      {
        // Another device of the same class with a different serial number
      }
    ]
  },
  {
    // Another device class, e.g. Digits
  }
]