An open source program for controlling XGecu's series of chip programmers.
This program exists because XGecu does not provide a program for use on Linux or other flavors of Unix. We who keep this project going prefer a simple, free, and open-source program that presents a command-line interface that allows for a GUI front-end if desired.
- Native support for Linux, BSD, macOS, and other flavors of Unix.
- Compatibility with TL866CS, TL866A, TL866II+, T48, and T56 from XGecu (http://www.xgecu.com/en/)
- More than 13000 target devices (including AVRs, PICs, various BIOSes and EEPROMs)
- ZIF40 socket and ISP support
- Vendor-specific MCU configuration bits
- Chip ID verification
- Logic IC testing
- Bitbang support
- Overcurrent protection
- System testing
$ minipro -p ATMEGA48 -w atmega48.bin
$ minipro -p ATMEGA48 -r atmega48.bin
You'll need some sort of Linux or MacOS machine. Other Unices may work, though that is untested. You will need version 1.0.16 or greater of libusb. Earlier versions may work, but are untested.
sudo apt-get install build-essential pkg-config git libusb-1.0-0-dev zlib1g-dev
sudo yum install gcc make pkgconfig git libusbx-devel
sudo zypper install gcc make git-core srecord rpmdevtools libusb-1_0-devel
sudo dnf install make pkg-config git gcc libusb1-devel zlib-ng-compat-devel
git clone https://gitlab.com/DavidGriffith/minipro.git
cd minipro
make
sudo make install
If you have a T56, you'll need to download and install algorithms from Xgeku's official software package.
sudo make install-algorithm
If you want to access the programmer as a regular user, you'll have to configure udev to recognize the programmer and set appropriate access permissions.
sudo cp udev/*.rules /etc/udev/rules.d/
sudo udevadm trigger
You'll also have to add your regular user to the plugdev system
group:
sudo usermod -a -G plugdev YOUR-USER
Note that this change will only become effective after your next login.
Bash users may want to optionally install the provided completion file:
sudo cp bash_completion.d/minipro /etc/bash_completion.d/
Building a Debian package directly from this repository is easy. Make sure you have the build dependencies installed as described above. Be sure it all builds, then do this:
sudo apt-get install fakeroot debhelper dpkg-dev
fakeroot dpkg-buildpackage -b -us -uc
You should then have a .deb package for you to install with dpkg -i.
Note that the .deb package will already provide the udev and
bash-completion configurations for you.
The following commands require git-buildpackage:
git archive --format=tar HEAD | tar x && git commit -am "packaging: Makefile substitution"
gbp dch --commit --since=HEAD --upstream-branch=master --dch-opt="-lppa" --dch-opt="-D$(lsb_release -c -s)" debian
gbp buildpackage --git-upstream-tree=SLOPPY --git-export-dir=../build-area -S
You can then dput the *.changes file in ../build-area to your PPA.
You can build RPM packages for Fedora, CentOS and openSUSE with the supplied
rpm/minipro-*.spec files.
First make sure you have a RPM build environment set up. You need to have
the rpmdevtools package installed and a rpmbuild directory tree within
your homedir. Use the rpmdev-setuptree command to create the rpmbuild
directory tree if it does not exist yet.
Then use these commands to download the source tarballs from Gitlab and build the package for Fedora and CentOS:
spectool -g -R rpm/minipro-fedora.spec
rpmbuild -ba rpm/minipro-fedora.spec
Or for openSUSE:
rpmdev-spectool -f -g -R rpm/minipro-opensuse.spec
rpmbuild -ba rpm/minipro-opensuse.spec
The final RPMs can be found below ~/rpmbuild/RPMS/
guix install minipro
If you want to access the programmer without root privileges you must install the necessary udev rules. This can be done by extending udev-service-type in your operating-system configuration with this package.
(udev-rules-service 'minipro minipro #:groups '("plugdev")
Additionally your user must be member of the plugdev group. At that point, minipro should be installed and ready to use.
The easiest way to install on macOS is by using homebrew to install the most recent release:
brew install minipro
At that point, minipro should be installed and ready to use.
If you'd rather compile from source (if, for instance, you need newer code than is in the most recent release), you'll need to do the following to prepare your environment and compile the code.
Install pkg-config and libusb using brew or MacPorts:
brew install pkg-config
brew install libusb
brew link libusb
or:
port install pkgconfig
port install libusb
git clone [email protected]:DavidGriffith/minipro.git
cd minipro
make
sudo make install
Unlike the other programmers from Xgecu, the T56 does not store its FPGA
bitstreams in the hardware. Instead it must be loaded by the
controlling software. Those bitstreams (Xgecu calls them algorithms)
are found in the official Xgecu software releases. They cannot be
included here for copyright reasons. Instead the build process can
download them for you and convert them into a single file for use by
minipro.
make algorithm
sudo make install-algorithm
When you download an archive/tarball from Gitlab, there is no guarantee that the file given to you will hash to the same value time and time again. For Gitlab to allow for this would require it to store a very large amount of data. If you run a packaging system that depends on hashes like that, consider following the example of the FreeBSD ports system. What they do is use the SHA-1 commit hash of the version to be installed. Check out how FreeBSD does it for Minipro here: https://github.com/freebsd/freebsd-ports/tree/main/sysutils/minipro
Code and data for testing ICs have been borrowed from https://github.com/Johnlon/integrated-circuit-tester and https://github.com/akshaybaweja/Smart-IC-Tester and used in accordance with the MIT License (https://opensource.org/license/MIT)