MATLAB Support Package for Parallax BASIC Stamp

MATLAB library for communicating with a BASIC Stamp 2 and Board of Education (BoE) kit
다운로드 수: 870
업데이트 날짜: 2016/9/1

라이선스 보기

The Parallax BASIC Stamp 2 (BS2) is a low-cost single-board microcontroller useful for electronics projects. It is available as part of a "Board of Education" (BoE) kit that includes a solderless prototyping board, I/O pins and serial connectivity.
This MATLAB Support Package allows you to to communicate with a BS2 over a serial port, and is specifically intended for use with the Board of Education. It consists of a MATLAB API on the host computer and a PBASIC server program that runs on the BS2. With this support package, you can:
* Communicate with BS2 from the MATLAB command line
* Read and write to the BS2 digital pins
* Output PWM, DTMF and X10 signals
* Measure pulse widths and digital state changes

The support package DOES NOT require any knowledge of PBASIC.

Sample usage:

% create the BASIC Stamp object
bs = stamp.BasicStamp('COM4');

% set the I/O state of pin 3 (0=output, 1=input)
bs.setState(3, 0)

% access digital state
bs.writePin(3,0) % set pin 3 to 0
bs.readPin(4) % read pin 4

% get the duration of a high pulse on pin 4
bs.recvPulse(4, 1)

% send a 200 microsecond high pulse on pin 3
bs.writePin(3,0)
bs.sendPulse(3,200)

% send a pseudo-PWM waveform with a
% duty cycle of 10% and duration of 30ms
bs.outputPWM(3, 0.1, 30)

% clean up
delete(bs)

인용 양식

MathWorks Classroom Resources Team (2024). MATLAB Support Package for Parallax BASIC Stamp (https://www.mathworks.com/matlabcentral/fileexchange/32329-matlab-support-package-for-parallax-basic-stamp), MATLAB Central File Exchange. 검색됨 .

MATLAB 릴리스 호환 정보
개발 환경: R2009a
모든 릴리스와 호환
플랫폼 호환성
Windows macOS Linux
커뮤니티
 Power Electronics Control 커뮤니티에 더 많은 파일이 있습니다

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!
버전 게시됨 릴리스 정보
1.2.0.1

Updated license

1.2.0.0

Fixed hyperlinks in README.pdf, and added image

1.1.0.0

Updated README.pdf

1.0.0.0