EPICS Controls Argonne National Laboratory

Experimental Physics and
Industrial Control System

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  <20222023  2024  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  <20222023  2024 
<== Date ==> <== Thread ==>

Subject: Re: EPICS on ESP32
From: Michael Davidsaver via Tech-talk <tech-talk at aps.anl.gov>
To: Florian Feldbauer <florian at ep1.ruhr-uni-bochum.de>
Cc: "tech-talk at aps.anl.gov" <tech-talk at aps.anl.gov>
Date: Tue, 30 Aug 2022 08:03:03 -0700
On 8/30/22 02:52, Florian Feldbauer via Tech-talk wrote:
Hey all,

for a small side project I'm working with a board featuring an ESP32-WROOM-32E module [1].
The module itself has WiFi and an EMAC core which is connected to an ethernet PHY on the board (10/100Mbps).
Also there are some sensors connected to the module.

With 448 KB ROM and 520 KB RAM, this chip seems a bit small
to run much of a "regular" IOC.  You might make it work by
manually striping down to just the CA server and DB core.

fyi. a point of rough comparison for RTEMS/powerpc32

$ size bin/RTEMS-mvme3100/softIoc
   text    data     bss     dec     hex filename
2426405  567300  212745 3206450  30ed32 bin/RTEMS-mvme3100/softIoc


At the moment I have a small program running on the board, that connects to ethernet, gets it's IP via DHCP and starts listening on a TCP port.
If a message is received the corresponding sensor data is send as an answer.

The chip is running a modified FreeRTOS kernel and I started to wonder, if it would be possible to port EPICS on that module.

I looked into FreeRTOS ~recently for an unrelated project.
It is a very bare bones OS.  The main surprise I found is that
there is only an abstraction API covering basic threading
and CPU exception handling.  Not I/O devices.  So eg. no
common UART API.  Certainly no sockets API.  Rather, the
various examples I found were using various SoC vendor
libraries directly.

So as it stands now, you would end up with a FreeRTOS+EspressIF
port rather than a generic FreeRTOS port.


Does anyone have experience with the ESP32 and tried running EPICS on it already?
If not, anyone has an idea for a good starting point for such a project?
A CA server that provides the sensor data as PVs would be enough.

A CA server is a complicated/stateful beast by comparison
with most other protocols.

Maybe start with a Modbus TCP server for it?

https://docs.espressif.com/projects/esp-idf/en/latest/esp32/api-reference/protocols/modbus.html


Cheers,
Florian


[1] https://www.espressif.com/sites/default/files/documentation/esp32-wroom-32e_esp32-wroom-32ue_datasheet_en.pdf



References:
EPICS on ESP32 Florian Feldbauer via Tech-talk

Navigate by Date:
Prev: EPICS on ESP32 Florian Feldbauer via Tech-talk
Next: Re: EPICS on ESP32 Eric Norum 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  <20222023  2024 
Navigate by Thread:
Prev: EPICS on ESP32 Florian Feldbauer via Tech-talk
Next: Re: EPICS on ESP32 Eric Norum 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  <20222023  2024 
ANJ, 14 Sep 2022 Valid HTML 4.01! · Home · News · About · Base · Modules · Extensions · Distributions · Download ·
· Search · EPICS V4 · IRMIS · Talk · Bugs · Documents · Links · Licensing ·