70
MRS-801-RE User Manual
{
struct i2c_adap *new_adapters;
new_adapters = realloc(adapters, (n + BUNCH) * sizeof(struct i2c_adap));
if (!new_adapters) {
free_adapters(adapters);
return NULL;
}
memset(new_ad n, 0, BUNCH * sizeof(struct i2c_adap));
return new_adapters;
}
struct i2c_adap *gather_i2c_busses(void)
{
char s[120];
struct dirent *de, *dde;
DIR *dir, *ddir;
FILE *f;
char fstype[NAME_MAX], sysfs[NAME_MAX], n[NAME_MAX];
int foundsysfs = 0;
int count=0;
struct i2c_adap *adapters;
adapters = calloc(BUNCH, sizeof(struct i2c_adap));
if (!adapters)
return NULL;
/* look in /proc/bus/i2c */
if ((f = fopen("/proc/bus/i2c", "r"))) {
while (fgets(s, 120, f)) {
char *algo, *name, *type, *all;
int len_algo, len_name, len_type;
int i2cbus;
algo = strrchr(s, '\t');
*(algo++) = '\0';
len_algo = rtrim(algo);
Summary of Contents for MRS-801-RE
Page 1: ...www ibase com tw IBASE Technology Inc MRS 801 RE User Manual...
Page 8: ......
Page 16: ...8 MRS 801 RE User Manual I O View Board Dimensions...
Page 40: ...32 MRS 801 RE User Manual...
Page 43: ...Copyright 2013 IBASE Technology Inc All Rights Reserved 35 IBASE Technology Inc...
Page 45: ...Copyright 2013 IBASE Technology Inc All Rights Reserved 37 IBASE Technology Inc...
Page 48: ...40 MRS 801 RE User Manual...
Page 52: ...44 MRS 801 RE User Manual sudo mkfs ext4 dev sdb1...
Page 54: ...46 MRS 801 RE User Manual tar xvf linux_bsp F600_linux_fs tgz...
Page 88: ...80 MRS 801 RE User Manual Version h define VERSION 3 1 1...