Coder Social home page Coder Social logo

bcu's Introduction

bcu (Board Control Utilities)

Build status GitHub Coverity Scan Build Status

to build and run BCU in Windows:

first we need to have FTDI D2XX library installed:

  1. go to https://www.ftdichip.com/Drivers/D2XX.htm
  2. click "setup executable" and download the zip file
  3. unzip the file and install the library

then we can download and build bcu:

$ git clone https://github.com/NXPmicro/bcu.git

open Board_Control_Utilities.sln with windows visual studio

ctr-shift+B to build the solution

ctr-f5 to run


to build and run BCU in Linux:

first we need to obtain libftdi1-dev library:
$ sudo apt-get update
$ sudo apt-get install libftdi1-dev

then we can obtain and build bcu:

$ git clone https://github.com/NXPmicro/bcu.git

$ cd bcu

$ cmake .

$ make

$ sudo ./bcu command

linux user: please remember to run bcu with sudo to avoid permission issue


list of available commands & their functions:

commands descriptions
reset reset the board
monitor switch into a tui windows that monitors voltage, current and power consumption inside the board
lsgpio show a list of available gpio pin
set_gpio [GPIO_NAME] [1/0] set a GPIO_NAME pin to be high(1) or low(0). all GPIO_NAMEs are shown in lsgpio command
lsftdi show the list of connected boards and the their location IDs
lsboard list all supported board models
set_boot_mode [BOOTMODE] set the boot mode as BOOTMODE
help show list of available commands and their functions, as well as options
version show version number

typical usage of bcu:

$ bcu command [-options]

some example:

1.set sd_wp gpio pin as high:
$ bcu set_gpio sd_wp 1

2.reset the i.MX8QMEVK board after 1 second:
$ bcu reset -board=iMX8QMEVK -delay=1000

3.hold sd_pwr pin low for 3 second:
$ bcu set_gpio sd_pwr 0 -hold=3000

4.set emmc as the booting device:
$ bcu set_boot_mode emmc


general options for all commands:

options descriptions
[-board=MODEL] set the board model, list of avaliable models is shown in lsboards command
[-id=ID] select the target board with location id(when there are multiple boards), the location id can be viewed by using command lsftdi

options for specfic command:

reset:

options descriptions
[-delay=DURATION] reset after DURATION ms
[BOOTMODE] setting BOOTMODE as the booting method

monitor:

options descriptions
[-dump] dump data into a file, which can be imported to excel

set_gpio:

options
[-delay=DURATION] set after DURATION ms
[-hold=DURATION] hold the output state for DURATION ms
[GPIO_NAME] specify which gpio pin should be set, list of available gpio can be found using list gpio command
[0] set the pin output low
[1] set the pin output high
[-path=PATH] for testing purpose only: set the gpio pin specified by path

set_boot_mode

options descriptions
[BOOTMODE] booting from emmc device

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.