Notifications
Clear all

how to compile source firmware  

  RSS
evan.r
(@evan-r)
Active Member
how to compile source firmware

I'm having trouble compiling the source code to my board.

I have a mk1 1.75mm with 1.3Rambo mini. I wanted to make a modification to the fan settings, and thought I would first try uploading the unmodified source code to the board before I changed anything.

However I'm confused about the steps:

The instructions required me to rename a variant for my printer (1.75 rambo mini 1.3). I did this, and then I tried to compile and upload, without success, am I missing something?

Other steps in the 'readme' included:
"Install the arduino addon in root of this repo", and "Remove Liquid Crystal library from your arduino or rename it"
Do I have to do these if my board already had prusa i3 firmware on it previously?

Any help appreciated

Evan

Opublikowany : 07/08/2016 1:58 am
PJR
 PJR
(@pjr)
Antient Member Moderator
Re: how to compile source firmware

Evan

Have a look at my post here: http://shop.prusa3d.com/forum/software-f13/how-to-setup-arduino-to-compile-fw-on-a-mac--t1258.html#p9453

The only bits missing the the copy & rename of the variant file and what to do with the LCD library , but that is adequately covered in the instructions on GitHub.

Peter

Please note: I do not have any affiliation with Prusa Research. Any advices given are offered in good faith. It is your responsibility to ensure that by following my advice you do not suffer or cause injury, damage…

Opublikowany : 07/08/2016 11:05 am
evan.r
(@evan-r)
Active Member
Topic starter answered:
Re: how to compile source firmware

Peter,

Thanks for your reply.

I am still having difficulty understanding what to do with steps 2 & 3 on the github:

"Remove Liquid Crystal library from your arduino or rename it"
- my arduino is the one that came with my prusa kit. Am I supposed to rename the liquid crystal library on the existing firmware? or rename it on the firmware I am about to upload?

"Install the arduino addon in root of this repo"
Wasn't able to find this add on. Is this the step that you instructed in the post you linked to? or something else?

Many thanks

Evan

Opublikowany : 07/08/2016 8:23 pm
evan.r
(@evan-r)
Active Member
Topic starter answered:
Re: how to compile source firmware

I thought it might be that I was referencing the wrong github page: https://github.com/prusa3d/Prusa-Firmware/tree/master

But when I go to this one and download the firmware folder is completely empty: https://github.com/prusa3d/Orignal-Prusa-i3

Opublikowany : 07/08/2016 8:34 pm
PJR
 PJR
(@pjr)
Antient Member Moderator
Re: how to compile source firmware

Evan

When you install the Arduino IDE, that automatically installs a variety of libraries including a "standard" LCD library. If is that you need to remove or rename.

Peter

Please note: I do not have any affiliation with Prusa Research. Any advices given are offered in good faith. It is your responsibility to ensure that by following my advice you do not suffer or cause injury, damage…

Opublikowany : 07/08/2016 8:51 pm
evan.r
(@evan-r)
Active Member
Topic starter answered:
Re: how to compile source firmware

Peter,

Thanks.

As for the arduino 'addon'... am I supposed to be able to find that somewhere on the github page? https://github.com/prusa3d/Prusa-Firmware/tree/master

Evan

Opublikowany : 07/08/2016 9:11 pm
evan.r
(@evan-r)
Active Member
Topic starter answered:
Re: how to compile source firmware

I've installed RAMBo board in arduino (assuming this is what you mean by arduino addon), I've changed the name of Liquidcrystal.h in arduino program files, and I've copied the correct variant into firmware folder where I renamed it.

Still I am getting this error message when compiling:

sorry - this program has been built without plugin support
exit status 1
Error compiling for board RAMBo.

My guess is that i need to install for RAMBo mini and not RAMBo? If so any idea where I would find this?

Opublikowany : 07/08/2016 10:12 pm
christophe.p
(@christophe-p)
Member Moderator
Re: how to compile source firmware

Hi Evan,

Here are some notes I wrote when I did it some times ago:

  • Install latest Arduino (1.6.9 fixed an issue that failed to compile with some previous version, I did not test 1.6.10)

  • Get the rambo addon from driver page: http://www.prusa3d.com/drivers (the last link at bottom right which redirect to: http://prusa3d.com/downloads/others/rambo_arduino_addon.zip )

  • Unzip this file and put the marlinAddon folder in C:\Program Files (x86)\Arduino\hardware you should then have a C:\Program Files (x86)\Arduino\hardware\marlinAddon folder.

  • Delete the C:\Program Files (x86)\Arduino\libraries\LiquidCrystal folder

  • Download the MK2 branch of the firmware in a zip file and unzip it (you can go to a specific commit) from https://github.com/prusa3d/Prusa-Firmware/tree/MK2

  • Copy the 1_75mm_MK2-RAMBo13a-E3Dv6full.h file from the "Firmware\variants" folder of the "Firmware" folder and rename it to "Configuration_prusa.h"

  • Start Arduino software

  • In Tools, choose Rambo card as card type

  • Load the Firmware.ino file from the unzipped folder

  • Compile with voodo chicken legs :), ignore the bootloader file not found, you should have a ~180k file generated
  • I'm like Jon Snow, I know nothing.

    Opublikowany : 07/08/2016 11:11 pm
    evan.r
    (@evan-r)
    Active Member
    Topic starter answered:
    Re: how to compile source firmware

    Thanks!

    Im using an i3 mk1... is all of this interchangeable?

    Opublikowany : 07/08/2016 11:14 pm
    Vojtěch Bubník
    (@vojtech-bubnik)
    Member Admin
    Re: how to compile source firmware

    I think I extracted following
    http://prusa3d.com/downloads/others/rambo_arduino_addon.zip
    into the Arduino installation
    C:\Program Files (x86)\Arduino\hardware

    > Im using an i3 mk1... is all of this interchangeable?

    The MK2 branch does not compile for MK1 yet. We are working on that.

    Vojtech

    Opublikowany : 07/08/2016 11:16 pm
    evan.r
    (@evan-r)
    Active Member
    Topic starter answered:
    Re: how to compile source firmware

    Hm okay - so does that mean with Mk1 that there is no way for me to access the source code for the firmware and upload it to my printer?

    Thanks for the patience - I'm inexperienced with this.

    Opublikowany : 07/08/2016 11:22 pm
    Vojtěch Bubník
    (@vojtech-bubnik)
    Member Admin
    Re: how to compile source firmware

    We don't have an update for the MK1 yet. Most of the updates we did for MK2 firmware have no meaning for the MK1.
    Vojtech

    Opublikowany : 07/08/2016 11:26 pm
    christophe.p
    (@christophe-p)
    Member Moderator
    Re: how to compile source firmware

    Sorry, I didn't understand that you are compiling firmware for the mk1.

    Then you should get the master branch, and copy the firmware\variants\1_75mm-RAMBo13a-E3Dv6lite.h file to firmware\Configuration_prusa.h file instead.

    That should generate a ~120k hex firmware file, end as Voltech said it's still the version 2.2.4.

    I'm like Jon Snow, I know nothing.

    Opublikowany : 07/08/2016 11:44 pm
    Alex Scoullos
    (@alex-scoullos)
    New Member
    Re: how to compile source firmware

    At risk of hijacking the thread- assuming you are flashing a bare RAMBO mini 1.3a (for an i3mk2); what should you do when the compile fails?

    For example:

    Arduino: 1.6.9 (Windows 10), Board: "RAMBo"

    In file included from sketch\SdFile.h:27:0,

    from sketch\cardreader.h:8,

    from sketch\Marlin_main.cpp:58:

    SdBaseFile.h:38: error: using typedef-name 'fpos_t' after 'struct'

    struct fpos_t {

    ^

    In file included from sketch\Marlin.h:10:0,

    from sketch\Marlin_main.cpp:38:

    c:\users\stryer\appdata\local\arduino15\packages\arduino\tools\avr-gcc\4.9.2-atmel3.5.3-arduino2\avr\include\stdio.h:950:33: note: 'fpos_t' has a previous declaration here

    __extension__ typedef long long fpos_t;

    ^

    sketch\Marlin_main.cpp: In function 'void process_commands()':

    Marlin_main.cpp:2920: error: 'mbl' was not declared in this scope

    mbl.reset();

    ^

    Marlin_main.cpp:2937: error: 'MESH_HOME_Z_SEARCH' was not declared in this scope

    current_position[Z_AXIS] = MESH_HOME_Z_SEARCH;

    ^

    exit status 1
    using typedef-name 'fpos_t' after 'struct'

    I am currently unable to use the firmware updater as it will not indicate a com port or allow a rescan, so I am trying to compile and upload the firmware instead (mk2 branch github).

    Any help would be appreciated (and would be happy to start a new thread if more appropriate)

    Opublikowany : 25/08/2016 5:07 am
    christophe.p
    (@christophe-p)
    Member Moderator
    Re: how to compile source firmware

    Hi Alex,

    I rather think that you forgot one of the step listed in this thread. Probably the most effective to do is to restarts from the start, reinstalling Arduino from scratch and following the step by step indicated below.

    I'm like Jon Snow, I know nothing.

    Opublikowany : 25/08/2016 4:45 pm
    Alex Scoullos
    (@alex-scoullos)
    New Member
    Re: how to compile source firmware

    I will give that a go then. On a side note, I was able to flash the rambo mini with the latest firmware on a different pc- so that's great. Now to figure out why my LCD dispaly is lit, but with no text....Im assuming the random trimpot on the floor has SOMETHING to do with it 😉

    Opublikowany : 25/08/2016 11:23 pm
    Share: