Cosm.com aka Pachube

Connect your Arduino Ethernet to the Pachube API to display and log data on the web.

Favorited Favorite 0

ATTENTION: Due to a complaint about a trademark infringement, we were asked to change all instances of Cosm to Pachube. Cosm and Cosm.com are separate entities, one is a US trademark and one is a domain name. While we don't want to confuse you all, which I am sure we have already, we want everyone to be happy. I'm not sure it is fair to Cosm.com that we use Pachube, but at the same time, we don't want to resolve this through litigation. Basically, we can't use the word 'Cosm' even-though, we are referencing Cosm.com. Clear as mud? 

About a month ago, I was moving my Geiger Counter feed over to the new Arduino Ethernet board. I previously had this setup connected to a computer running Processing, and sending data like CPM and uSv/hour to a free datalogging website called Pachube, for well over a year. The data I was feeding from the Geiger Counter was graphically displayed on a dedicated URL or embedded into a website elsewhere. 

Here is the live Geiger Counter feed embedded into this post using Pachube's 'Graph Builder' function.

Displaying CPM for the last few months, updated every minute. 

Here is how I got the feed above to work: 

Sign-up with Pachube. It's free, but you have to register.

Now start a new feed, there should be a button on your console screen:

The current beta release of Pachube will now give you options to select things, like Arduino, Twitter, etc.

Select Arduino, create a name and tags for your project, then looky here! 

They give you a nice Arduino .ino file pre-loaded with all of the relevant info, like your feed ID and API keys. You basically get your own graphical datalogging webpage with a nice shinny pair of keys pre-loaded for your Arduino. 

The only things you need to change are these two line of code:

    // assign a MAC address for the ethernet controller.
// Newer Ethernet shields have a MAC address printed on a sticker on the shield
// fill in your address here:
byte mac[] = { 0x90, 0xA2, 0xDA, 0x0D, 0x74, 0x06};

// fill in an available IP address on your network here,
// for manual configuration:
IPAddress ip(192,168,20,254);

The MAC address should be on your Ardiuno Ethernet board and you also need to find an available IP on your network. To find an available IP (in Windows), open a command prompt and type 'ipconfig'. You should see the IP address of the computer you are using. I choose that number, but replaced the last digits with '254'.  Then type 'ping your_new_ip_address' (e.g. 'ping 192.168.20.254') and if you don't get any response from the ping test, then the IP address should be open to use. 

The example sketch Pachube gives you is for an analog sensor, but it isn't difficult to integrate the code into your own datastream, by inserting your own byte of data into the 'thisData' variable in this line of code (from the example .ino file).

        // here's the actual content of the PUT request:
    client.print("sensor1,");
    client.println(thisData);

You can also tag different datastreams in your code (sensor1, sensor2, etc) to display different types of data.

The web interface to build your graph is very easy. You can change things like pixel size, labels, units, etc. 

If you want to see the Arduino code for my Geiger Counter feed it can be found here. I hope you all can start some feeds of your own and share them with the world! Have fun!


Comments 13 comments

  • RocketGuy / about 12 years ago / 2

    Great Article, just one thing though, as a professional network dude: Don't just grab an IP address if you're on an administered network. (if it's your network, of course, go to town). But if you're on a large managed network with network folks involved you want to inform/ask for an IP, if they are assigned. Otherwise you get conflicts down the road, big waste of time.

    But anyway, this is great stuff, look forward to trying it out!

  • nanogear / about 12 years ago / 2

    Thank you!!! Great service from Cosm.

  • ATTENTION: Due to a complaint about a trademark infringement, we were asked to change all instances of 'Cosm' to 'Pachube'. Cosm and Cosm.com are separate entities, one is a US trademark and one is a domain name and both are software based companies. While we don't want to confuse you all, which I am sure we have already, we want everyone to be happy. Although, I'm not sure it is fair to Cosm.com that we are using Pachube, but at the same time, we don't want to resolve this through litigation. Basically, according to this Cosm (which is the one that asked us to change the name), we can't use the word 'Cosm' eventhough, the service I am talking about is hosted at Cosm.com. What. Any lawyers in the house have any input on this, free of charge?

    • Kamiquasi / about 12 years ago / 1

      tl;ra (too long, read anyway): There's a company called Mithral that used Cosm as a trademark for particular services for a long time but never bothered to set up a cosm.com or cosm.net .

      The company behind Pachube (since acquired by logmein) acquired cosm.com and cosm.net from third parties that together preferred $55,000 over hanging on to those domains. Pachube-turned-Cosm then tried to apply for the Cosm trademark, but was rejected, because Mithral already had it and Pachube-turned-Cosm and Mithral offered services that were too similar for the trademark office's liking.

      Mithral got wise to the act and decided that they'd rather like to have cosm.com and cosm.net .

      To do so, they would have to prove 3 points; 1. That cosm.com and cosm.net are confusing with respect to the trademark 'cosm' - proven. 2. That Pachube-turned-cosm has no rights or legitimate interests in the domain names - also proven. 3. That the domain names were registered for the purpose of, or currently used, in bad faith - not proven.

      Because not all 3 were proven, Mithral didn't get the domain names.

      Now, this domain name dispute is basically almost entirely separate from the decision that this article alludes to. The decision seems to be based entirely on a request (formal or informal) from Mithral that SparkFun refrain from using the Cosm trademark when actually referring to Pachube-turned-cosm. Perhaps Mithral referenced the domain name decision to point out the trademark dispute and the finding on that matter to give their request some additional weight.

      Personally - and I'm certainly not a trademark lawyer - it sounds a lot like Pachube messed up when they decided to try and go for Cosm and committed to that with domain names, advertising (not sure why, but every 4 tech webpages I visit seem to have a 'Pachube is now known as Cosm' ad), etc. Or maybe it's a strategy.

      Either way, SparkFun in turn decided that rather than get inbetween the two parties, they'd just change the Cosm references to Pachube and be done with it. Which sounds like a perfectly rational response to this mess :)

      • The decision seems to be based entirely on a request (formal or informal) from Mithral that SparkFun refrain from using the Cosm trademark when actually referring to Pachube-turned-cosm

        Correct. I received an informal complaint from Cosm (not cosm.com) and was asked to change the name.

        Now, this domain name dispute is basically almost entirely separate from the decision that this article alludes to.

        My main concern is to limit the confusion to the end user (so is enforcing a trademark right?). The domain name dispute is very important and creates a ton of confusion. One entity can use the word cosm.com and one entity can use the word cosm. What!? This makes no sense to me and google isn't going to tell the difference. The obvious solution is to refer to cosm.com when referencing the website cosm.com. Right? I suggested this, but it wasn't sufficient with Cosm. Why? Google rankings? Probably. Would SparkFun be held liable for using the word Cosm.com or even Cosm when we blatantly are referring to Cosm.com? I don't think so. How could we..when cosm.com is still legally operating under that name.

        The entire situation is convoluted and more so is the motivation of Cosm (not cosm.com) to go after SparkFun after loosing a domain name dispute only weeks ago. Seems too coincidental to me.

        I want to be fair to both parties (Cosm and Cosm.com). The fact the Cosm wants us to use the name Pachube isn't fair to Cosm.com, IMHO. So, I'm really confused as to why a US trademark can be enforced for the name cosm, yet the domain name dispute has been settled using the name cosm.com. It seems both can't exist without a bunch of confusion, which is the whole point of IP enforcement, yet cosm.com is still operating and cosm is enforcing its trademark.

        I'm not trying to argue, I am just really confused.

        • pt / about 12 years ago / 1

          heya! mithral sent adafruit basically the same note last month - we had our lawyer look at it and we did not need to remove our blog posts/tutorials. i sent an email to nate today when i saw this, check in with him. i also cc'ed the cosm team, adam from mithral and all the lawyers folks. i asked that cosm and mithral resolve this with each other directly.

          • Hey there! Thanks for the info!

            i asked that cosm and mithral resolve this with each other directly.

            That seems to make the most sense.

  • Cafetinagem / about 12 years ago / 1

    It's easier then before!!!

  • afulki / about 12 years ago / 1

    The Ruby code examples are a bit misleading, using different versions etc. after poking around a bit, I got code working to send data to COSM from a Ruby script (also shows how to connect to grab data if that's your thing) http://afulki.net/2012/09/cosm/

  • Sparkfun you spoil me with great posts!

  • ME heat o nator / about 12 years ago / 1

    I think you just read my mind. Do you sell a sensor that can do that? If so, will you post a tutorial on how to set it up. I want to read minds and log thoughts. Thanks.

Related Posts

Recent Posts

Why L-Band?

Tags


All Tags