Trouble using Picaxe 18x with the Pololu motor control

jgillick

New Member
I'm trying to use my new Picaxe 18x to drive 2 motors through the Pololu Micro Dual motor control. For some reason nothing happens and I hope somebody can help me shed some light on the problem. Here's what I did:

(NOTE: I have read the Picaxe and Pololu user manuals)

  • I'm using the Picaxe 18x Standard Project board
  • I removed the darlington so I could connect directly to the picaxe pins with jumpers.
  • Connected picaxe pin 1 to the motor reset pin
  • Connected picaxe pin 2 to the motor serial control input

I have read the Picaxe and Pololu user manuals and it seemed to be quite easy to do -- but for some reason it doesn't work. Here's the code:

Code:
symbol motor_reset_pin = 1
symbol motor_serial = 2
symbol motor_baud = T2400_4 ' also tried with T2400

main:
	pause 500
	high motor_reset_pin
	pause 500

	' Left motor (2) at full speed (127)
	serout motor_serial, motor_baud, (0x80)
	serout motor_serial, motor_baud, (0x00)
	serout motor_serial, motor_baud, (5) ' 2 * 2 + 1
	serout motor_serial, motor_baud, (127)

	' Right motor (3) at full speed (127)
	serout motor_serial, motor_baud, (0x80, 0x00, 7, 127) ' 2 * 3 + 1 = 7
	
	goto main
I've tried with and without the 'goto main' part and have verified both pins are outputting from the picaxe by using an LED.

I'm sure I'm making a noob mistake here, and would like it if somebody could point me in the right direction.

Thanks!
 

premelec

Senior Member
Yes it could be - try using two battery packs - one for low current signals and the other more current... at least you can start to isolate the problem...
 
Top