[code]#include <Zumo32U4.h>
Zumo32U4Motors motors; //In order for motors.setLeftSpeed to work this line has to be added
void setup() {
// put your setup code here, to run once:
pinMode(9,OUTPUT);
pinMode(10,OUTPUT);
}
void loop() {
// put your main code here, to run repeatedly:
motors.setLeftSpeed(50);
}[/code]
This is the error message I now get:
Arduino: 1.6.6 (Windows 7), Board: “Arduino Robot Control”
C:\Users\GunnarM\Documents\Arduino\libraries\Zumo32U4\Zumo32U4ProximitySensors.cpp: In function ‘bool digitalReadSafe(uint8_t, bool)’:
C:\Users\GunnarM\Documents\Arduino\libraries\Zumo32U4\Zumo32U4ProximitySensors.cpp:14:15: error: ‘NUM_DIGITAL_PINS’ was not declared in this scope
if (pin < NUM_DIGITAL_PINS)
^
C:\Users\GunnarM\Documents\Arduino\libraries\Zumo32U4\Zumo32U4ProximitySensors.cpp: In function ‘void pinModeSafe(uint8_t, uint8_t)’:
C:\Users\GunnarM\Documents\Arduino\libraries\Zumo32U4\Zumo32U4ProximitySensors.cpp:26:15: error: ‘NUM_DIGITAL_PINS’ was not declared in this scope
if (pin < NUM_DIGITAL_PINS)
^
C:\Users\GunnarM\Documents\Arduino\libraries\Zumo32U4\Zumo32U4ProximitySensors.cpp: In member function ‘void Zumo32U4ProximitySensors::lineSensorEmittersOff()’:
C:\Users\GunnarM\Documents\Arduino\libraries\Zumo32U4\Zumo32U4ProximitySensors.cpp:117:32: error: ‘NUM_DIGITAL_PINS’ was not declared in this scope
if (lineSensorEmitterPin < NUM_DIGITAL_PINS)
^
exit status 1
Error compiling.
I feel there is something missing regarding the pins and that is why it won’t run however can’t find anything that will specify which pin to run the command on. Based on the error message it feels like I have to declare the number of pins and the pin location but I am unable to figure out how.