Microchip Arduino thing interview questions?

Anything not related to a specific project.

Re: Microchip Arduino thing interview questions?

Postby schazamp » Fri May 27, 2011 2:03 pm

This is really interesting (listening now), thanks for going through all of this, and posting it.
schazamp
Full Member
Full Member
 
Posts: 225
Joined: Wed Jan 19, 2011 9:51 am
Location: St. Louis, MO

Re: Microchip Arduino thing interview questions?

Postby ricklon » Fri May 27, 2011 2:25 pm

I'm Rick from Fair Use Building and Research. I did the updates to the Arduino IDE. I rewrote the Compiler.java process to support multi platforms specified in a platforms.txt. I also, added property inheritance, and logging. The changes are set to be able to meld back into the Arduino platform, the entire history of the project is in the git version history. Mark Sproul did the requirements for platforms.txt, bootloader, and a majority of library updates to make it possible to get hexs uploaded and working. This version uses avrdude for hex uploading.

Our, Fair Use Building and Research, goal is that the platform provider create a ./hardware/platform_dir and put everything in it. So new platforms are copied in, and automatically added to the software.

A note about the build process. The compiler source code is held in a zip file in a dist directory and the copied into ./compiler directory for the creating the distribution. So that licenses.txt file is sitting in that ./compiler directory. So the two are merged into the final distribution. However, it's not in the source here https://github.com/chipKIT32/chipKIT-cxx. Which is a separate project.

I'm glad you linked to the source. If anyone wants to clone or fork it it's out there to do that.
ricklon
Newbie
Newbie
 
Posts: 1
Joined: Fri May 27, 2011 1:44 pm

Re: Microchip Arduino thing interview questions?

Postby arhi » Fri May 27, 2011 4:28 pm

I'm confused with this thread big time :( ... so I'd appreciate some insight. With regards to arduino platform (and the new microchip version of it) I'm not very interested as ppl using arduino behave like a religious group and I really hate religion so I stay away from it ... also, as much as arduino is great for beginners I kinda believe I have enough lines of code under my fingers not to be noob wrt mcu's...

What I don't get is this:
Microchip always had "weird" licences for everything. "you can use for any of your products without warantee blah blah .. but you cannot share" ?! so the whole MAL you could use your own but not in open source products ... imho - weird big time .. it's just preventing ppl from using microchip stuff (for e.g. the reason I moved from 32mx to cortex m3). So now there's this arduino stuff that's partially (or fully?) open source and that has again some weird licences? and that will have a new set of libraries that will support what? under what licence? How in the name of Nikola Tesla is microchip going to explain the cost effectiveness of maintaining 2 sets of libraries, one for this arduino stuff and one for mplabx? This chipkit32 is gcc-mips + patches ... C32 that comes with mplabx (that is also multiplatform) is again gcc-mips + patches .. one is free and open source and other is limited and closed source .. where's the sense in that? (not to mention, how come a gcc + patches can be closed source?! it's kinda against gcc licence?)

I love microchip devices, I love the mcu's I love the op-amps ... I loved the pickit2 .. but on the software side .. old mplab was terrible, licences suck, mal is great but licensed in a way that you do not want to use it for open source project ... I still have over 100 different microchip mcu's at home, 4 different dev kits and I still decided to leave it all and move to stm32 cortex m3 devices, get new dev kit, new programmer, setup new tools .. start from scratch, just because they have normal gcc and open source libraries...

So to formulate the question .. is this arduino thingy now bringing us "open source microchip tools" and will the only way to use this open source tools be to join the arduino religion or some of those openness will brush on the "normal" tools (mplabx+compilers_mal)?
User avatar
arhi
Hero Member
Hero Member
 
Posts: 2160
Joined: Thu Jun 24, 2010 11:41 am
Location: Belgrade, Serbia

Re: Microchip Arduino thing interview questions?

Postby jamodio » Fri May 27, 2011 10:49 pm

ian wrote:Audio file, edited to remove banter and cross talk. Unedited audio available if there is a controversy :) Will try to make a smaller embedded version by next week.


Audio sounds quite good, thanks for recording the presentation.

By any chance do you have a link to their Powerpoint slideshow ?

Cheers
Jorge
jamodio
Newbie
Newbie
 
Posts: 7
Joined: Thu May 26, 2011 11:58 am

Re: Microchip Arduino thing interview questions?

Postby ian » Sat May 28, 2011 4:20 am

presentation attached.
Attachments
chipKIT Presentation Final 5_18_11.zip
(1.8 MiB) Downloaded 1451 times
User avatar
ian
Crew
Crew
 
Posts: 10803
Joined: Mon Jul 06, 2009 6:14 am

Re: Microchip Arduino thing interview questions?

Postby jbeale » Sat May 28, 2011 10:34 am

I'm interested in using the PIC32's timer input capture mode to measure pulsewidths with better accuracy (80 MHz clock = 12.5 ns resolution) than I can get with a stock 16 MHz Arduino.

Are there any examples of such a thing online? Can it be done using the Chipkit version of the standard Arduino dev environment? Which timers does the system use (eg. millis() clock)?
jbeale
Full Member
Full Member
 
Posts: 158
Joined: Thu Jan 13, 2011 6:48 pm

Re: Microchip Arduino thing interview questions?

Postby jbeale » Sat May 28, 2011 1:44 pm

ok, I realize my timer question is probably better answered in the chipkit forum, so I posted it there.
http://www.chipkit.org/forum/viewtopic.php?f=6&t=45
jbeale
Full Member
Full Member
 
Posts: 158
Joined: Thu Jan 13, 2011 6:48 pm

Re: Microchip Arduino thing interview questions?

Postby Markus Gritsch » Sat May 28, 2011 4:16 pm

Since I had a board with a PIC32MX795F512H I built some time ago (http://overtone-labs.ning.com/forum/top ... ent%3A1805) lying around, I tried if I could get some "Arduino"-code running on it. It works.

The linker scripts that ship with mpide assume that the binary is used together with a bootloader, so I provided a new script, which allowed me programming the .hex file using the PICkit3. All necessary files are provided in the attached .zip archive.

* Place the linker script 'chipKIT-MAX32-application-32MX795F512L_nobootldr.ld' into the folder 'mpide-0022-chipkit-win-20110521\hardware\pic32\cores\pic32'

* Place the file 'boards.txt' (which makes use of the new linker script) into the folder 'mpide-0022-chipkit-win-20110521\hardware\pic32'

* Now you can compile the sketch 'Blink.pde' with mpide, import the resulting 'Blink.cpp.hex' in MPLAB and program it using PICkit3 to the target board.

It's nice to be able to use C++ on the PIC32. Finally.

Have fun,
Markus
Attachments
files.zip
(5.52 KiB) Downloaded 389 times
IMG_0453.JPG
User avatar
Markus Gritsch
Sr. Member
Sr. Member
 
Posts: 297
Joined: Tue Feb 09, 2010 6:54 am

Re: Microchip Arduino thing interview questions?

Postby ian » Sun May 29, 2011 5:06 am

@ricklon - Thanks for chatting with me, and thanks for stopping by. I'm really glad Microchip is committing to open source support for some of their devices. You guys have done a great job with the IDE, it's great that it will be merged back into Arduino trunk. Maybe someone will port other open source compilers like MSPGCC and an ARM toolchain.

@arhi - The group working on the chipkit seems really dedicated to making everything for the platform open source, and abiding by the norms of the Arduino community. I hope this will have side benefits like open drivers for PIC USB, ethernet, and CAN. We can also hope that the corporate types will test the waters and loosen the licensing of everything else too. I can dream...

@Markus - nice work! I'll post this up.
User avatar
ian
Crew
Crew
 
Posts: 10803
Joined: Mon Jul 06, 2009 6:14 am

Re: Microchip Arduino thing interview questions?

Postby ian » Sun May 29, 2011 5:12 am

Thanks to everyone who asked questions, and thank you to everyone at Microchip who answered them. I'll post a wrapup and give away the chipKITs on Tuesday (Monday is a US holiday).
User avatar
ian
Crew
Crew
 
Posts: 10803
Joined: Mon Jul 06, 2009 6:14 am

Re: Microchip Arduino thing interview questions?

Postby arhi » Sun May 29, 2011 8:02 am

donno, pickit2 was one of the reasons I have hundreds of pic's on stock, pickit3 is one of the reasons I decided to move to cortex m3. I still make projects with microchip mcu's just to "spend the stock" (and I already sold whole batch of 18f4550 and 18f2550 - had 100 each, some guy purchased them to make some crack for some game console) so now have bunch of different pieces .. and I do not plan to get new ones ... I love the design but I hate the licences .. and as a company I see them degrading - pickit2 was great tool, "real tool for a hobbyist" - it is cheap, it is fully open so you can easily use it for and from ever you want - there's even an avr burner with pickit2 .. then they designed "upgrade" and made it slow and closed with seriously limited functionality ... how to trust them now and invest into this arduino like system (both time and money) if I always have in the back of my head that maybe next version will be slower and closed ?

I can't say for "business" users .. but for me .. I love the microchip mcu's way more then both avr and arm but I really hate the licences
User avatar
arhi
Hero Member
Hero Member
 
Posts: 2160
Joined: Thu Jun 24, 2010 11:41 am
Location: Belgrade, Serbia

Re: Microchip Arduino thing interview questions?

Postby madscifi » Sun May 29, 2011 12:38 pm

I really hope that microchip is committed to open-sourcing the code and I'm willing to give them the benefit of the doubt for the moment, but what they have released is missing some bits. At the moment various ported functions in the Arduino libraries simply point back to Microchip's proprietary library and the source for that is not all present. A simple example is the function interrupts() in wiring.h - it is defined as INTEnableInterrupts() which exists as a declaration in the library header file peripheral/int.h, but the definition is nowhere to be found (at least, I could not find it).

On a somewhat different topic I'm saddened to discover that the code samples included in the PIC32 Family Reference Manual are not to be trusted. I was trying to figure out how to use the output compare functionality and tried out Example 16-6. It is supposed to generate a single pulse using a 32 bit counter and enter the interrupt function after the falling edge. In fact, it fails to set up the hardware for 32 bit operations and uses 16 bit mode instead. Also, it fails to enable the interrupt for the peripheral but sets the interrupt flag instead.
madscifi
Newbie
Newbie
 
Posts: 1
Joined: Sun May 29, 2011 12:00 pm

Re: Microchip Arduino thing interview questions?

Postby Toley » Mon May 30, 2011 7:09 pm

Hi Markus,
I have try your mod for the ChipKit32 IDE. I have a simple question, where can I find the generated hex file ?
Toley
Newbie
Newbie
 
Posts: 16
Joined: Mon Feb 15, 2010 7:12 pm

Re: Microchip Arduino thing interview questions?

Postby Markus Gritsch » Tue May 31, 2011 1:57 am

Hold the shift-key down while clicking on the compile-button, then the output verbosely displays the commands issued. You can see there now the folder in the temp-dir, where the compilation actually happens. Its named 'buildXXXXXXXXXXXXXXX.tmp' where XXXXXXXXXXXXXXX is replaced by some numbers.
User avatar
Markus Gritsch
Sr. Member
Sr. Member
 
Posts: 297
Joined: Tue Feb 09, 2010 6:54 am

Re: Microchip Arduino thing interview questions?

Postby ian » Tue May 31, 2011 1:08 pm

I got a follow up on the compiler questions from the compiler developer:
http://dangerousprototypes.com/2011/05/ ... ompiler-qa

Really interesting stuff there. Maybe a way to port the PIC18/24 compilers without the microchip libraries? I can't tell if this means chipKIT is currently in the same boat as the other Microchip compilers - open GCC but the processor library is still closed source. Has anyone found this (missing) at github?
User avatar
ian
Crew
Crew
 
Posts: 10803
Joined: Mon Jul 06, 2009 6:14 am

PreviousNext

Return to General discussion