Posted by: Claudio Carbone | 9 March 2012

How I loathe the marketing guys

Invensense Press Releases

Invensense Press Releases

Look at the timeline reported above. 20 April 2011 : 9dof sensor fusion presented. 13 September 2011 beginning of high volume production. 27 February 2012 availability of version 5 of the MotionApps software.

Now in reality nothing is true.

They presented a familiy of devices that, with the help of some onboard processing, would have provided sensor fusion.

A little bit of history is required here.

Invensense is a designer and producer of MEMS devices. MEMS devices are all the rage these days because they provide the kind of informations that required sensors as big as a car in the old days in teny-tiny chip packages!
Everyone has heard his smartphone has accelerometer and compass inside: the accelerometer helps detecting the orientation and allowing automatic rotation of the screen, the compass is self-explanatory. Well these devices used to be as big as old laptops!
Now they are about 3×3 mm!

So invensense has been selling gyroscopes and accelerometers for years and you can find its products most everywhere (have a look at Sparkfun ). What’s the fuss? The fuss is that, as with anything, what you do with the information is the key to power.
Accs and Gyros alone don’t give you very much: they are quite noisy, and most of the task we use them for don’t need the kind of information they provide. For example the rotation of the screen of the phone is measured in degrees with respect to the vertical going to the center of the earth. The gyroscope gives measures of the speed of rotation around its axis, while the accelerometer gives measures of accelerations. And we need an orientation. An orientation may be obtained as the sum against time of speeds of rotation: if you know you’re turning 10°/s, after 9s you’ve rotated 90°. It looks simple, doesn’t it?
Well it isn’t!

I’m not delving into this, look for some paper about IMUs or Attitude estimation, suffice it to say you have to do some heavy processing on the raw data to obtain useful information.

Since this is heavy processing (often involving filtering data and matrix products) it is resource intensive, and it has historically been bread&butter with the DSP world.
Now having a single chip that does the work of: gyro, accelerometer AND dsp… WONDERFULL!!!
Anybody could go, buy it, solder it and BAM! Motion processing on the cheap!

Well that was the promise of Invensense.

Now the true facts.

Theirchips available so far are: the MPU6000 and MPU6050. On paper the only difference is that the 6050 is I2C and the 6000 is SPI. You’d go SPI anytime as it is much faster. Wait until you read that the software platform from Invensense doesn’t support the 6000!
Don’t know what the difference is: it’s just a bus, but they don’t support it!

Next what you’ve been reading on all the press releases is that they support 9DOF fusion.
If you ever get far in reading docs, you’ll never find any hint at how exactly this is done.
Then you may buy an eval board, and find there is an external compass (an AK8975).
Then you may try downloading some code from the Developers Corner… good luck with that!

The code itself is a mistery: there are two zips, one is for the TI430 MotionFit wireless sdk (based on the new 9150) and has the library PRECOMPILED. So no joy. The other is for the AVR UC3 and has lots and lots of source (and this already gives hints on how transparent they are). Now if you try to compile this code, you’ll notice a few files missing:

  • AK8975.h
  • compass_debug.h
  • compass_legacy.h

The first has been bugging the community for almost a year now. If you ask Invensense, they tell you to go ask AK. If you ask AK they tell you to go ask Invensense. So no compass headers. The other two I just found missing in the package, haven’t much to say about them.
Now all of this is Version 2. They just published a PR of Version 5! We don’t have nothing more than a cumbersome V2! Where are V3, V4 and V5?????
If you ask in their forum, they tell you it’s there in the Downloads section. Except that all you can find is those two zips I described.

Now onto real matters: thanks to people who got their hands dirty and literally sniffed the I2C traffic we have some data to work on, otherwise we would have none! Invensense refuses to explain how to use their chip. They tell you to go download the software, but there is almost no software! The two packages are for two extremely customized platforms, there is no general purpose library.

If you ask them how to do the fusion, they won’t answer.
If you ask them how to interface to the data processing core, they won’t answer.
If you ask about the new software versions, they won’t answer.

There is a reality wispered among the community: they never actually did it.
That’s why the released in rapid succession: MPU6000, MPU6050, MPU9150.
At this point the 6000 is useless, it’s not even supported by the community. The 6050 may be usefull, but they are not disclosing enough information and all relays on hackers. The 9150 is the 6150 with the AK inside and MAY BE ABLE to do what it promises.
At least people who got ahold of the demo board, say it really does the 9DOF fusion, albeit how did they test it is a mistery.

I leave you with a capture of a discussion from the Invensense forum. Sectionsbest appears to be a moderator (a forum without explicit moderator labeling?) or otherwise a man from Invensense.

Invensense Forum Capture

Invensense Forum Capture

Posted by: Claudio Carbone | 21 February 2012

I2C Followup – Microchip’s errata

I2C Display

I2C Display

After much much (much!!!) fiddling I finally have the I2C module working.

How did you solve the problems?

Nice question. Short version: I didn’t.
In fact I still have tickets open with microchip about the I2C modules on the 440F128H: I haven’t been able to get any of  them to work.
It could be fault in my code. True, but a fellow on the microchip forums volunteered to share his code.
It does not work at all.
It could be a hardware fault. True but I have multiple instances of the same board: some with the 440F128H and some with the 695F512H.
The 695 work without any problem, I even tested I2C ports 3 and 5 (and in the process discovered a nice errata that’s still uncorrected: every port from 3 through 5 MAY NOT correctly determine the bus status when the module is first powered on. In my case this means that port 5 needs an external physical cycling of the I2C pins, while port 3 works like a charm) and they work without a problem.

No chance of getting ANY port to work on the 440.
Well this means I’m not going to use that chip in any future project.

Anyway the errata on the PIC32 family looks awful to say the least.
After three revisions they did not correct any issue!
The I2C means you can’t use those ports as a master without resolving to spend a GPIO pin to cycle the I2C bus. If you’re the slave… well good luck: either you derogate to the bus rules and power cycle the lines, or you have to modify any other master’s code to do it for you. Or loose the first message every time you power up.
But go have a look at the SPI errata too, it’s simply incredible that after three revisions the most powerful chips of a manufacturer are still affected by such problems as

  • SPI Slave Mode. A wake-up interrupt may not be clearable.
  • DMA CRC Append Mode. In Pattern Match mode, the DMA module may not append all of the CRC results to the result buffer.
  • I2C™ . The SDA line state may not be detected correctly.
  • SPI. Byte writes to the SPISTAT register are not decoded correctly.

This is just a short list, I reported what to me seems something that deserved to be correct after 3 hardware iterations.
All the more because in 3 iterations the only thing that changed is the I2C problem reported above (corrected in the 3rd iteration).

Well I’m not a silicon engineer, but I can’t but remain puzzled by this.
Let’s see what comes out of the other problem with the I2C.

Posted by: Claudio Carbone | 13 February 2012

Fighting the Compiler (MPLAB C32)

Luckily I have some relaxing newage music going on (Mono Lake from Rick Wakeman)…
Otherwise you may hear CNN talk about a sudden explosion in Rome.

Since I began working on my first big project (all the more big because I’m working solo) I learned a few things, and had to put others to use.
So I have this complex program running on a PIC32, sampling sensors, keeping the battery in check, writing to SD, and enabling SD access via MSD (Mass Storage Device class) when connected via USB.
Debugging this is sometimes cumbersome as I don’t have a serial terminal, and hooking one up is a bit of an hassle as the thing already has an UART used for the GPS.

Why not use an LCD to output relevant debug messages?

Nice idea, but my mind wasn’t done yet:

Why going parallel, it’s a mess! Let’s go serial.

There started my I2C epopea.

128x64 Serial I2C Lcd

128x64 Serial I2C Lcd

So I2C is not that much complicated you see, it’s a serial bus essentially but with a medium access control and collision detection system, allowing multi-master and multi-slave configurations (contrary to RS232 and derivatives which only allow a single master and a single slave in hardware).
There are lots of tutorials out there, go pick one on google if you’re so inclined

Since operating the I2C requires a bunch of MAC operations (start, stop, restart, collision, ack, nack, and so on), you’d expect and advanced micro had a decent peripheral able to do that.
I expected the same, only to get a big delusion when I read this passage on the I2C manual

DS61116D-page 24-33
The I2C module does not allow queueing of events

What does this mean?
It means there is no provision in the so-called Peripheral to help the programmer achieve what he wants: communicate with a device over I2C.
Everything MUST be accomplished by the programmer: he has to check the status of the bus, the ack and nack of bytes both while sending and while receiving, he has to take into account the time needed by each operation…
Either you go polling or you go interrupt-driven, you have to do it all by yourself.
How can they even call a bunch of macros a “Library” ???

So after this shot in the heart, that meant a lot of work more than already anticipated, came the real deluge: nothing worked.
Nothing at all.
No macro worked, not even the one that should turn on the module!

What this means is: low-level register coding remains the only way.
So thanks to my new printer I proceeded to print the entire I2C manual (two faces per page just to save some tree branches) and started working on writing my bare-metal code, flipping switches here and there (metaphorically but also quite materialistically as SFR bits are in essence just switches).

And what came out was a first attempt at a library that was also supposed to work but… incurred in a nice undocumented feature (from now on known as DARN BASTARD BUG): a simple jump instruction (the end of a while loop) had some mutations and transformed into an evil Reserved Instruction triggering a General Exception, but only if a start condition was issued on the I2C module!

If the Start was not issued, the while did work just as it was supposed to.

This has been driving me mad for 2 days now: not only the fact that a so called Library is in essence just a collection of configuration macros and than a useless piece of code, but the fact that I could not find any decent way of getting that darn I2C module to work as it is supposed to.

This resulted in 3 tickets (for now) filed with Microchip support.
I hope to see the light of day sometime soon…

Posted by: Claudio Carbone | 13 February 2012

A (for real this time) good deal!

Ok after the bad experience of the low cost oscilloscope, I think I have to share the symmetrical experience with my new printer.

After years with an HP inkjet MFC 4180C I decided that a REAL printer was needed.

I got a Brother 7460DN.

Brother 7460DN MFC

Brother 7460DN MFC

Cost: 200€ shipped.
It’s a nice laser MFC.
I chosed it almost exclusively for two features: ethernet and automatic full-duplex.

My father and I in fact already sharea printer (the inkjet mfc), and I was really sick of having to go to some copying shop to get even 5 pages. The InkJet was not only slow, it didn’t have duplex, and it costed the hell to print!
Really: at 35~40€ per ink cartdrige printing was on the hideously costly side, all the more because I never got it to print correctly without the color cartdrige! When colors were zip or thereabout, you’d see any page, even a stupid Word text, being printed in cyan or magenta or something complitely different from the black you were expecting.
And then I also had to run an always-on server just to share the darn thing on the network (it was just a usb printer).
Since I also have a NAS doing most of the work for my network, the server was pretty much useless.

So I went hunting, looking for the right set of features without going insane.

When the 7460 arrived the first thing I noticed is the amount of software it wanted to install, and I was a little critic about this.
I’m always for the less intrusive pieces of technology (love the “portableapps” kind of things!).

And indeed it would work with standard PS drivers I suspect but those hefty drivers have a very nice feature:

you can associate your computer with the printer so that any time you are at the printer side and scan a document/image, you can choose the computer on which to upload the file directly from the printer control panel! No more shuffling back and forth from printer to pc. On my father’s WinXP rig it’s seamless: you just press the “Scan” button and the file appears in the documents folder.
On Win7, as usual with all the complexitites of that OS which I love nevertheless, it asks you for an action to take.
Just like when inserting a pendrive or cd.
You can anyway assign a default action, and it will just do that.
This is one of the most brilliant features I’ve seen on a printer: no funky special apps, just press a button and the drivers do the rest!

A nice touch is also the fax system: nothing’s emulated, this MFC has a real fax.
It can work with PABX, answering machines, and your pc. It can store faxes to later forward to the pc when it comes online, or just print them out. It can be configured to wait a number of rings in case the line is shared with a telephone, or wait for a tone code to trigger the receiving. And it can obviously send and receive from pc.

You can also manage most of its features from a browser, not the most advanced interface, but it manages to get things done.

And there is even more!
I bought it during a promotion!
For 200€ I got the MFC and a USB Label Printer!

Brother Label Printer QL500

Brother Label Printer QL500

I still have to try it, but it’s an 80€ gift nontheless! Nothing to be ashemed of, don’t you think?
Sure I’m no label man, but since it’s free… Who’s going to complain?

This one’s been one of my best deals, since my still pumping Creative Audigy 2 ZS.
That one deserves a post of its own: it has something like 10 years, and it’s still a wonderfull 7.1 soundcard, driving my Creative 5.1 speakers on my gaming pc. And I payed about 130000ITL for it! 67.14€… other times😛

Posted by: Claudio Carbone | 12 February 2012

“The more you spend, the best you spend”

This post’s title would like to be the translation of an italian motto.

Explained in more detail, the phrase “Chi più spende meglio spende” means that when you are looking for something, paying more is much better than paying less.

That’s not always true, but it is with regards to the recent Owon PDS5022s Impressions post.
I went searching for an oscilloscope at the best price I could find.

I found it but what did I get?
Let me remember the missing features first:

  • FFT
  • Trigger menu incomplete
  • measurements available (only 5 agains the advertised 20+ of more recent versions)

The FFT is just a gimmick in many cases, but may as well give you a simple idea of the frequencies involved in a signal. Can never substitute a Spectrum Analyzer though, and that’s why the SA prices are heavenly!
The trigger menu is a much more serious thing: without access to the holdoff, pre-triggering, etc you are really left with just a basic triggering system. Can’t go searching for spikes, hiccups, or anything else that involves more than a comparator.
The measurements really tell the story about the kind of people who produced this thing. The Tek 3012 I have at work is late 90s technology. Still it has 21 automatic measurements.
To this you should add:

  • the abysmal memory depth (2K I think)
  • the abysmal screen refresh rate (in the range of 1~2 Hz!)
  • the iffy triggering (auto wouldn’t catch things most of the times! needed manual…)
  • the noise on the signals
  • lack of firmware upgrade capability

If you want a more in-depth review of an even far superior model which is still affected by some of these problems (check out the refresh rate in part3), check out this video on youtube (part2 and part3 are accessible from there).

An official reseller here asked me 320€ for a new 5022.
This SDS7102 goes for about 450€.
Now a Tek 1001 (which is very basic) is about 1000€.
Sure Tek adds a lot for its name, but sure enough Chinese manufacturers work on the cheap.
So there MUST be a difference for that price don’t you think?

Having worked for years with a Tek 3012 I can tell you there is: A LOT!
There are so many things in an oscilloscope, all the more when it’s a digital one.

As marmad22 himself said (the author of the video above) I’m going to save money to spend on a much more decent product.
China instruments are 6-feet-under for me from now on.

Posted by: Claudio Carbone | 10 February 2012

New stuff: Owon PDS 5022S impressions

My new oscilloscope

Being payed for your work is very satisfying, isn’t it?
Some of the satisfaction is obviously indulging in the most convoluted ways to dump the recently acquired money.
For geeks and techies like me, the market offers an incredible amount of ways to literally obliterate money!

Thought that Gucci bag was crazy at 1200€? Think again!

A new Tektronix base oscilloscope (models 100x) goes for about 900€. At work I usually have a Tek 3012 under my hands, do you know how much one of these goes for? It’s a 1998 piece of technology, and it still sells for more then 1300$ used! The TDS 3012C has a retail price of 4999$! WOOT!

No wonder China is placing a firm foot in low cost instrumentation too: an Owon 6022 60MHz retails for about 500$, this morning I watched one go on ebay for 216€ (used).

But anyway, I’ve been payed for some engineering I did and that’s fine, but wasting money is stupid no matter how much you earn.
At least this is my phylosophy, so I went hunting on ebay and snatched the above depicted China made Owon 5022 for 176€!

176 Euro!

You can see it’s not a Tek from the moment you turn it on: the screen response is sluggish, full of ghosting, the measurements available are too few (just Freq, Period, Cycle RMS, Mean and Peak-to-Peak… go have a look at what the Teks do…)…
Actually I think this is some bad unit: the manual tells a different story about measurements available.
I discovered it’s also missing FFT from the MATH menu and Holdoff setup from the TRIGGER menu.
UPDATE An email is on its way to Owon as well as another to the seller, this doesn’t look like a good unit to me.

Owon LCD vs USB comparison

Owon LCD vs USB comparison

As the caption of the above image clearly states, in this image you can look at the real thing and at the software running on my laptop visualizing the very same data.
This actually is a really nicely made piece of (Chinese) software: instead of visualizing a bmp or jpg or anyway a copy of the frame buffer of the instrument (like some Tektronix do over ethernet), this downloads the data stored in the O’scope memory and then redraws that data using the resolution of your laptop. So it scales much much better than a 640×480 bmp!
It also allows you to move traces around, albeit apparently only vertically: I haven’t been able to move anything horizontally, there isn’t even a slider! The darn thing allows you to zoom in and out, but it’s all useless as you can’t pan horizontally…
Now the thing has all the data stored, you can even change the time slicing and this would in turn put more or less of the data in view, but panning is out of question… heck I don’t get how one could forget such a feature!

So to sum it up a bit, I didn’t expect fireworks from a 200€ piece of tech, and I’d be very satisfied with my prize if it weren’t for the advertised but missing features. I hope Owon will chime in to let me know what happened to this particular O’scope.

More in-depth analysis of the performance would require more complex signals that I’m unable to generate here at home.
Let the 100KHz I2C signal suffice for the time being.



by reading here and there I discovered there are at least two firmware versions around for this scope, 5.3 and 6.2 or something like that. The latter is the one with FFT. Interestingly some users on the DSLreports forum noted how OWON UK is totally oblivious of this, asserting the 5022 doesn’t have any FFT capability that is exclusive of the 6062 model and above. Videos on youtube are there to testimony the contrary. I’ve sent that email, and also contacted a local reseller of Owon, we’ll see what comes out.

Posted by: Claudio Carbone | 22 January 2012


Long time since last time.
I wish it were for publicing some nifty new toy, or script, or whatever.
Sadly I feel the need to publicly share a disappointing event in the Italian history.

At this link you can read the machine-translation of an article appeared in the online version of the second italian newspaper “La Repubblica”.

The article describes how the Digos (a branch of the national Police force) had some demonstrators of the Socialist party HIDE THE NATIONAL FLAG for public order reasons.
You see those pacific Socialists unrolled a 20m long Italian flag on purpose to counter-demonstrate against marching Lega party members.
This party (the Lega party) is a secessionist movement, often asking for more money and rights to be moved to the northern regions.
This party was the main supporter besides Berlusconi’s own movement of the last Berlusconi’s government.
Its leader, Umberto Bossi, has been nominated Minister of Federal Reforms without even a first level degree in anything.
In fact this man leads one of the most influent italian parties without being able to give a decent speech (and I’m not referring to his recent medical status), and without adeguate capabilities I may add.
Still people votes for him and his movement, follow him, and force the Italian Police to have the Italian flag hidden for fear of riots.

So instead of punishing those who insult national symbols (like mr Bossi almost weekly does), this country prefers to hide those symbols for the sake of peace.

I think this clears a bit why Italians are Italians to all those buffled foreigners.

Never heard of USA police having the flag lowered…

Posted by: Claudio Carbone | 31 October 2011

Put a PIC32 to sleep part2: auto-wake on timed alarm.

Hi Folks!

I’ve been toying around with my little PIC32 and had thoughts about expanding the functionalities.
Since we (now) know how to put the MCU to sleep and how to get out of it, why not teach ourselves how to have it wake up itself at a predetermined time?

Sounds like an alarm!
And yes it is!

So this new demo is just an expansion of the previous: it exploits the RTCC module to have the PIC32 wake up by itself.
The old functionality is still there: you can put it to sleep and bring it online by pressing the button.
But if you don’t wake it up, it will wake itself after 19 seconds.
This number is clearly seen at line 344 of main.c.
Also keep in mind that the number are coded in BCD, so they MUST be fed in hexadecimal.
I’ve been puzzeled for a minute when after asking for a 19 seconds alarm, I got a 13 seconds one!
Then I remembered the BCD thing, and sure enough 19 in dec is 13 in hex.
So keep this in mind.

Not much else to say here, it’s pretty easy really.

Give it a try and let me know.

Last notes (i was forgetting):

a) as before it is configured to run on my Tiertex board, be sure to configure the LEDs and button for your board, and the project for your specific model (mine is a 440F128H).

b) there is a “configureUSB” function in there, this is just to put the USB module to sleep. The module is not used in this project, but another user on the MCHP forum discovered that it doesn’t automatically go to sleep, you have to manually shut it down. The risk is that your MCU will effectively sleep, but will drain 5~10x the power it should while sleeping.
For more details check here.



oooopsssss, forgot the link!
Download the demo

Posted by: Claudio Carbone | 10 October 2011

Put a PIC32 to sleep

I’m working with these 32bit microcontrollers which are relatively new (Microchip started producing them around 2008), at least to me.
I’m fighting to gain as much knowledge as possible but they are so vast an architectural leap from 16 and 18 series MCUs, that the involved work is huge.
I’m studying them from multiple sides at once, which is difficult, but often there isn’t time to prepare a learning guide, lay out a path and follow it. Most times you’re forced to try shortcuts (not all of which are really so) and see what the outcome is.
In this process I fighted with the documentation (something Microchip seems to have banded: pic32 documentation plainly sucks), I fighted with the forums (they also seem to have dropped official support from the forums, mods are nowhere to be seen and users are left at themselves), I fighted with the hardware.

So I figured: why not sharing some of my newly acquired knowledge?

So here it is just one bit: how to put the cpu to sleep using the Change Notification module.

This module is a peripheral that can always run (even during sleep with primary oscillator disabled), it’s purpose is to notify (by interrupt) of changes on specific input pins. The pins that can work with these module are labeled CNnumber on the datasheets, so not any pin can be used for this purpose.
The board I’m using is an inexpensive SD demo board made by Tiertex, with three leds, a button, dual oscillator (primary and secondary for RTC) and microSD slot.

My demo uses two timers (the Core timer and Timer1) to blink two leds at two different rates.
The button is used to switch the Timer1 on and off, thus disabling one of the two blinking leds.
In order to put the MCU to sleep the two lines gotosleep= in the CN interrupt handler need be uncommented.
I suggest you run the demo and ensures everything is working (button correctly detected, timers halting and resuming).
Once everything is ok, you can uncomment the sleep lines.

The sleep command MUST be outside the issuing ISR.
In fact the actual sleep command, PowerSaveSleep(), is somewhere else.
That’s because the CN ISR is the same function that is called when entering as well as when exiting the sleep.
Since during sleep the mcu halts at the exact same instruction that puts it to sleep, if you put the sleep command in the ISR then the following ISR call, which should wake the cpu, would not be served because the code was halted inside the previous ISR.

Also keep in mind that the execution resumes at the exact same point it was halted.
So if you entered sleep by CN and plan to resume, for example, by RTC, when the RTC raises the IRQ the code would continue to execute the part of the CN ISR that remained after the sleep instruction, only after that the CPU would look for the RTC interrupt.

Hope this was clear and useful.

Here is the link -> Source Code

Posted by: Claudio Carbone | 3 October 2011

A little (huge) detour

Some random news.

  1. Microchip has opened up a new site: Embedded Code Source

    A site that inherits the best of intentions: aggregate all interesting free source code for any particular task you can put a Microcontroller at.
    The press release cites third party companies currently working with Microchip as possible contributors, but as of now the only giver is Microchip itself. Albeit with a decent number of examples. Currently it’s limited almost only to Pic24 and dsPic, with rare occurrences of Pic18. Let’s give ’em time and see what they come up with.
    Site link

  2. I’ve started working with: FreeRTOS

    And what is it? RTOS stands for Real Time Operating System, which is an OS designed to adhere to strict time constraints. Contrary to modern OSes (all of them, including every Windows and every Unix derivative) that live to simplify the life of the user, helping him with user interfaces and time-limited tasks, RTOS where born for the control industry, in which timings are of paramount importance. Abused examples are plants security control systems (imagine the temperature of the core of a nuclear plant): you have to react to incoming data in a certain time, data itself must be sampled at defined times and rates. You can’t delay a temperature sampling because the processor is occupied serving a webpage.
    In this peculiar scenarios the RTOS has flourished arriving today to the point that free complete RTOSes are available, like the aforementioned FreeRTOS.

    Thanks to Joao Melo and his blog (available here) I was able to have a simple implementation running in no time at all.
    It’s thrilling to create tasks, delay them, suspend them, resume them, have the scheduler preempt them, all in real time in a teeny-tiny fingernail sized package.
    It’s almost as if a complete cpu from years ago has shrunk to a centimeter in size, maintainig all its processing power, but losing all the heat dissipation. It’s amazing!

    So now I’m at the point that I have the scheduler working nicely, simple-stupid task (think the “blink the led” type) are interrupted and resumed at the touch of a button (also the button is sampled by another concurrent task). And since the console output of the debugger is routed through the Microchip IDE, it’s painfully slow. So I had the brilliant idea of trying to port the Microchip’s USB Stack to FreeRTOS.
    Since I was sorely missing a decent UART link, I started with the CDC mode (in this mode the USB device is seen as an emulated serial terminal, you connect to it via any HyperTerminal) and after some days of hard work I can say it works.
    I have gone up to 60 Kcps which is equivalent to 60KB/s. Which is not bad considering it’s an hack of mine!
    I’ll see what I can do with other USB modes (Mass storage is next on the list).

    Right now I’m really satisfied with this free OS, it’s really powerfull and yet simple.
    Give it a try if you have one of the supported platforms.

  3. I finally found the code for this wonderfull demo: Multiple Stacks on a single MCU

    I’ve been amazed by this demo since I saw it, and I’ve been hunting the code everywhere. Finally I found it in a largely forgotten site (why did they abandon it?):
    Unfortunately it does not compile for some ASM error I can’t understand. But having the RTOS code and all the Microchip stacks already in Threaded form is something I wouldn’t have ever hoped, so… I’ll use it to get the stacks to work in the RTOS and see what I can do with them.

I’ll have some more updates  in the coming days.

Embedded FTW!

Older Posts »