IJFW - IchigoJamのBASICプログラムをメモリカード(MMCまたは互換カード)に保存したり読み出したりできるプログラム。メモリカードにファームウェアのファイルを置くだけで、電源ON時に自動的に書き換える機能も搭載(一応こちらがメイン)。LPC1114FN28専用。

Dependencies:   mbed

Embed: (wiki syntax)

« Back to documentation index

Show/hide line numbers UartIsp.h Source File

UartIsp.h

00001 #ifndef UART_ISP_H
00002 #define UART_ISP_H
00003 
00004 #include "mbed.h"
00005 #include "UartIspBase.h"
00006 #include "FatfsIjfwConfigurable.h"
00007 
00008 class UartIsp : public UartIspBase {
00009 public:
00010     enum ISP_RESULT {
00011         NOERROR,
00012         ERR_FILE_OPEN,
00013         ERR_SYNC_MCU,
00014         ERR_UNLOCK_FLASH,
00015         ERR_FILE_READ,
00016         ERR_WRITE_TO_RAM,
00017         ERR_COPY_TO_FLASH,
00018     };
00019 
00020     UartIsp(RawSerial* _serial, FatfsIjfwConfigurable* _fs);
00021     virtual ~UartIsp();
00022 
00023     virtual void writeSerial(const char val);
00024     virtual char readSerial();
00025     virtual int readable();
00026     virtual void sleep(int msec);
00027 
00028     ISP_RESULT runUartIsp(const char* filename);
00029     
00030 protected:
00031     
00032     RawSerial* serial;
00033     FatfsIjfwConfigurable* fs;
00034     char* buffer;
00035 
00036 };
00037 
00038 #endif