All-in-one development IDE? - Page 1
Forum section: electronics / general

author: brainwash
author_rank: Frequent Contributor
timestamp: December 14, 2016, 04:14:48 am
content: I have various boards around the house and frequently find myself making a project on different platforms and deploying them. However I have a huge issue with toolchains and IDEs, as well as figuring out the low-level configuration commands for each chip. That's why most of the time I just default to some Arduino port if I want to get something done quickly. This means that most of the time I have to deal with the horrible IDE as well.I'm looking for a cross-platform solution (preferably Eclipse-based) that has a single setup (not one Eclipse instance for each board) and that can do ICD, for: 8-bit ATMega, MSP430, Stellaris/Tiva-C, ESP8266, STM32. PIC is a bonus but I haven't used it in years.My current TI stuff requires probably around 2GB of Windows-only stuff at the root of my drive. AFAIK Energia relies on it as well.The Arduino IDE is horrible (no ICD, no autocomplete, no VCS) but provides easy access to most platforms so it tends to get used the most.I would also like to just copy/paste the setup to a different machine and possibly even to a different OS.If anyone is having the same issues and has found a solution care to provide a quick description? Obviously ICD only where applicable.

author: ez24
author_rank: Super Contributor
timestamp: December 14, 2016, 05:32:40 am
content: Following (I finally got up the nerve to say this)

author: ez24
author_rank: Super Contributor
timestamp: December 14, 2016, 06:24:40 am
content: Quote from: Bud on December 14, 2016, 06:17:09 amI am going to use this from now on - thanks

author: sleemanj
author_rank: Super Contributor
timestamp: December 14, 2016, 06:56:17 am
content: Maybe PlatformIO, i don't know if it supports all your platforms. Personally, I tried it, but found it too complicated and unintuitive for my liking, but that said i also hate eclipse and my "IDE" of choice is a text editor with syntax highlighting, a file tree and a shell terminal, that's all I want, I absolutely hate any "project management" stuff in an IDE.

author: rstofer
author_rank: Super Contributor
timestamp: December 14, 2016, 07:22:22 am
content: Both Microsoft Visual Studio Community Edition and Eclipse support Makefile projects. You can put the toolchain anywhere you want as long as you specify the location in the Makefile.There is an Arduino plug-in for Visual Studio that adds a few buttons that are familiar to Arduino IDE users including COM port, board type, compile, download, etc. It's a vast improvement over the Arduino IDE.Eclipse is now heavily into building the project Makefile for projects it understands.You should probably expect to have to get involved with the Makefile if you project grows to multiple files.This isn't especially hard but there is a bit of a learning curve.

author: Karel
author_rank: Super Contributor
timestamp: December 14, 2016, 07:39:21 am
content: I don't want to use one IDE solution for everything.But I do use my favorite text editor Kate for everything.Most IDE's are aware when an opened file is changed from outside the IDE and reload the file automatically.

author: Jeroen3
author_rank: Super Contributor
timestamp: December 14, 2016, 08:10:05 am
content: A cross-platform cross-compiler with debugger for ATMega, MSP430, Stellaris/Tiva-C, ESP8266 and STM32.It's good to have dreams.

author: hans
author_rank: Super Contributor
timestamp: December 14, 2016, 09:14:00 am
content: Nope.If a chip has a GCC port that's great for Eclipse, however different chips still have different gdb proxies. For example Microchip XC16 and XC32 is possible to put into Eclipse, but I'm not familiar with a GDB proxy for 16-bit PICs.You probably have way much more admin time than just learning 2 IDE's side by side. In addition, you probably also lose quite a lot of time on the quirks of Arduino's IDE.Multi machine is hard enough given how fragmented installations are.Multi OS is out of this the world.

author: nctnico
author_rank: Super Contributor
timestamp: December 14, 2016, 09:16:46 am
content: AFAIK Eclipse should get you quite far. I'm using it for various microcontrollers (including PIC -shudder-), PHP (if I really really have to), C++ and VHDL.

author: ElektroQuark
author_rank: Unknown
timestamp: December 14, 2016, 09:30:55 am
content: Is it possible to use Microchip debug probes (PICKit, IDC, REAL ICE) with Eclipse?

author: Brutte
author_rank: Frequent Contributor
timestamp: December 14, 2016, 10:13:09 am
content: Quote from: brainwash on December 14, 2016, 04:14:48 amOk, so I have done: coding + compiling + debugging + programming + documentation, etc. on AVR8, PIC32, ARM Cortex M (STM32, LPC17xx, Stellaris and other) plus of course x86, under single instance of Eclipse. As you are mostly interested in in-circuit-debugging, for AVR8 I used JTAGICE + avarice, for PIC32 there was PICKIt2+ejtagproxy, for Cortex-M there were various dongles with OpenOCD. I have not tried MSP430. AFAIK you can also use gcc for Xtensa core and if the GDB is available then that should not be more complicated than for other above architectures. It is also worth noting that there are simulators available for those (simulavr for AVR8, qemu for cortex-m, mips and xtensa) so many algorithms can be debugged/simulated without actual hardware under same Eclipse.

author: kripton2035
author_rank: Super Contributor
timestamp: December 14, 2016, 11:43:55 am
content: Quote from: Karel on December 14, 2016, 07:39:21 amthis even works with the arduino IDE !

author: brainwash
author_rank: Frequent Contributor
timestamp: December 14, 2016, 11:59:14 am
content: I wasn't expecting so much feedback, thanks everyone. It seems like quite a few have similar needs as in the first post.To detail: ICD (or step-by-step debugging) would be nice but it obviously won't work with every platform.Replying in random order:Quote from: Brutte on December 14, 2016, 10:13:09 amThat sounds quite interesting and very close to what I want. Is there any way you can share the way you've configured your eclipse installation? Or perhaps even upload it somewhere, if it's easier.Simulators are very useful for automated testing. Through careful abstracting/wrapping of the hardware-specific functions you can easily test the code or port it to another platform. So testing was one of my future topics after finding a proper IDE/toolchain flow. Keil could do that and I think the TI version of Eclipse can also.Quote from: hans on December 14, 2016, 09:14:00 amI don't think you can  debug low-end PIC16F, wasn't even aiming for that. A makefile approach is fine.Quote from: nctnico on December 14, 2016, 09:16:46 amPerhaps I misspoke, Eclipse is ok, just not sure if you can integrate everything inside it and still have it perform properly. I have around 4-5 instances floating around for various stuff. OTOH I have at least: one for enterprise Java, one for GWT, one for embedded C, one from TI, one for AngularJS.Quote from: Jeroen3 on December 14, 2016, 08:10:05 amNot sure if it's meant at my post or it's just a wish. But I'm not talking about a single compiler, that would be almost impossible, just integrating several projects on different platforms under the same IDE and keep a constant workflow.Quote from: rstofer on December 14, 2016, 07:22:22 amMakefile is fine, it's industry standard AFAIK. The real problem is with the libraries/includes/platform, TI for example has an unreadable XML format. It's probably unreadable even to them as they have broken compatibility several times.VS is nice but I don't particularly like it and it's not cross-platform. I could get used to it, if needed.Quote from: sleemanj on December 14, 2016, 06:56:17 amI found out about platform.io after writing my original post. It looks very promising and 'they' seem to be considering adding debugging support. I also don't like it but willing to sacrifice some of my habits if it gets the job done.As a side note - I've also grown fond of the IntelliJ-based IDEs from Jetbrains. For C they have CLion, which I haven't used, but I assume it's as good as the other ones.Quote from: Karel on December 14, 2016, 07:39:21 amI'm not sure if you can get an external IDE to highlight compiler errors without a lot of fumbling. Also the advantage of an integrated IDE is that you can debug line-by-line and check the current state of a variable. Sure, you can read the errors and jump manually, run git from the command line, run gdb manually - but then you are only a level above notepad.So far there seem to be two promising possibilities: platform.io (can be used with another IDE for editing files) or a custom setup of Eclipse.

author: Brutte
author_rank: Frequent Contributor
timestamp: December 14, 2016, 01:46:12 pm
content: Quote from: brainwash on December 14, 2016, 11:59:14 amWell, I do not use AVR8 and MIPS any more. If you want the installation details, that was always a raw Eclipse + CDT and various plug-ins.For AVR8 search avrfreaks and my posts. For examplehere. There is a debugging session screenshot included in one of the posts.As for mips, you need ejtagproxy.As for cortex-M there are zillions of projects showing how to run gdb with openocd and eclipse - nothing fancy.Mind you need some IO viewer plugin as the built-in Eclipse "memory view" is not very convenient. I suggestembsysregview: (AVR8, Cortex-M, MSP430 etc) or GnuArmEclipse (mostly cortex).As for languages, C and C++ works out of the box (CDT). For Ada you need another plugin (from adacore).As for OSes: FreeRTOS has its plugin and Chibios has another plugin. Ada runs with its own OS.Of course you need other generic plugins (for doxygen, egit, qemu, serial terminal etc) to do programming but I assume you already know that.

author: brainwash
author_rank: Frequent Contributor
timestamp: December 14, 2016, 03:01:09 pm
content: But I'm curios about specifics:- how do you handle different gcc versions? Normally you set up a global system path or a project override.- what's your workflow for creating a new project? Do you duplicate an existing config or create one from scratch?- how is the MCU defined? As a project variable?- how does the IDE handling moving from place to place? If you move a tooling folder do you have to update all projects?- are the build and debug steps done through Makefile or .bat/sh files?

author: nctnico
author_rank: Super Contributor
timestamp: December 14, 2016, 03:51:54 pm
content: In Eclipse you can set the paths to a specific toolchain for a build target in a project. This means you can build the same project for multiple microcontrollers if you want. Within a workspace you can have different projects (for example VHDL and C++).

author: eugenenine
author_rank: Frequent Contributor
timestamp: December 14, 2016, 04:15:48 pm
content: UCEIDE is a project that whose goal IIRC is just this. Its Arduino like so it may not be what you want.I have MPLAB X (with its copy of eclipse) and then eclipse by its self. Do you setup the standalone eclipse to work with other toolchains then bring in all the Microchip stuff from mplax x or do you start with Microschip's mplabx and add other stuff to it?

author: ElektroQuark
author_rank: Unknown
timestamp: December 15, 2016, 07:55:49 am
content: MPLAB X is based on NetBeans not Eclipse.

author: Brutte
author_rank: Frequent Contributor
timestamp: December 15, 2016, 08:16:14 am
content: Quote from: brainwash on December 14, 2016, 03:01:09 pm- how do you handle different gcc versions?#if #endifif that is for avr then __AVR is defined in a compiler and if x86 then __x86__ (IIRC),if that is Keil then __CC_ARM if that is SDCC then it is __SDCC etc- what's your workflow for creating a new project?The plugins (avr-eclipse and gnu-arm-eclipse) come with wizarding. Of course you can copy a template project or your own. Or you can create a makefile project and provide your own makefile.- how is the MCU defined? As a project variable?That is defined as -D and plugins maintain that. Or you can -D manually if you like to. Mind you also need to link proper libraries and linker script for a particular mcu - wizarding does that automagically but in a manual mode that is your duty.- how does the IDE handling moving from place to place? If you move a tooling folder do you have to update all projects?Not sure if I understand. The makefiles are governed by plugins via wizarding and if you move or add a file or folder then the makefile is updated after you click "make all". If you maintain your project as a makefile project then that depends on the details of the makefile you write. So adding a folder requires adding its path in a makefile or writing a makefile that discovers subfolders automatically. That depends on your make-fu, not the eclipse.- are the build and debug steps done through Makefile or .bat/sh files?This is made via makefiles. But the makefile can be either created by a plugin (you pick options from drop-down list) that creates makefile, or alternatively you can use a generic makefile project where you edit a makefile in a text mode.EDIT:Sorry, didn't notice - build steps are made via makefile. And if you want to debug you have to build an elf with debug information (usually this is default with wizarding). As for debugging - this is maintained by debugging module (Eclipse CDT comes with it installed, with dedicated menu).As for exactly the thingy you want to debug - if that is qemu then you need to install and use "debug with qemu", if that is native application then you need to use "debug native application" (this one is preinstalled with CDT), if it is debug with OpenOCD then you pick "debug with OpenOCD" (I think this one comes with gnu-arm-eclipse), etc. Nothing sophisticated. And there is also a generic option for raw "gdb hardware debugging" where you can manually specify every woodoo gdb option (kinda "gdb expert mode").So, gdb connects to debugging dongle via some communication channel. Not sure what dongle you own but it is usually via pipe or TCP/IP or serial. Again, if your dongle comes with ethernet connectivity - just plug it in and configure gdb to access it. If it comes with serial - do serial. However most common dongles are "brain-dead-dongles" that require a middleware application that translates commands in between gdb and dumb debugging dongle. OpenOCD comes handy, supports many platforms. For AVRs the middleware is called avarice. For PIC32 this is called ejtagproxy, etc. Every dongle manufacturer provides its own gdb middleware (or at least should) and there is no one-serves-all.Of course the middleware has to be running attached to a target, just waiting for gdb connection. Then you run gdb, the connection is established with a dongle, and you are ready for debugging.

author: eugenenine
author_rank: Frequent Contributor
timestamp: December 15, 2016, 06:27:48 pm
content: Quote from: EdoNork on December 15, 2016, 07:55:49 amerr, yea, got my open source projects mixed up. Same concept though just search and replace the names. do you set up MPLAB X's netbeans to compile other stuff or do you install standalone netbeans and then point it to the microchip toolchain?

author: brainwash
author_rank: Frequent Contributor
timestamp: December 16, 2016, 01:03:31 pm
content: Quote from: Brutte on December 15, 2016, 08:16:14 amThanks for the clarification so far.I meant if the installation is portable, like grabbing the Eclipse and tools folders from your machine and continuing work on another machine with minimal setup.Regarding cross-platform, I meant the development machine (Windows/Linux/OSX), not the underlying MCU. But I guess that's very dependent on the MCU tooling. It probably makes more sense to put everything into a VBox, but that requires a more-than-decent machine which kind of excludes ultra-light laptops.

author: ^_^
author_rank: Regular Contributor
timestamp: December 16, 2016, 02:45:24 pm
content: Well, when it comes to JUST editing, there was a guy in my previous work who used always Eclipse.He hated MPLAB and he'd only open it to compile the Eclipse-edited code, haha.I think you can do the same with Visual Studio, which also comes with epic code editor.Then you're only left with debugging with the vendor-specific IDE.That's always something.// Right now I'm using Keil, and it just might be one of the worst IDEs there are.//

author: Brutte
author_rank: Frequent Contributor
timestamp: December 16, 2016, 04:16:12 pm
content: Quote from: ^_^ on December 16, 2016, 02:45:24 pmKeil has released an Eclipse uVision plug-in several years ago. You start uVision in the background and use Eclipse as a front-end (it does debugging and even simulation).

author: ^_^
author_rank: Regular Contributor
timestamp: December 17, 2016, 04:06:28 pm
content: Quote from: Brutte on December 16, 2016, 04:16:12 pmBro, i installed it and I think it's so much not worth it.First, Keil folder jumped to 6.5GB (I don't think it was more than 4GB before) as you need to install some "legacy support", you can't just install the plugin itself (according to the instruction on Keil webpage).Then this is the list what it can do:http://www.keil.com/support/man/docs/ecluv/And I think you can't compile the code beforehand (in just eclipse)! You can debug though, lol?So you probably need to set up the compiler yourself and the plugin cannot get it working for you through Keil...This is crap, it should work straight awayDissapointed.

author: Brutte
author_rank: Frequent Contributor
timestamp: December 17, 2016, 08:14:11 pm
content: Quote from: ^_^ on December 17, 2016, 04:06:28 pmEclipse is not a compiler.As for wizarding, I'd be surprised if the plug-in did not offer wizarding a "hello world" sample project.I am sure the structure of the project in uVision is different than in Eclipse CDT so you cannot just copy the project files from uVision to Eclipse or from Eclipse to uVision and expect that to work out of the box.

author: Jeroen3
author_rank: Super Contributor
timestamp: December 19, 2016, 08:24:27 am
content: It would make no sense to copy project from uVision to Eclipse since you can't run RVCT without uVision. (licensing issues)

author: brainwash
author_rank: Frequent Contributor
timestamp: November 03, 2017, 12:39:03 pm
content: Resurrecting this as I've revisited this topic a week ago while getting started with an ESP32.I think I got a solution to my initial problem: Eclipse + PlatformIO + OpenOCD with a hardware debugger of your choice.PlatformIO has a debug option, but it's a monthly plan, so I did not even test it.You can use any IDE you want with PIO, but Eclipse was my choice as I've used it for >10 years.PIO allows you to use standard C/C++ code and move slowly away from the Arduino environment as your project grows. But you can still use the extensive Arduino library set, which is not worth reinventing. Especially the TFT/EPD libraries.Debuggingis a mixed bag, I'm currently using a Bus Pirate with a custom-built OpenOCD. It's slow and works only 50% of the time. But when it works, it's priceless: you can inspect all variables, step through code, see all the threads, just like you would on a computer. But it took me >12 hours to set everything up, mostly through trial-and-error. And the platform (ESP32) is still in development, not as stable as the other ones.I've got an Olimex Tiny H on the way as well as a JLink clone, hopefully these will be faster, more reliable and better supported.Portabilityis decent: Eclipse CDT is stock, PlatformIO is easy to install, the project configuration files (makefiles and tooling) use a path system that make them usable across machines. Versioning control is done on bitbucket.org , as they have free private repositories. I guess you could host your own, a server costs 5$/mo at digitalocean and you can do a lot with it.Ease of use- currently the best compromise I could find. You can start a project in Arduino (if you want a dirty prototype), create a new project with "pio init" and copy the arduino files over. Maybe make a small change to the platformio.ini file and then just click "Build" and "Upload". Unfortunately you have no direct control over the Makefile, AFAIK. But that's beyond my paygrade anyway...

author: NorthGuy
author_rank: Super Contributor
timestamp: November 03, 2017, 04:01:00 pm
content: Quote from: brainwash on November 03, 2017, 12:39:03 pmAssuming your time is worth $100/hr, $1200 for something which is slow and works only 50% of the time doesn't strike me as a good solution.

author: brainwash
author_rank: Frequent Contributor
timestamp: November 03, 2017, 05:05:30 pm
content: I guess contributing open-source is like throwing away suitcases of money...That time wasn't spent in vain, it now takes me 10-20 minutes to set up a new project with debugging on any 32-bit platform of my choice. Also, some hardware debuggers work better than others, for specific platforms, swapping them now takes 5 minutes.Learning how to patch and compile OpenOCD - well, arguably a niche skill. But I do this as a hobby, I imagine there are professionals who just whiz through this.Anyway, in total, those 12 hours will probably save me at least 12 hours in debugging issues, in the future. And if I share the knowledge, the benefits multiply.

author: JoeO
author_rank: Frequent Contributor
timestamp: November 03, 2017, 06:14:17 pm
content: Quote from: NorthGuy on November 03, 2017, 04:01:00 pmDo you have or know of a better solution?

author: brainwash
author_rank: Frequent Contributor
timestamp: November 03, 2017, 07:10:49 pm
content: Just to be clear, by 50% I mean it fails on debugger startup, try it a few times and it runs fine. Once it's started there's no issue with it, except the slowness. It's ok for development, not ok for problem reproduction.

author: jaycee
author_rank: Regular Contributor
timestamp: November 16, 2017, 08:58:48 pm
content: For AVR, i use code::blocks to drive the Atmel AVR gcc toolchain. code::blocks will drive pretty much any GCC based toolchain, and a few others as well, including the Microsoft compiler.

author: ElektroQuark
author_rank: Unknown
timestamp: November 17, 2017, 12:21:53 pm
content: And Code::Blocks is really lightweight and fast. You can use it with GCC and SEGGER J-LINK and SEGGER Ozone debugger.

author: spongman
author_rank: Newbie
timestamp: November 17, 2017, 04:40:37 pm
content: i have used the PlatformIO Atom plugin for arduino-like stuff in the past (arduino, mbed, esp8266 rtos & stm32cube). it trivializes installing those frameworks and 3rd party libaries and the code editor is half decent.for me, it's a no-brainer drop-in replacement for the arduino abomination.

author: CM800
author_rank: Frequent Contributor
timestamp: November 17, 2017, 04:44:44 pm
content: Visual GDB covers a whole load of different standard chips, including Linux and Android projects.

author: technix
author_rank: Super Contributor
timestamp: November 20, 2017, 07:27:27 pm
content: For me stock Eclipse CDT have great milage. I use macOS as the development system so there is no Keil available for me - only GCC for most platforms, and I will stick to cross-platform software here so you can use it on Windows too. I have AVR + ARM up now so it covers your AVR, Stellaris, Tiva and STM32.The ARM stuff is a lot easier thanks to the GNU MCU Eclipse project. That plugin gives stock Eclipse support to generate the appropriate makefiles for ARM, and getting stuff up is usually a three-minute job if you have a template ready. You also get debugging with either J-Link or OpenOCD along with GDB. OpenOCD is actually extremely versatile as it supports almost all debug probe imaginable.For AVR you do need to write the makefiles yourself. Debugging is achievable with avarice and GDB, however you will need to build avarice from source if you want to use Atmel ICE. I even had to change the code a bit to make it recognize libhidapi as well as properly enumerate the Atmel ICE device under macOS.