0

I have downloaded the adafruit Motor Hat Demo for windows IOT.

The code calls GetMotor(3) which I assume is supposed to activate the motor connected the the connections labeled "M3"?

However it actually activates the motor connections labeled "M1"...

Is anyone else getting this behaviour?


Update

It appears that no matter what motor I set via GetMotor(x) both M1 and M2 are activated and will both obviously run the motor while neither M3 or M4 ever work.

Thinking that it might have been a faulty motor hat or some dodgy soldering by myself, I tested a second motor hat and it does exactly the same thing.

coolblue2000
  • 3,796
  • 10
  • 41
  • 62
  • Which demo did you follow? – Rita Han Jan 12 '18 at 01:59
  • The adafruit motor hat demo from their examples page – coolblue2000 Jan 12 '18 at 08:08
  • So, you want to drive 4 DC motors but only two can be derived(M1 and M2), right? Have you tested [this sample](https://github.com/adafruit/Adafruit-Motor-HAT-Python-Library/blob/d772067c8970caff129bb76deb2b1f86d3ac2b4b/examples/DCTest.py)? – Rita Han Jan 15 '18 at 05:44
  • No I want to drive one motor (at this time) and no matter what I do M1 and M2 always turn on and M3 and M4 are always off, regardless of which motors are specified in the code... However it seems to have been fixed, see answer below. – coolblue2000 Jan 15 '18 at 11:20

1 Answers1

0

This is now fixed. It seems to have been an issue with Windows IOT.

I re-flashed the sd card although with the same version of windows iot that was previously on it (this was the latest version). The PI then installed a windows update. The motor hat now works perfectly.

I have no idea if the issue was with the previous windows installation being corrupt or if the update fixed something. But either way everything now works fine.

However I still need to test to see if they fixed the windows IOT wifi bug that stopped the raspberry pi from automatically connecting the network after a reboot...

coolblue2000
  • 3,796
  • 10
  • 41
  • 62
  • Do you address the motors using python or .NET? I want to do some netcore with a motor hat but can't find a compatible library – Tom Tavernier Sep 05 '18 at 22:14