uhf_c72_plugin_2 0.2.9 copy "uhf_c72_plugin_2: ^0.2.9" to clipboard
uhf_c72_plugin_2: ^0.2.9 copied to clipboard

PlatformAndroid

A flutter plugin for UHF C72 to read and write UHF Cards. Extended version.

uhf_c72_plugin_2 #

A better flutter plugin for UHF type C72 to read UHF Cards.

Getting Started #

  • Import the library:

    import 'package:uhf_c72_plugin/uhf_c72_plugin.dart';

  • Open connection to the UHF reader

    await UhfPlugin.connect;

    Returns: bool? (nullable)

      @override
      void initState() {
         super.initState();
         initRFID();
      }
    
      void initRFID() async {
         await UhfC72Plugin.connect;
      }
    
  • Check if is the reader connected

    await UhfC72Plugin.isConnected;

    Returns: bool? (nullable)

      @override
      void initState() {
         super.initState();
         initRFID();
      }
    
      void initRFID() async {
         await UhfC72Plugin.connect;
         await UhfC72Plugin.isConnected;
      }
    
  • Start reading data from a single UHF card

    await UhfC72Plugin.startSingle;

    Returns: bool? (nullable)

  • Start reading data multi 'continuous' UHF cards

    await UhfC72Plugin.startContinuous;

    Returns: bool? (nullable)

  • Is started reading

    await UhfC72Plugin.isStarted;

    Returns: bool? (nullable)

  • Write data to UHF card

    await UhfC72Plugin.writeData(int ptr, int len, String value);

    Takes: int ptr => Default: 2, int len => How many multiples of 4 ex: 2 => 2x4 = 8, String value => Any string that's length is a multiple of 4, len determines the number of characters written in the UHF card

    Returns: bool? (nullable)

  • Read data to UHF card

    await UhfC72Plugin.readData(int ptr, int len);

    Returns: String? (nullable)

  • Erase data from UHF card

    await UhfC72Plugin.eraseData(int ptr, int len);

    Returns: bool? (nullable)

  • Stop Reading

    await UhfC72Plugin.stop;

    Returns: bool? (nullable)

  • Close the connection

    await UhfC72Plugin.close;

    Returns: bool? (nullable)

  • Clear cached data for the reader

    await UhfC72Plugin.clearData;

    Returns: bool? (nullable)

  • Is Empty Tags

    await UhfC72Plugin.isEmptyTags;

    Returns: bool? (nullable)

  • Set Power level (5 dBm : 30 dBm use string numbers)

    await UhfC72Plugin.setPowerLevel;

    Returns: bool? (nullable)

  • Set Work Area Values { "1", "2", 4", "8", "22", "50", "51", "52", "128"}

    await UhfC72Plugin.setWorkArea;

    Returns: bool? (nullable)

  • Listen to tags status

    UhfC72Plugin.tagsStatusStream.receiveBroadcastStream().listen(updateTags);

       List<TagEpc> _data = [];
       void updateTags(dynamic result) {
        setState(() {
            _data = TagEpc.parseTags(result);
         });
       }
    
2
likes
130
points
13
downloads

Publisher

unverified uploader

Weekly Downloads

A flutter plugin for UHF C72 to read and write UHF Cards. Extended version.

Documentation

API reference

License

unknown (license)

Dependencies

flutter

More

Packages that depend on uhf_c72_plugin_2

Packages that implement uhf_c72_plugin_2