Skip to content

fx-bricks/pfx-brick-cpp

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

19 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

PFx Brick C++ API

This repository contains the API for developing C++ applications which communicate with the PFx Brick.

Getting Started

Requirements

  • gcc
  • hidapi
  • sphinx (for documentation)

Basic Usage

An example of the API can be seen below

#include <stdio.h>
#include <string>
#include "../src/pfxbrick.h"

int main (int argc, char *argv[])
{
  PFxBrick brick = PFxBrick();
  if (brick.open())
  {
    brick.get_icd_rev();
    printf("ICD rev : %s\n", brick.icd_rev.c_str());
    brick.get_status();
    brick.print_status();
    brick.get_config();
    brick.print_config();
    brick.close();
  }
  return 0;
}

Documentation

If you want to learn more about PFx Brick, check out our website.