Jump to content


LeafLabs Maple


  • Please log in to reply
22 replies to this topic

#1 c2po

c2po

    Key Member

  • Members
  • PipPipPip
  • 796 posts
  • LocationAtlanta, GA
  • Country: flag of United States United States


Posted 26 November 2011 - 08:38 AM

I'm wondering if anyone thought or tried to use LeafLabs Maple board (or any similar STM32F103RB based) as a platform to mimic CopterControl board hardware setup, so that CC firmware can be used either without or with minor modifications. I do know that some pins are routed differently on Maple, but not very many of them.

I have a Maple board just laying around and also few similar sensors, so not sure if I should try it.
I also know there is a port for Sony Move but just wanted to see if I can use the stuff that I have.

I still haven't installed development environment to compile firmware but I guess that shouldn't be a big problem. Main problem for me is unfamiliarity with the code which will take quite a while due to a size of code and lack of spare time, so I thought that might be changing the hardware to match CC schematics would be easier.

Any thoughts would be greatly appreciated.

Thanks,
Andrew

#2 dankers

dankers

    Janitor

  • Administrators
  • 5124 posts
  • Country: flag of Australia Australia


Posted 26 November 2011 - 10:36 AM

Should be fairly easy to get it to run, the structure of OpenPilot uses a single board file to define the hardware. The Maple is just an STM32 with a power supply and all pins to headers, they use the RB if I recall correctly.

Not sure if it worth the trouble? Its not easy to add the rest of the sensors, you will need analog power also and basically the best way would be to make a shield for the Maple, it could be a fair bit of work and cost but for sure it is possible. The F4 dev board might be a better option, these are free from ST in the US and also include and accel on board, a better MCU and more IO.

#3 D-Lite

D-Lite

    Core Team

  • Members
  • PipPipPip
  • 968 posts
  • Country: flag of Germany Germany


Posted 26 November 2011 - 10:38 AM

It really isn't that hard. The initial PS3 Move port took me about 4 weeks but this included things like setting up the development environment, learning STM32 (which I didn't used before), getting into the CC code and reverse engineering some parts of the hardware (in addition to the 90% Kenn already did on that part).

#4 D-Lite

D-Lite

    Core Team

  • Members
  • PipPipPip
  • 968 posts
  • Country: flag of Germany Germany


Posted 26 November 2011 - 10:44 AM

View Postdankers, on 26 November 2011 - 10:36 AM, said:

The F4 dev board might be a better option, these are free from ST in the US and also include and accel on board, a better MCU and more IO.

I agree with that, ordered one of these last week for just 16EUs. Even if you don't need the additional performance of that chip, to have 1MB of flash + 192K RAM is great.

#5 dankers

dankers

    Janitor

  • Administrators
  • 5124 posts
  • Country: flag of Australia Australia


Posted 26 November 2011 - 10:50 AM

Want to work on getting PyMite to run on it?

#6 ThomasB

ThomasB

    Advanced Member

  • Members
  • PipPipPip
  • 214 posts
  • LocationWesterstede
  • Country: flag of Germany Germany


Posted 26 November 2011 - 10:58 AM

Hi c2po

You know the MP32 project at virtualrobotix?
Roberto has ported the maple system and added some libs for copter sensors:
http://www.virtualro.../multipilot32-1
http://code.google.c...r_electronics32

so a re-porting to the maple board should be easy  ;)

best

Thomas

Edited by ThomasB, 26 November 2011 - 10:59 AM.


#7 ThomasB

ThomasB

    Advanced Member

  • Members
  • PipPipPip
  • 214 posts
  • LocationWesterstede
  • Country: flag of Germany Germany


Posted 26 November 2011 - 11:01 AM

View Postdankers, on 26 November 2011 - 10:36 AM, said:

The F4 dev board might be a better option.
Yes, I agree with that. The only bad thing.. it's not very small.

#8 dankers

dankers

    Janitor

  • Administrators
  • 5124 posts
  • Country: flag of Australia Australia


Posted 26 November 2011 - 11:03 AM

Neither is the Maple by the time you add the sensors to it.

#9 Reddog

Reddog

    UI Manager

  • Members
  • PipPipPip
  • 1200 posts
  • Country: flag of Australia Australia


Posted 26 November 2011 - 11:25 AM

View Postdankers, on 26 November 2011 - 10:36 AM, said:

The F4 dev board might be a better option, these are free from ST in the US and also include and accel on board, a better MCU and more IO.

Is there a particular version of the Processor/Dev board that will be similar to the Revo processor?

#10 ThomasB

ThomasB

    Advanced Member

  • Members
  • PipPipPip
  • 214 posts
  • LocationWesterstede
  • Country: flag of Germany Germany


Posted 26 November 2011 - 12:41 PM

The revolution board will use the F4 processor, and the STM32F4 discovery board is the cheapest way to get an experimental board for this processor.

#11 D-Lite

D-Lite

    Core Team

  • Members
  • PipPipPip
  • 968 posts
  • Country: flag of Germany Germany


Posted 26 November 2011 - 02:59 PM

View Postdankers, on 26 November 2011 - 10:50 AM, said:

Want to work on getting PyMite to run on it?

Sounds interesting but I have so many other unfinished projects at the moment :) What's the current status of PyMite? Is it already running on the Revolution board?

#12 dankers

dankers

    Janitor

  • Administrators
  • 5124 posts
  • Country: flag of Australia Australia


Posted 26 November 2011 - 03:08 PM

Not yet, its an area we need help with.

#13 Brian

Brian

    Core Developer

  • Members
  • PipPipPip
  • 567 posts
  • LocationTucson, AZ
  • Country: flag of United States United States


Posted 26 November 2011 - 04:06 PM

It really shouldn't be hard to port the CC code to the maple.  I almost purchased a maple mini when I found them on ebay for $25 a couple of weeks ago, but I thought it might be a knockoff, and I already have a few similar generic STM32 boards.  The maple mini looks like a nice small form factor, and could be useful for many projects.

I have a branch that removes most of the devices and makes a good starting point for point, and you can add back in whatever devices you want/need.  I have it running on a generic STM32 board, and I just ported it to the Move last night.

As for the F4, is there a branch with F4 code in it?  The next branch still seems to only contain code for the F1.  If I can get something running on the F4 I might be able to take a look an PyMite.

#14 c2po

c2po

    Key Member

  • Members
  • PipPipPip
  • 796 posts
  • LocationAtlanta, GA
  • Country: flag of United States United States


Posted 26 November 2011 - 04:16 PM

Wow, thank you guys, looks like I started quite a discussion going while I was asleep... :)

Thanks, Dave, actually I just happen to have all the pieces around, Maple (actually Olimexino to be correct, wich has very nice regs with separate analog part), some sensors, shield, etc., that's why I've got the idea to just throw everything together and see if it flies, and then play with it and use as a platform for experiments and learning the platform.
And you are right, Maple is RB version, so it is basically a direct match for CC.

Funny that for me being in the past both hardware guy and a programmer, for some reason it's more interesting and easier to tinker with the hardware than to change software.

Thanks for all the advices!
Thomas, I do know about virtualrobotix, but never looked into the details or a software. If I dive into that I would better get into CC code than some other projects, since I think it has the best design, well thought architecture, and greatest potential so far (from what I've seen of course).

I might need some help with setting dev environment and get started with the code, it's been a while (a couple of decades, lol) since I left that Unix/C stuff and went to a database side of the programming world. Although I've setup a git and pulled all the repository, but working with branches/checkouts and all this "make" stuff is kinda confusing and scary for me right now, I don't have a firm grasp on that yet.

I've also looked at Eclipse, I guess I should be able to setup that too, but again might have some dumb questions...
What would be the best part of the forum to ask for help with that?

Thanks,
Andrew

#15 naiiawah

naiiawah

    Core Developer

  • Members
  • PipPipPip
  • 309 posts
  • LocationNorthwest USA
  • Country: flag of United States United States


Posted 26 November 2011 - 08:54 PM

View Postdankers, on 26 November 2011 - 03:08 PM, said:

Not yet, its an area we need help with.
I'm interested in the Pymite porting.  I'll order a Discovery.

#16 dankers

dankers

    Janitor

  • Administrators
  • 5124 posts
  • Country: flag of Australia Australia


Posted 26 November 2011 - 09:26 PM

View Postnaiiawah, on 26 November 2011 - 08:54 PM, said:

I'm interested in the Pymite porting.  I'll order a Discovery.

Thank you, that would be really really helpful.

#17 naiiawah

naiiawah

    Core Developer

  • Members
  • PipPipPip
  • 309 posts
  • LocationNorthwest USA
  • Country: flag of United States United States


Posted 26 November 2011 - 09:45 PM

View Postdankers, on 26 November 2011 - 09:26 PM, said:

Thank you, that would be really really helpful.
NP!  Sounds fun actually.  Alas, the F4 Discovery boards are no longer free to the US, but Digi-Key will have one on the truck to me tonight if I can believe their site.

#18 Brian

Brian

    Core Developer

  • Members
  • PipPipPip
  • 567 posts
  • LocationTucson, AZ
  • Country: flag of United States United States


Posted 10 December 2011 - 04:56 PM

Just to follow up...  I ended up getting a Maple Mini.  It is a very nice, small board, and should be useful for one project or another.  I wired up JTAG and flashed the CC bootloader and my modified (stripped down) CC firmware, and it appears to be fully functional.

#19 ThomasB

ThomasB

    Advanced Member

  • Members
  • PipPipPip
  • 214 posts
  • LocationWesterstede
  • Country: flag of Germany Germany


Posted 10 December 2011 - 05:44 PM

Hi Brian,

Sounds good.
I'm very interested in your stripped down CC code,
Maybe, if you have some time, you could post it here, or push it in the GIT ?

best

    Thomas

#20 Brian

Brian

    Core Developer

  • Members
  • PipPipPip
  • 567 posts
  • LocationTucson, AZ
  • Country: flag of United States United States


Posted 10 December 2011 - 06:30 PM

View PostThomasB, on 10 December 2011 - 05:44 PM, said:

I'm very interested in your stripped down CC code,
Maybe, if you have some time, you could post it here, or push it in the GIT ?

Sure.  I have my transmitter box working now, and I plan on checking in that branch.  It's a stripped down CC with an additional module that reads the receiver an relays UAVTalk messages between two com ports.

It's really not hard to create a stripped down CC binary, though.  If it used the same (or very similar) processor, you can use the standard CC bootloader, comment out the initialization for the missing sensors in pios_board.c, and remove most (or all) of the modules.

Brian