Dawn Robotics Forum Support and community forums for Dawn Robotics Ltd 2015-02-06T02:11:51+01:00 http://forum.dawnrobotics.co.uk/feed.php?f=5&t=1328 2015-02-06T02:11:51+01:00 2015-02-06T02:11:51+01:00 http://forum.dawnrobotics.co.uk/viewtopic.php?t=1328&p=1665#p1665 <![CDATA[Re: Pan and Tilt Servos control?]]> http://forum.dawnrobotics.co.uk/viewtopic.php?f=5&t=1332

Statistics: Posted by pageauc — Fri Feb 06, 2015 2:11 am


]]>
2015-01-31T09:02:20+01:00 2015-01-31T09:02:20+01:00 http://forum.dawnrobotics.co.uk/viewtopic.php?t=1328&p=1655#p1655 <![CDATA[Re: Pan and Tilt Servos control?]]>
I will look into it and share the results. By the way, my students are excited by the pi-robot...we plan to expand it further...

Thanks again!

Statistics: Posted by Miltos — Sat Jan 31, 2015 9:02 am


]]>
2015-01-31T00:36:40+01:00 2015-01-31T00:36:40+01:00 http://forum.dawnrobotics.co.uk/viewtopic.php?t=1328&p=1653#p1653 <![CDATA[Re: Pan and Tilt Servos control?]]>
Fantastic to hear that you're up and running. :)

To change how the motors are controlled you'll need to modify mini_driver_firmware.ino.

You should see in the processMessage routine (line 458) that the left and right motor speed are read out of the 'set outputs' serial message and stored in global variables for motor direction and duty cylce (speed). At the moment the duty cycles are sent out to the DC motors using an interrupt service routine at the bottom of the file but I think that what you'd want to do is to add some code into the main loop (probably around line 280) to take the values stored in the globabl variables and send them to your servo motors.

Once you've made your changes to the firmware, change one or both of the values of VERSION_MAJOR and VERSION_MINOR at the top of the file. Then, when you next start up the robot, the web server should detect that the firmware is out of date, and compile and upload it (you can follow progress on the 192.168.42.1/logs.html screen).

Hope that helps.

Regards

Alan

Statistics: Posted by Alan — Sat Jan 31, 2015 12:36 am


]]>
2015-01-29T10:38:38+01:00 2015-01-29T10:38:38+01:00 http://forum.dawnrobotics.co.uk/viewtopic.php?t=1328&p=1650#p1650 <![CDATA[Re: Pan and Tilt Servos control?]]>
I need now to re-configure the left virtual joystick to control the servo motors as a substitute the electical ones. Where is this configuration file and how can I modify it as the two servo motors are connected now to D5 and D6 pins?

Regards,

Statistics: Posted by Miltos — Thu Jan 29, 2015 10:38 am


]]>
2015-01-28T21:01:00+01:00 2015-01-28T21:01:00+01:00 http://forum.dawnrobotics.co.uk/viewtopic.php?t=1328&p=1648#p1648 <![CDATA[Re: Pan and Tilt Servos control?]]>
Finally success!!! :D It was my fault!!! I will try now to upload something on Dagu Mini Driver and I will let you know the results....

Thanks a lot!!! again,

Miltos

Edited: Yes, success with the upload file as well...everything works great, now. I believe this will turn as a great guide for this forum too...

Statistics: Posted by Miltos — Wed Jan 28, 2015 9:01 pm


]]>
2015-01-28T14:39:32+01:00 2015-01-28T14:39:32+01:00 http://forum.dawnrobotics.co.uk/viewtopic.php?t=1328&p=1647#p1647 <![CDATA[Re: Pan and Tilt Servos control?]]>
I've got Dagu Drive Mini driver installed on COM4. This is the command line I give inside avrdude:

avrdude -c arduino -p atmega8 -P COM4

and this is the reply:

avrdude: stk500_getsync(): not in sync: resp=0xfe

Any guesses?

Statistics: Posted by Miltos — Wed Jan 28, 2015 2:39 pm


]]>
2015-01-28T00:35:31+01:00 2015-01-28T00:35:31+01:00 http://forum.dawnrobotics.co.uk/viewtopic.php?t=1328&p=1646#p1646 <![CDATA[Re: Pan and Tilt Servos control?]]>
No worries, glad I don't have to feel guilty about your Mini Driver not working. :)

The Atmega8 on the Mini Driver is fairly robust so I think it probably can be rescued. It may just be some problem with setting up wiring between the Arduino and the Mini Driver.

Perhaps you could try wiring VCC and GND on the Mini Driver to the 5V and GND lines on your Arduino. This would make sure that they have a common ground and power.

You may also be able to get more information by running avrdude from the command line. Avrdude is the program used by the Arduino environment to upload the bootloader. This is probably easier to do on Linux (you can run it from the Pi command line) but if you run

avrdude -c arduino -p atmega8 -P SERIAL_PORT

where SERIAL_PORT is the name of your COM or serial port (probably /dev/ttyUSB0 or /dev/ttyACM0 on Linux) then you should hopefully get some info on whether avrdude can see the Mini Driver (atmega8).

Regards

Alan

Statistics: Posted by Alan — Wed Jan 28, 2015 12:35 am


]]>
2015-01-27T16:49:10+01:00 2015-01-27T16:49:10+01:00 http://forum.dawnrobotics.co.uk/viewtopic.php?t=1328&p=1642#p1642 <![CDATA[Re: Pan and Tilt Servos control?]]>
The bootloader doesn't load eventhough I've tried every combination possible. I wonder if the VCC and GND pins on ISP have anything to do with this, as are not connected to anything.

Anyway, I will try a few combinations more and I'll tell you the results...

You will not find my name or email address in your database as I haven't purchased any robokit from Dawn robotics. It happened to have a mini Dagu Driver and an Arduino UNO and I build the camera robot from scratch with my students in Greece. I am a teacher of technology in a High School and this camera robot is an opportuinity for our students to learn and explore... You''ve already helped a lot and I want to thank you for this...

As a result, if you think that the Dagu mini driver is faulty we will proceed to buy another one from Dawn robotics.

Regards,

Miltos

Statistics: Posted by Miltos — Tue Jan 27, 2015 4:49 pm


]]>
2015-01-27T11:41:26+01:00 2015-01-27T11:41:26+01:00 http://forum.dawnrobotics.co.uk/viewtopic.php?t=1328&p=1641#p1641 <![CDATA[Re: Pan and Tilt Servos control?]]>
When it says 'this may take a minute' it should probably read this may take 5 minutes. Can you please leave it for a while longer to see if you get any results?

Also, I can't find your order number by searching for your name and email address in our order system. Could you please email it to me at sales@dawnrobotics.co.uk? Apologies that it's taking so long for you to get up and running with your robot, it really should be a much quicker, better experience than this.

Regards

Alan

Statistics: Posted by Alan — Tue Jan 27, 2015 11:41 am


]]>
2015-01-26T23:32:07+01:00 2015-01-26T23:32:07+01:00 http://forum.dawnrobotics.co.uk/viewtopic.php?t=1328&p=1637#p1637 <![CDATA[Re: Pan and Tilt Servos control?]]>
but this "journey" will take long... I've followed your guide for flashing Dagu Mini Driver with the bootloader but the process stucks on with this message "Burning bootloader to I/O Board (this may take a minute)...".
Then nothing happens :!:
May be my Dagu is completely dead but I can still see its blue light blinkign when connecting on board...

That's it for the moment...

Statistics: Posted by Miltos — Mon Jan 26, 2015 11:32 pm


]]>
2015-01-26T18:31:23+01:00 2015-01-26T18:31:23+01:00 http://forum.dawnrobotics.co.uk/viewtopic.php?t=1328&p=1635#p1635 <![CDATA[Re: Pan and Tilt Servos control?]]>
Great news that you have an Uno. This tutorial shows you how to use an Arduino as an ISP in general.

Specifically for the Mini Driver

  • Load the sketch File > Examples > ArduinoISP onto your Uno
  • Connect wires as follows between Uno and Mini Driver

  • Uno Mini Driver
    10 <---> RST (RESET)
    11 <---> MO (MOSI)
    12 <---> MI (MISO)
    13 <---> SCK

  • Provide power to both the Uno and the Mini Driver. Probably the best way is to plug them both into the same PC with USB cables.
  • In the Arduino IDE select Tools > Programmer > Arduino as ISP
  • Select Tools > Board > Arduino NG or older w/ ATmega8
  • Select Tools > Burn Bootloader


You can check that this has worked by trying to upload the Blink sketch to the Mini Driver.

Best of luck. :)

Regards

Alan

Statistics: Posted by Alan — Mon Jan 26, 2015 6:31 pm


]]>
2015-01-26T14:18:48+01:00 2015-01-26T14:18:48+01:00 http://forum.dawnrobotics.co.uk/viewtopic.php?t=1328&p=1634#p1634 <![CDATA[Re: Pan and Tilt Servos control?]]>
thanks for your reply again! I was suspicious about the bootloader too!!! I've got Arduino Uno.Can we fix the bootloader with that? If so kindly give me instructions on how to...

Thanks again,
Miltos

Statistics: Posted by Miltos — Mon Jan 26, 2015 2:18 pm


]]>
2015-01-26T13:01:09+01:00 2015-01-26T13:01:09+01:00 http://forum.dawnrobotics.co.uk/viewtopic.php?t=1328&p=1633#p1633 <![CDATA[Re: Pan and Tilt Servos control?]]>
Unfortunately it sounds as if you might have a corrupt bootloader on the Mini Driver. :P Do you have access to another Arduino and some wires that you could use to connect the Mini Driver to the Arduino? If you do then we can use it to fix the mini driver. Otherwise, please email your order number to sales@dawnrobotics.co.uk and I'll organise a replacement.

Regards

Alan

Statistics: Posted by Alan — Mon Jan 26, 2015 1:01 pm


]]>
2015-01-24T11:13:51+01:00 2015-01-24T11:13:51+01:00 http://forum.dawnrobotics.co.uk/viewtopic.php?t=1328&p=1632#p1632 <![CDATA[Re: Pan and Tilt Servos control?]]>
First of all my effort to re-programme the Dagu Arduino Mini driver didn't succeed... I've got the same error again and again whenever I try to upload the "Sweep" program from the ready made examples of Arduino IDE.
This is the message I've got:
////////
This report would have more information with
"Show verbose output during compilation"
enabled in File > Preferences.
Arduino: 1.0.6 (Windows 7), Board: "Arduino NG or older w/ ATmega8"
Binary size sketch: 2.416 bytes (from 7.168 byte)

avrdude: stk500_paged_write(): (a) protocol error, expect=0x14, resp=0x64
avrdude: stk500_cmd(): programmer is out of sync
////////

Secondly, a few things I want to draw your attention to...
The drivers of my Dagu Arduino Mini Drivers are installed correctly and Windows 7 (my OS) communicate with this driver on (COM4). So, no problems there... I've benn also very carefull to choose the correct board as per your instructions "Arduino NG or older w/ ATmega8". The program loads "I see the green bar progressing" but at the end the error message appears...

Thirdly, I've followed the given procedure by attached the AA batteries to the mini driver board and turned the switch on just in case... same results.

Last, I didn't find and D9 pin to attached the servo motor...my Dagu mini driver has the following pins D2,D3,D4,D5,D6, D11,D12.D13. The D9 pins are occupied by a jumper with D10,D8, and D7 as well.

That's all! any help will be much appreciated...

Regards,

Statistics: Posted by Miltos — Sat Jan 24, 2015 11:13 am


]]>
2015-01-23T09:57:44+01:00 2015-01-23T09:57:44+01:00 http://forum.dawnrobotics.co.uk/viewtopic.php?t=1328&p=1631#p1631 <![CDATA[Re: Pan and Tilt Servos control?]]>
Sorry, I wasn't clear. Could you please check to see if the left joystick works with one of the wheel motors attached?

To use the Arduino IDE with the mini driver

1. If your computer runs Windows then you first need to install the drivers linked from the product webpage.
2. Connect the mini driver to your PC using the USB cable
3. Open up the Arduino IDE
4. Open up File > Examples > Servo > Sweep
5. Attach a servo motor to pin D9. It's also probably a good idea to attach some AA batteries to the +/- pins of the mini driver and turn the switch on.
6. Select the board type by selecting Tools > Board > Arduino NG or older w/ ATmega8
7. Select the correct serial port with Tools > Serial Port
8. Hit 'upload'

After about 30 seconds (for some reason it takes quite a while for the mini driver to start up) you should hopefully see the servo motor start to move back and forth.

Depending upon whether that works or not you might also want to try uploading the program given in this blog post. One of the cool things about the mini driver is you can actually use it to build a robot on its own. Although of course, it's much better if you can get it to work with the Pi, as then you get camera and WiFi as well.

Best of luck. :)

Regards

Alan

Statistics: Posted by Alan — Fri Jan 23, 2015 9:57 am


]]>