This package contains a simple test of tests for various elements of the SmartBoard hardware, which is a simple baseboard designed for easy embedding. It is able to run both a semi-automatic test suite as well as allow interactive testing.

Dependencies:   EthernetNetIf NTPClient_NetServices mbed

This program is most of what you need to test your SmartBoard baseboard hardware. It provides a means to test the following:

  • Two channels of CAN (with a loopback cable)
  • RS-232 Ports
  • Analog inputs
  • PWM outputs
  • Ethernet port
  • Real time clock
  • micro SD
  • USB Host port
Committer:
WiredHome
Date:
Thu Mar 31 11:22:00 2011 +0000
Revision:
4:ca93a8d4874d
Minor revisions to the help text

Who changed what in which revision?

UserRevisionLine numberNew contents of line
WiredHome 4:ca93a8d4874d 1 /* USB Mass Storage device file system
WiredHome 4:ca93a8d4874d 2 * Copyrigh (c) 2010, Igor Skochinsky
WiredHome 4:ca93a8d4874d 3 * based on SDFileStorage
WiredHome 4:ca93a8d4874d 4 * Copyright (c) 2008-2009, sford
WiredHome 4:ca93a8d4874d 5 */
WiredHome 4:ca93a8d4874d 6
WiredHome 4:ca93a8d4874d 7 #ifndef MSCFILESYSTEM_H
WiredHome 4:ca93a8d4874d 8 #define MSCFILESYSTEM_H
WiredHome 4:ca93a8d4874d 9
WiredHome 4:ca93a8d4874d 10 #include "mbed.h"
WiredHome 4:ca93a8d4874d 11 #include "FATFileSystem.h"
WiredHome 4:ca93a8d4874d 12
WiredHome 4:ca93a8d4874d 13 /* Class: MSCFileSystem
WiredHome 4:ca93a8d4874d 14 * Access the filesystem on an attached USB mass storage device (e.g. a memory stick)
WiredHome 4:ca93a8d4874d 15 *
WiredHome 4:ca93a8d4874d 16 * Example:
WiredHome 4:ca93a8d4874d 17 * > MSCFileSystem msc("msc");
WiredHome 4:ca93a8d4874d 18 * >
WiredHome 4:ca93a8d4874d 19 * > int main() {
WiredHome 4:ca93a8d4874d 20 * > FILE *fp = fopen("/msc/myfile.txt", "w");
WiredHome 4:ca93a8d4874d 21 * > fprintf(fp, "Hello World!\n");
WiredHome 4:ca93a8d4874d 22 * > fclose(fp);
WiredHome 4:ca93a8d4874d 23 * > }
WiredHome 4:ca93a8d4874d 24 */
WiredHome 4:ca93a8d4874d 25 class MSCFileSystem : public FATFileSystem {
WiredHome 4:ca93a8d4874d 26 public:
WiredHome 4:ca93a8d4874d 27
WiredHome 4:ca93a8d4874d 28 /* Constructor: MSCFileSystem
WiredHome 4:ca93a8d4874d 29 * Create the File System for accessing a USB mass storage device
WiredHome 4:ca93a8d4874d 30 *
WiredHome 4:ca93a8d4874d 31 * Parameters:
WiredHome 4:ca93a8d4874d 32 * name - The name used to access the filesystem
WiredHome 4:ca93a8d4874d 33 */
WiredHome 4:ca93a8d4874d 34 MSCFileSystem(const char* name);
WiredHome 4:ca93a8d4874d 35 virtual int disk_initialize();
WiredHome 4:ca93a8d4874d 36 virtual int disk_write(const char *buffer, int block_number);
WiredHome 4:ca93a8d4874d 37 virtual int disk_read(char *buffer, int block_number);
WiredHome 4:ca93a8d4874d 38 virtual int disk_status();
WiredHome 4:ca93a8d4874d 39 virtual int disk_sync();
WiredHome 4:ca93a8d4874d 40 virtual int disk_sectors();
WiredHome 4:ca93a8d4874d 41
WiredHome 4:ca93a8d4874d 42 protected:
WiredHome 4:ca93a8d4874d 43
WiredHome 4:ca93a8d4874d 44 int initialise_msc();
WiredHome 4:ca93a8d4874d 45 uint32_t _numBlks;
WiredHome 4:ca93a8d4874d 46 uint32_t _blkSize;
WiredHome 4:ca93a8d4874d 47 };
WiredHome 4:ca93a8d4874d 48
WiredHome 4:ca93a8d4874d 49 #endif