Dangerous Prototypes

Dangerous Prototypes => Bus Pirate Development => Topic started by: Sjaak on May 01, 2010, 05:55:19 pm

Poll
Question: What to display in the pinstate command
Option 1: Ground is brown votes: 1
Option 2: Ground is black votes: 2
Option 3: Use numbers instead votes: 1
Option 4: Use silkscreen names instead votes: 1
Option 5: other votes: 0
Title: Which colours to use for the pinstate command?
Post by: Sjaak on May 01, 2010, 05:55:19 pm
There seems to be a lot of (conflicting) wishes for the pinstate command. I think making it usercontrollable is pointless (writing it down somewhere is simpler ;)) so I started the poll.

1. Ground is brown (the current one)

Code: [Select]
I2C> v
Pinstates:
(BR)    (RD)    (OR)    (YW)    (GN)    (BL)    (PU)    (GR)    (WT)    (Blk)
GND     3.3V    5.0V    ADC     VPU     AUX     SCL     SDA     -       -
P       P       P       I       I       I       I       I       I       I
GND     0.00V   0.00V   0.00V   0.00V   L       L       L       L       L
I2C>

2. Ground is black

Code: [Select]
I2C> v
Pinstates:
(Blk)   (WT)    (GR)    (PU)    (BL)    (GN)    (YW)    (OR)    (RD)    (BR)
GND     3.3V    5.0V    ADC     VPU     AUX     SCL     SDA     -       -
P       P       P       I       I       I       I       I       I       I
GND     0.00V   0.00V   0.00V   0.00V   L       L       L       L       L
I2C>

3. pinnumbers

(1) is the top left, (2) is the top right, .. , (10) is bottom right

Code: [Select]
I2C> v
Pinstates:
(1)     (2)     (3)     (4)     (5)     (6)     (7)     (8)     (9)     (10)
GND     3.3V    5.0V    ADC     VPU     AUX     SCL     SDA     -       -
P       P       P       I       I       I       I       I       I       I
GND     0.00V   0.00V   0.00V   0.00V   L       L       L       L       L
I2C>

4. pinnames (as printed on the silkscreen)

Code: [Select]
 I2C> v
Pinstates:
GND     3.3V    5.0V    ADC     VPU     AUX     CLK     MOSI    CS      MISO
GND     3.3V    5.0V    ADC     VPU     AUX     SCL     SDA     -       -
P       P       P       I       I       I       I       I       I       I
GND     0.00V   0.00V   0.00V   0.00V   L       L       L       L       L
I2C>

I personally prefer the third option, since this it the most general one and would suit everyone (also the homebuilt cablesets).

Please take a look at the newterm topic for some extra thoughts regarding the colouring scheme. ( discussion starts here: http://dangerousprototypes.com/forum/in ... 44#msg4344 (http://dangerousprototypes.com/forum/index.php?topic=291.msg4344#msg4344) )

Edit: added pinnumberingplan :D
Title: Re: Which colours to use for the pinstate command?
Post by: alm on May 01, 2010, 07:04:46 pm
There is actually room for both colors and pin numbers. This might be helpful to show the 'correct' order, and still provide information for people using custom cables (eg. a piece of a PATA cable). It does make the display more busy, though.
Code: [Select]
I2C> v
Pinstates:
1 (Blk) 2 (WT)  3 (GR)  4 (PU)  5 (BL)  6 (GN)  7 (YW)  8 (OR)  9 (RD)  10 (BR)
GND     3.3V    5.0V    ADC     VPU     AUX     SCL     SDA     -       -
P       P       P       I       I       I       I       I       I       I
GND     0.00V   0.00V   0.00V   0.00V   L       L       L       L       L
I2C>

Another way might be to just indicate pin one, but I couldn't come up with a clean way without taking up an extra line, which sucks in my opinion, because it limits the amount of previous commands you can see.
Title: Re: Which colours to use for the pinstate command?
Post by: Sjaak on May 01, 2010, 09:10:37 pm
I think combining colours and pinnumbers is the best of both worlds!
Title: Re: Which colours to use for the pinstate command?
Post by: alm on May 03, 2010, 03:15:38 pm
By the way, I think it would be easier to read if only the first letter of the color is capital. It would also be consistent with 'Blk'. This is just a minor detail though.
Code: [Select]
I2C> v
Pinstates:
1 (Blk) 2 (Wt)  3 (Gr)  4 (Pu)  5 (Bl)  6 (Gn)  7 (Yw)  8 (Or)  9 (Rd)  10 (Br)
GND     3.3V    5.0V    ADC     VPU     AUX     SCL     SDA     -       -
P       P       P       I       I       I       I       I       I       I
GND     0.00V   0.00V   0.00V   0.00V   L       L       L       L       L
I2C>

Gy might be better for gray (Gr could also refer to green).

( ! ) Fatal error: Uncaught exception 'Elk_Exception' with message 'Please try again. If you come back to this error screen, report the error to an administrator.' in /var/www/dangerousprototypes/forum/sources/database/Db-mysql.class.php on line 696
( ! ) Elk_Exception: Please try again. If you come back to this error screen, report the error to an administrator. in /var/www/dangerousprototypes/forum/sources/database/Db-mysql.class.php on line 696
Call Stack
#TimeMemoryFunctionLocation
10.01202274768session_write_close ( )...(null):0
20.01232406344ElkArte\sources\subs\SessionHandler\DatabaseHandler->write( )...(null):0
30.01242407120Database_MySQL->query( ).../DatabaseHandler.php:119
40.05792545840Database_MySQL->error( ).../Db-mysql.class.php:273