- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include "system.h"
#include "io.h"
int main(void){
FILE *fp;
fp = fopen ("/mnt/host/test.txt", "r");
IOWR(LED_BASE,0,1); // LED
if (fp == NULL){
__asm("NOP"); // for break point
IOWR(LED_BASE,0,2); // LED
}
fclose(fp);
IOWR(LED_BASE,0,3); // LED
while(1){
__asm("NOP"); // trap
IOWR(LED_BASE,0,4); // LED
}
return 0;
}
- Tags:
- Include
Link Copied
3 Replies
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
#include <stdio.h>
Leon
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
設定ミスでした。
bsp-editorの"enable_small_c_library"にチェックを入れていました。
無事にBuildできたので、本件closeとさせてください。
お騒がせしました。
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello,
This is due to small memory size in Qsys. If you increase the size, you will be able to build. this option "enable_small_c_library" is used to optimize the BSP size in case of low memory space available.
Reply
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page