Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Support for PIC32-PINGUINO-MX220
01-03-2012, 08:49 PM,
#1
Support for PIC32-PINGUINO-MX220
The Google code download area is up to date with the latest X.2 version.
This version include support for the new PIC32-PINGUINO-MX220 board.
As usual, feedback is welcomed.....

Jean-Pierre
Reply
02-03-2012, 11:23 AM, (This post was last modified: 02-03-2012, 11:31 AM by regis.)
#2
RE: Support for PIC32-PINGUINO-MX220
http://code.google.com/p/pinguino32/downloads/list

Supported boards are :
8-bit boards with PIC18F2550 or PIC18F4550, PICuno_Equo and FreeJALduino,
32-bit Olimex boards : PIC32_Pinguino, PIC32_Pinguino_OTG, PIC32_Pinguino_Micro, PIC32_Pinguino_220
32-bit EDTP boards : Emperor_460 and Emperor_795
32-bit UBW32 boards : UBW32_460, UBW32_795

(01-03-2012, 08:49 PM)jpmandon Wrote: The Google code download area is up to date with the latest X.2 version.
This version include support for the new PIC32-PINGUINO-MX220 board.
As usual, feedback is welcomed.....

Jean-Pierre

It is easier to complain than it is to do, but it is better to do than it is to complain.
Reply
02-03-2012, 01:41 PM,
#3
RE: Support for PIC32-PINGUINO-MX220
Thanks for your efforts!
As soon as the boards Olimex are giving to us arrive, I'm pretty sure there will be a lot of feedback from some of us Wink
Reply
02-03-2012, 05:54 PM,
#4
RE: Support for PIC32-PINGUINO-MX220
Thank you very much.

I've been searching for a solution to get that board, I received at embedded world, working for two days -.-
Reply
03-04-2012, 03:06 AM, (This post was last modified: 03-04-2012, 03:49 AM by funlw65.)
#5
RE: Support for PIC32-PINGUINO-MX220
(01-03-2012, 08:49 PM)jpmandon Wrote: The Google code download area is up to date with the latest X.2 version.
This version include support for the new PIC32-PINGUINO-MX220 board.
As usual, feedback is welcomed.....

Jean-Pierre

Hi Jean-Pierre and development team!

I tested the Pinguino MX220 board under linux and I have a problem to report, and I found also maybe a better solution to the problem (if there is none).

I tried to upload some test programs using the latest Pinguino IDE (from svn) and was impossible as a regular user. Only as superuser I was able to do it. Tested both openSUSE 12.1 and now Ubuntu 10.10 .

My udev line is:
Code:
# Pinguino32 (PIC32MX)
SUBSYSTEM=="usb", ATTRS{idVendor}=="04d8", ATTRS{idProduct}=="003c", MODE="0666",GROUP="plugdev"
and I am member of plugdev group.

   
As you see, it didn't worked and I know at least a person with the same problem regarding to UBW32 bootloader (he use DM1 and Duinomite Mega boards).

However, I downloaded MPLAB X, mplab C18 for linux (not MPLAB XC8) and also the latest Microchip Application Library archive. Inside archive, at the USB Bootloaders examples, we have a cross-platform PC application for uploading hex files to a HID Bootloader. The application is written in Qt library and using HIDAPI library (not libhid). HIDAPI is under BSD license and as requirement have libusb 1.0 . The application query the USB port at every 1 second, to see if a board is attached/detached.

I compiled the application with Qt Creator (provided by the Ubuntu distro) and launched the application in user mode. It detected instantly the board and was ready to upload some hex files. Of course, I didn't as I don't know if supports PIC32 but the bootloader commands are the same for all PICs. I was able to reset my Pinguino using this application. Maybe is a good start for a proper bootloader?

   

Apart of this, there are many Pinguino examples which don't work with Pinguino MX220 but I guess the support is still under development, so I will not bother yet with that.

Here is the settings window and what it detects querying the bootloader (I guess...)
   
The EEPROM check box is disabled. It may be possible to support also PIC32...
How can I get a .hex file from Pinguino IDE without commenting some lines from python source? I ask because I will take the risk of uploading a test program.
----
Never mind, I found the hex file... I will report asap.
----
Nope! Fail... it seems that the application is not able to deal with PIC32 .hex files. However, is working up to PIC24 and I guess it can be adapted also for PIC32. Anyway, the point is, HIDAPI can work with a HID bootloader in user mode without problems.
   
Reply
03-04-2012, 09:28 AM,
#6
RE: Support for PIC32-PINGUINO-MX220
G'day Vasi and all the Forum Members,
I am the other guy Vasi was talking about and the fun I had trying to get mphidflash to work here on 10.04 LTS was starting to get really frustrating. It wasn't until Vasi said have I tried doing using superuser mode, then I gave it a go first on a Maximite SM1 board then next on the Duniomite Mega board. Also I got an email saying a new hex was out for the DM so I tried it out and found a heap of bugs using 'screen' in the shell and found 'putty' wouldn't even connect. I did try an older versions and got the same so went back to an even older one just to get to display properly.

I am very new to linux but years ago I did have a go and I have decided to ditch win$ucks for good and concentrate on fully learning the shell and from that 'C' will soon follow after I get a few function scripts done. I have downloaded the Pinguino but so far I haven't been able to get it to run but thats for another thread where I can sound it out much better.

In another thread I found on this forum was a member who wanted to port the DM over to the Pinguino and YES I would love to be part of the group on that project.

Regards Bryan
Reply
03-04-2012, 09:46 AM, (This post was last modified: 03-04-2012, 10:07 AM by pingotg.)
#7
RE: Support for PIC32-PINGUINO-MX220
This sounds like 2 separate problems:

1. (Bryan1) needs some settings/permissions/udev rules etc
(if doing it as root works but doesn't work when non-root, then you know it's this kind of thing)

2. (funlw65/vasi) something else - maybe the wrong libusb (*) but maybe something else
another thing to check if on 64-bit Linux: are you using a 32-bit flashing app and if so have you got the right 32-bit libs (.so files) for it (or try statically linking it)

(*) note that 0.1 and 1.0 are incompatible, yes it's stupid but true see their web site

Before doing anything else, it does look like trying it as root is worth trying!

John
Reply
03-04-2012, 12:52 PM, (This post was last modified: 03-04-2012, 12:55 PM by funlw65.)
#8
RE: Support for PIC32-PINGUINO-MX220
(03-04-2012, 09:46 AM)pingotg Wrote: This sounds like 2 separate problems:
...

2. (funlw65/vasi) something else - maybe the wrong libusb (*) but maybe something else
another thing to check if on 64-bit Linux: are you using a 32-bit flashing app and if so have you got the right 32-bit libs (.so files) for it (or try statically linking it)

(*) note that 0.1 and 1.0 are incompatible, yes it's stupid but true see their web site

Before doing anything else, it does look like trying it as root is worth trying!

John

Hi John,

1. - I'm in the 32 bit version of Ubuntu 10.10;

2. - yes, I have libusb 1.0 installed, but also libusb-compat-0.1 compatibility layer (quote: "This is a "wrapper" which converts libusb-0.1 function calls to their 1.0 equivalents."). I believe that this combination of libraries is the best regarding to future. The libusb 1.0 is more stable and actively developed. The "wrapper" cover al libusb 0.1 needs;

3. - it seems to me that libhid (which is based on the older libusb 0.1) allow USB access only in superuser mode. If this is desired, then no problem, but here is another (and better) combination, consisted from libusb-1.0 and HIDAPI (which allow USB access in normal user mode) and I think this must be the path regarding to future versions of Pinguino IDE, considering that Linux distros may be dropping libusb-0.1 for libusb-1.0 .

P.S. I think Pinguino IDE come with his own libusb-0.1 library so, I think it does not matter what I have installed on my system.
Reply
03-04-2012, 01:41 PM, (This post was last modified: 03-04-2012, 01:56 PM by pingotg.)
#9
RE: Support for PIC32-PINGUINO-MX220
I'm very doubtful it's quite like that. libhid is very very unlikely to be checking permissions. Something else may be, or it's seeming like that's the issue when actually it's another one.

Adding permissions checks for root access to that sort of lib.... really isn't likely at all.

hmm, I suppose another possible cause would be the things in & order of PATH, LD_LIBRARY_PATH and so on.

I don't know about that claimed compatibility stuff but it would need the right name unless it's statically linked - which it isn't by default at least for my system or the makefiles I've seen.

edit: had a look at the compat stuff and it has some differences and bugs so be a bit cautious as to whether it works with mphidflash / ubw32 (test, test & test lol)

John
Reply
03-04-2012, 04:03 PM, (This post was last modified: 03-04-2012, 04:03 PM by funlw65.)
#10
RE: Support for PIC32-PINGUINO-MX220
According to this documentation, libhid should work in user space... anyway, libusb-0.1 and libhid are an old pair of libraries and it will be more and more difficult to obtain them for the newer linux distros. But this is not an emergency yet.

I expect that something good will (continue to) come from Microchip as they already have a cross-platform solution for PIC18F-PIC24F HID bootloaders and are committed in providing cross-platform development tools. Then, it will be easy to borrow what is worth...

Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)