There is no command in BusPirate BASIC to configure BUS mode, like a command to configure BusPirate to SPI mode with well defined parameters. This configuration has to be done by hand and it could be a source of an error. And it is boring manual task, there should be a way to script it... ;-)
And there is no command in BusPirate BASIC to verify that device is configured in correct mode.
An example, this simple BASIC program reads 2 bytes from SPI but because there is no way to configure SPI mode from BASIC, that has to be done manually before switching to script mode:
SPI(BASIC)>list
10 PSU 1
20 PULLUP 1
25 REM DELAY 5
30 START
40 LET A= RECEIVE
50 LET B= RECEIVE
60 LET W=A*256+B
70 STOP
80 PSU 0
90 PRINT A;",";B;",";W
Similar reading in manual mode WP%:5[rr]w:
SPI>WP%:5[rr]w
POWER SUPPLIES ON
Clutch engaged!!!
Pull-up resistors ON
DELAY 5ms
/CS ENABLED
READ: 0x06
READ: 0x29
/CS DISABLED
Clutch disengaged!!!
SPI>
There is no command in BusPirate BASIC to configure BUS mode, like a command to configure BusPirate to SPI mode with well defined parameters. This configuration has to be done by hand and it could be a source of an error. And it is boring manual task, there should be a way to script it... ;-)
And there is no command in BusPirate BASIC to verify that device is configured in correct mode.
An example, this simple BASIC program reads 2 bytes from SPI but because there is no way to configure SPI mode from BASIC, that has to be done manually before switching to script mode:
Similar reading in manual mode
WP%:5[rr]w
:My BusPirate device: