I’ve got DFRobot USB Host Shield with DFRobotShop Rover. And i try to make it work with PS3 dualshock controller.
In that Rover pins 5-8 are used to control the motors.
If i try DFRobotShop Rover alone without any shield attached it works fine: i can control it via serial (W,A,S,D sample sketch). And it doesn’t matter whether i assign “pinMode(i, OUTPUT);” or not - it function the same way in both cases.
Then i plug DFRobot USB Host Shield with bluetooth dongle in it and use the latest USB Host Library ( github.com/felis/USB_Host_Shield_2.0 ).
BT works fine: all samples function properly, i can read all buttons, values.
If i then try to control the motors everything works fine until i try “digitalWrite(8,HIGH);”. There can be 2 variants:
- If there were “pinMode(8, OUTPUT);” in setup() then after “digitalWrite(8,HIGH);” USB shield hangs If i then send any signal to serial - USB restarts (reinits) and works normally again till “digitalWrite(8,HIGH);”.
- If there were no “pinMode(8, OUTPUT);” in setup() then there is always LOW at pin 8 regardless “digitalWrite(8,HIGH);” or “digitalWrite(8,LOW);”: if i say “digitalWrite(8,HIGH);” it acts as if i said “digitalWrite(8,LOW);”. USB Shield doesn’t hang and everything else seems to work fine except that Motor B now has only one direction - pin 8 controls the direction.
I dont understand what to do… Rover uses 5-8 pins for motors, USB shield is said to use 9-10 pins. But it seems that there is some conflict on pin 8.
Please, any help!