Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
[-]
Slideshow

[-]
Stats
» Members: 893
» Latest member: Spyryt
» Forum threads: 601
» Forum posts: 3,191

Full Statistics

Control system
#21
(05-19-2019, 08:02 PM)Mrplasma Wrote: Can you share the odrive code? And would that work on the standard s.h.a.d.o.w?

The translation/emulation code I have written should work on any system designed to use a sabertooth motor controller. It receives the sabertooth commands on one serial port and retransmits ODrive commands on two others.

Unfortunately, I haven't tested if it actually works, and it is a bit complicated by the 2/3/2 code I also included.

I will look at putting what I have up on GitHub.
Reply
#22
Ok thank you would you be able to put up a video on the wiring portion of the odrives to the saber tooth?
Reply
#23
(05-19-2019, 10:37 PM)Mrplasma Wrote: Ok thank you would you be able to put up a video on the wiring portion of the odrives to the saber tooth?

In my build the ODrives Drivers replace the Sabertooth motor controller because I am using brushless foot motors. The ODrives can be controlled via RC (pwm) signals, or via serial (one serial line per ODrive).

I still haven't finalized how this is going to work in my droid, so don't have anything to show off yet.



In other news, my port of Shadow-MD to the M4 Metro Grand Central seems to be going well. I now have the PS3 nav controller pairing with the board using a simple OTG adapter, meaning there is no need for a USB host shield.

[Image: attachment.php?aid=1563]

I will attempt to build the audio playback directly into the board as well. It is definitely capable of playing back the audio samples, but I am not sure if it will slow the board down too much for the other functions it has to do. If I can get this to work it will might replace the need for the external mp3 trigger board. If the board almost does it at 120MHz, it is possible to overclock these up as far as 200MHz, but I am not sure what other side effects this has.

I am going to try and build every motor control option into the code, so that it will be usable for anyone wanting to run Shadow-MD on a more modern board. It will hopefully support Sabertooth, RC Servo (pwm) and ODrive.

I will also be building in the control logic for my 2-3-2 system.


Attached Files Thumbnail(s)
   
Reply
#24
So, is that board a "super Arduino?"

Did you have any problems with the BlueTooth dongle and getting the MAC address of you PS Move Controller?

Eebel
Reply
#25
(05-29-2019, 05:21 PM)Eebel Wrote: So, is that board a "super Arduino?"

Pretty much. It is the same form factor as an Arduino mega, and mostly pin compatible. Instead of the 8MHz Atmel micro it has a much more powerful 120MHz Arm chip with hardware floating point, hardware DACs, etc.

Many existing Arduino libraries will compile for it, but you do have to search around for ported libraries if the standard ones don't work. I found a customised USB library to suit which works, I am yet to find a hardware servo library that works, and may have to try and fix the bugs in it myself. Unfortunately I am no C++ programmer.

(05-29-2019, 05:21 PM)Eebel Wrote: Did you have any problems with the BlueTooth dongle and getting the MAC address of you PS Move Controller?

Yes, I struggled with the controller pairing on the mega when I did it originally, and I had forgotten the steps again this time. I need to make sure I document the process properly, because it seems to be the trickiest part of getting shadow up and running.

I notice that some people on astromech.net mention that they don't store the MAC of the controllers and they just make the first connected one the primary and the second connected the secondary. This is less "secure" than hard coding them, but much more convenient.

One thing that is trickier with this board is that the single USB port is used by the Bluetooth adapter so you can't see the serial debugging easily by plugging it in to your PC.

I am interested in looking into adding a touch screen shield for feedback and simple controls. I have ordered one to play with.

Martin
Reply
#26
I was wondering if you could hook a USB port to it so you could plug your PC and the Bluetooth dongle in at the same time.  Do you think that is possible?

Also, can it play sounds or do you still need an MP3 trigger board?


I have https://www.adafruit.com/product/815 on order. I will use one in the body and one in the dome of my R5. They will drive 16 servos or LEDs. Although, I am planning on using NeoPixels or DotStars to add the LEDs to the Dome. Since I only need a max of ten LEDs, it seems this chain able LEDs fit the bill perfectly.


Eebel
Reply
#27
Information 
(05-30-2019, 11:53 AM)Eebel Wrote: I was wondering if you could hook a USB port to it so you could plug your PC and the Bluetooth dongle in at the same time.  Do you think that is possible?

Also, can it play sounds or do you still need an MP3 trigger board?

To have the Bluetooth module plugged in you have to have the USB port in host mode. So it would be difficult to have it also taking to a PC which is also in host mode. I have ordered another ftdi serial adaptor to use as a serial debug connection (can't find the one I already have).

Yes, it can play MP3s directly, but I have not tested if it can do this and run everything else at the same time.

Martin
Reply
#28
I ordered one at it will be here tomorrow. Luckily, I already know the MAC address of all for move controllers I have. I’m going to go with a single controller and a backup for each droid.  Having two controllers one one droid uses too many hands!  I like to have a free hand when controlling the droid.

The sketch I’m starting with is from the guy who makes MagTags on Astromech.net and he has a very cool R5.  He started with SHADOW-MD and stripped out the MD and uses the Adafruit PWM servo drivers I listed above.  Mine won’t lay eggs.  However, I am building the buzz saw and bad motivator. (And life scanner if I have time before August Comicon in Dover).

Reply
#29
I have been making some progress on my control system. I have what I think is a working version of Shadow-MD for the Cortex M4 based board I am using, plus I almost have a working touch interface, just need to back integrate it into Shadow-MD. The specific functions I will make available on the touch screen are also a work in progress.

I am using an Adafruit 2.8" capacitive touch screen shield and a generic Mega-R3 proto-shield as a wiring breakout and level converter board. The exact layout, pinout, etc of the proto-board is a work in progress, but it will include 3.3 to 5V level conversion for all of the UARTs as well as logic in and out for the 2/3/2 system.

I am still yet to figure out if I will be able to playback the audio directly from this board without impacting the performance of everything else. On the plus side it does seem to run perfectly at 200MHz, would probably need to do quite a bit of testing before trusting my droid in public running on a severely overclocked chip.

[Image: attachment.php?aid=1569]
[Image: attachment.php?aid=1570]
[Image: attachment.php?aid=1571]


Attached Files Thumbnail(s)
           
Reply
#30
Wow, an overclocked droid! What was involved in converting the SHADOW-MD sketch to run on the M4? I tried compiling it and it failed. I saw a readme on Adafruit that covered some of the steps needed. However, I did not go down that rabbit hole yet. Since I’m starting with a heavily modified sketch already, my plan is to get that working with the Adafruit PWM boards and Sabertooth/Syren boards on a 2560 with the Bluetooth shield. So far I have the PlayStation move controller talking to the sketch. I have to solder the header pins on the PWM boards before I can test the servo controls.

I’m being side tracked because I am designing a buzzsaw for the droid which involves making a new door (the panel to the right of the coin slots) and all of the servo/motor mounts for the buzzsaw. Luckily, my first draft came out pretty good. If my luck holds, version two should be good enough to incorporate into the middle body ring. Once that five-day print is going i’ll be back to working on the control system.

Eebel
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)