Programming EB-006 from Linux

For E-blocks user to discuss using E-blocks and programming for them.

Moderators: Benj, Mods

Post Reply
robquin
Posts: 2
Joined: Wed Jun 10, 2009 10:41 pm

Programming EB-006 from Linux

Post by robquin »

Does anyone have any idea how to program a pic on the EB-006 board using a linux machine?

I have no problem producing a hex file under linux but I have no way of getting it into my pic. I can run PPP using wine but it can't see the EB-006 because there are no drivers for it.

Thanks, Rob

KeithSloan
Posts: 114
Joined: Fri Jul 27, 2007 10:50 am
Been thanked: 1 time

Re: Programming EB-006 from Linux

Post by KeithSloan »

Have you considered Virtual Box? The VirtualBox Personal Use and Evaluation License (PUEL). version supports USB see http://www.virtualbox.org/wiki/Downloads ( Note the open source does NOT ). Does mean you cannot dump Windows entirely but does mean you can use Linux for browsing the Web, email and anything to do with the internet, hence avoiding malware etc.

User avatar
Steve
Matrix Staff
Posts: 3434
Joined: Tue Jan 03, 2006 3:59 pm
Has thanked: 114 times
Been thanked: 422 times

Re: Programming EB-006 from Linux

Post by Steve »

The USB driver we use is Windows-only. Someone on the Microchip forum has created a Linux driver, but we do not have the facilities to test it here. If you are familiar with Linux and how its hardware/driver layer works, then this thread may be useful:
http://www.microchip.com/forums/tm.aspx?m=106426

robquin
Posts: 2
Joined: Wed Jun 10, 2009 10:41 pm

Re: Programming EB-006 from Linux

Post by robquin »

Post by KeithSloan on Mon Jun 29, 2009 9:02 am
Have you considered Virtual Box? The VirtualBox Personal Use and Evaluation License (PUEL). version supports USB see http://www.virtualbox.org/wiki/Downloads ( Note the open source does NOT ). Does mean you cannot dump Windows entirely but does mean you can use Linux for browsing the Web, email and anything to do with the internet, hence avoiding malware etc.
Thanks Keith,

I've been exploring that avenue since I last posted. It took me a lot of fiddling but yes I finally got PPP to see the EB-006 and write to it.
Here are some of the things I discovered on the way (in case it helps anyone following after).

1 The open source licenced version of virtualbox is a non-starter as it doesn't support USB. You need the PUEL version. Keith has already said that but I want to underline the point as I wasted quite a bit of time on it.

2 Virtualbox does not properly support Windows-98 and earlier OSes, so you get a tiny display and NO USB. There is third party software that is supposed to fix this but I didn't explore that route. I bought a copy of Windows-XP to get things working.

3 The old drivers that I used to use with Windows-98 no longer worked in my VirtualBox/Windows-XP setup so I had to update them.

After that everything was setup right and it all worked like a charm but it does seem like a "sledgehammer to crack a nut".
Post by steve on Mon Jun 29, 2009 9:44 am
The USB driver we use is Windows-only. Someone on the Microchip forum has created a Linux driver, but we do not have the facilities to test it here. If you are familiar with Linux and how its hardware/driver layer works, then this thread may be useful:
http://www.microchip.com/forums/tm.aspx?m=106426
Thanks for that Steve. The link you gave is a discussion about porting a linux program (callled fsusb) to Windows. The Linux program is actually at http://www.internetking.org/fsusb/. The program is not a driver but more like a Linux command line version of PPP. I got the program compiled on my system and tried to use it to send the file Count_PortB.hex to the EB-006. It failed to find the EB-006. Not that surprising as it's actually written to write to a PICDEM_FS_USB DEMO board. Here is the console output.

# fsusb Count_PortB.hex
Locating USB Microchip(tm) PICDEM-FS USB(tm) (vendor 0x04d8/product 0x000b)
Fatal error> Could not find USB PICDEM device--
you might try lsusb to see if it's actually there.

When I have more time I may look through the source code and see if it can't be pointed at the EB-006. That's for a later date but I will probably explore further as it seems to be a much more elegant solution than the VirtualBox one, especially if a graphical front end was written for fsusb

Post Reply