Hi Andrea,
You should always focus on the first error first.
> < envPaths
> Can't open envPaths: No such file or directory
That means that envPaths was not created for you when it should be. The problem is like to be that you need to change your iocBoot/iocXXX/Makefile to set ARCH=linux-arm. Then when you run "make" in that directory it will create envPaths for you. iocXXX is whatever you have named your IOC boot directory.
Mark
________________________________
From: Tech-talk <tech-talk-bounces at aps.anl.gov> on behalf of Andrea Solano via Tech-talk <tech-talk at aps.anl.gov>
Sent: Monday, January 11, 2021 5:42 AM
To: tech-talk at aps.anl.gov
Subject: can't readable 'arduino.proto' in 'helloWorldIOCApp/Db'
Hi, I have a problem with reading the
protocol file. All code from: http://www.smolloy.com/2015/12/epics-serial-communication-with-arduino/
I use EPICS LAST VERSION
WITH ASYN AND STREAM DEVICE
LAST VERSION
Detail of mi ioc initialization:
#!../../bin/linux-arm/helloWorldIOC
< envPaths
Can't open envPaths: No such file or directory
epicsEnvSet(STREAM_PROTOCOL_PATH,"helloWorldIOCApp/Db")
macLib: macro TOP is undefined (expanding string cd "${TOP}")
## Register all support components
dbLoadDatabase "dbd/helloWorldIOC.dbd"
helloWorldIOC_registerRecordDeviceDriver pdbbase
drvAsynSerialPortConfigure("SERIALPORT","/dev/ttyACM0",0,0,0)
asynSetOption("SERIALPORT",-1,"baud","115200")
asynSetOption("SERIALPORT",-1,"bits","8")
asynSetOption("SERIALPORT",-1,"parity","none")
asynSetOption("SERIALPORT",-1,"stop","1")
asynSetOption("SERIALPORT",-1,"clocal","Y")
asynSetOption("SERIALPORT",-1,"crtscts","N")
dbLoadRecords("db/arduino.db","PORT='SERIALPORT'")
## Load record instances
#dbLoadRecords("db/xxx.db","user=pi")
cd "/home/pi/EPICS/helloWorldIOC/iocBoot/iochelloWorldIOC"
iocInit
Starting iocInit
############################################################################
## EPICS R7.0.4.2-DEV
## Rev. R7.0.4.1-117-g4f14e9e674cfc16be1b2
############################################################################
2021/01/11 12:16:34.315589 _main_ Can't find readable file 'arduino.proto' in 'helloWorldIOCApp/Db'
2021/01/11 12:16:34.315919 _main_ while reading protocol 'set_digital' for 'led:set'
2021/01/11 12:16:34.316084 _main_ led:set: Protocol parse error
2021/01/11 12:16:34.316252 _main_ led:set: Record initialization failed
Error (514,11) PV: led:set ao: init_record
2021/01/11 12:16:34.316618 _main_ Can't find readable file 'arduino.proto' in 'helloWorldIOCApp/Db'
2021/01/11 12:16:34.316787 _main_ while reading protocol 'get_analog' for 'photo:get'
2021/01/11 12:16:34.316946 _main_ photo:get: Protocol parse error
2021/01/11 12:16:34.317103 _main_ photo:get: Record initialization failed
iocRun: All initialization complete
## Start any sequence programs
#seq sncxxx,"user=pi"
My protocol file:
Terminator = LF;
get_analog {
out "R";
in "R %f";
ExtraInput = Ignore;
}
set_digital {
out "W%d\n";
ExtraInput = Ignore;
}
My db file:
record(ao, led:set) {
field(DESC, "Arduino digi pin 11")
field(DTYP, "stream")
field(OUT, "@arduino.proto set_digital() $(PORT)")
field(DRVL, "0")
field(DRVH, "255")
}
record(ai, photo:get) {
field(DESC, "Photo diode's output")
field(DTYP, "stream")
field(INP, "@arduino.proto get_analog() $(PORT)")
field(SCAN, ".5 second")
}
- References:
- can't readable 'arduino.proto' in 'helloWorldIOCApp/Db' Andrea Solano via Tech-talk
- Navigate by Date:
- Prev:
can't readable 'arduino.proto' in 'helloWorldIOCApp/Db' Andrea Solano via Tech-talk
- Next:
Re: Can't enable custom frame rates for a basler camera in area detector Mark Rivers via Tech-talk
- Index:
1994
1995
1996
1997
1998
1999
2000
2001
2002
2003
2004
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
<2021>
2022
2023
2024
- Navigate by Thread:
- Prev:
can't readable 'arduino.proto' in 'helloWorldIOCApp/Db' Andrea Solano via Tech-talk
- Next:
DBE_PROPERTY in CS-Studio Phoebus Roehrig, Christian via Tech-talk
- Index:
1994
1995
1996
1997
1998
1999
2000
2001
2002
2003
2004
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
<2021>
2022
2023
2024
|