The stepper motor L293D diagram again. Is it me or is it still wrong?

lauriet

Member
The diagram on page 18 of Manual 3 shows the Picaxe connections to the L293D being from Pin 4, Pin 5, Pin 6 and Pin 7.

As I'm using an 08M, I'm guessing this really means Leg 4, Leg 5, Leg 6 and Leg 7 (the usual confusion), as the 08M only has Pins 0 to 4.

If my assumption is correct, this is also wrong as Leg 4 is (generally) an Input Only pin, so cannot be used to output to the L293D; on the 08M series Leg 3 (Pin 4) has to be used instead.
This also then means the associated code is relatedly wrong; the pin High outputs (%1010,%1001,%0101,%0110) should be (%10010,%10001,%00101,%00110). This amendment works in the Program Editor, whereas the published code throws an error.

However, I see from previous stepper motor postings that this diagram and code has been used successfully since time immoral, so my reasoning must be incorrect.
Could someone please gently clarify my confusion?

Thanks,
 

Billo

Senior Member
... since time immoral...
Well, I'm getting old and what time has done to me has certainly been wicked and depraved...I guess that's immoral alright!

I know, you meant immemorial, but I couldn't resist.

On the subject though, I am not sure what that diagram is saying. It does not seem to match the code and no PICAXE I know of can use physical pins 4, 5, 6 and 7 for this purpose. I think your reasoning is fine.
 

westaust55

Moderator
Also keep in mind the vintage of the PICAXE manual 3 compared to the other parts, it has not really advanced with the emergence of the M2 and X2 parts.

Pins 4, 5, 6 and 7 could easily have originally referred to dedicated outputs on earlier chips. That said, the data in the code if for the lower 4 bits whereas outputs 4,5,6 and 7 would have corresponded to the upper 4 bits in any pins = statement.

IMHO is is better to always enter all 8 bits when using a binary designation.
That is %00001010 rather than just %1010 which may be confused with $10100000.

This is not to say that the manuals should not correspond with at least one chip and could include a small table of alternatives for other chips.
 
Top