RE: [TINI]SLush and File Writing
Lorne Smith <Lorne.Smith-6tN4nzCoH/[email protected]>
| Newsgroups | gmane.comp.hardware.microcontrollers.tini |
|---|---|
| Message-ID | <[email protected]> |
You probably do not have write permissions to the root directory of the file system. The main slush thread runs with guest privileges. You can change this by adding the following line to the end of the slush constructor: userIDByThreadID.put(Thread.currentThread(), new Byte((byte)adminUID)); --Lorne > -----Original Message----- > From: tini-admin-6tN4nzCoH/[email protected] > [mailto:tini-admin-6tN4nzCoH/[email protected]]On Behalf Of [email protected] > Sent: Tuesday, April 13, 2004 4:09 AM > To: shawn silverman; swami venkataramani > Cc: tini discussion forum > Subject: [TINI][TINI]SLush and File Writing > > > Dear Shawn > > code: > //-------------------------------------------------- > FileOutputStream ffout; > try > { > ffout= new FileOutputStream("datafile"); > ffout.write((new String("12345\r\n")).getBytes()); > ffout.write((new String("67890\r\n")).getBytes()); > ffOut.flush(); > ffout.close(); > }catch(IOException e) > { > } > //--------------------------------- > in myApp. > > If only myApp in flash,“datafile” can found in SRAM. > If new slush(=myApp+slush) in flash,“datafile” cannot found in SRAM? > but other funtions in myApp in newSlush work good! > why? > > //------------------ > about new slush: > In com.dalsemi.slush.java, I make Changes: > import MyPackage.MyApp; > … > public static void main(String[] args) > { > new Slush(); > new MyApp(); > } > > //------------------------- > > Best regards, > zhbnzz > > > ======================================================== > “掀起你的盖头来,AOC新妆靓丽健康秀”! > http://design.163.com/aocmonitor/index.html > > 是邮件你收 有病毒我上!VIP邮箱 全面保护! http://vip.163.com > > 中国最大的免费邮箱在等你 25兆空间4兆附件! http://mail.163.com > > 点击网易泡泡惊喜无限 全免费手机短信任你发! http://popo.163.com > _______________________________________________ > TINI mailing list > TINI-6tN4nzCoH/[email protected] > To UNSUBSCRIBE, edit your profile, or see list archives: > http://lists.dalsemi.com/mailman/listinfo/tini > _______________________________________________ TINI mailing list TINI-6tN4nzCoH/[email protected] To UNSUBSCRIBE, edit your profile, or see list archives: http://lists.dalsemi.com/mailman/listinfo/tini